From d1a820f287c30792e4e600aae31178a595525692 Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Fri, 29 May 2020 22:09:55 +0900 Subject: [PATCH 01/15] =?UTF-8?q?=E3=82=A2=E3=83=8E=E3=83=86=E3=83=BC?= =?UTF-8?q?=E3=82=B7=E3=83=A7=E3=83=B3=E3=82=92=E5=89=8A=E9=99=A4=E3=81=99?= =?UTF-8?q?=E3=82=8B=E3=83=A1=E3=82=BD=E3=83=83=E3=83=89=E3=82=92=E8=BF=BD?= =?UTF-8?q?=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- annofabapi/wrapper.py | 55 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) diff --git a/annofabapi/wrapper.py b/annofabapi/wrapper.py index 4581f866..64045b69 100644 --- a/annofabapi/wrapper.py +++ b/annofabapi/wrapper.py @@ -55,6 +55,14 @@ class AnnotationSpecsRelation: choice_id: Dict[ChoiceKey, ChoiceKey] +@dataclass(frozen=True) +class AnnotationQuery: + """ + 削除対象のアノテーションを指定するクエリ + """ + label_id: str + + def _first_true(iterable, default=None, pred=None): return next(filter(pred, iterable), default) @@ -357,6 +365,53 @@ def copy_annotation( self.api.put_annotation(dest.project_id, dest.task_id, dest.input_data_id, request_body=request_body) return True + @staticmethod + def __match_query_for_annotation(annotation_detail: Dict[str, Any], query:AnnotationQuery) -> bool: + return annotation_detail["label_id"] == query.label_id + + @staticmethod + def __to_put_annotation_detail(annotation_detail: Dict[str, Any]) -> Dict[str, Any]: + """ + `get_annotation_editor`メソッドで取得したアノテーションを、`put_annotation`メソッドに渡すアノテーションに変換する + """ + annotation_detail["url"] = None + return annotation_detail + + def delete_annotation(self, project_id: str, task_id: str, input_data_id: str, query:Optional[AnnotationQuery]=None) -> Optional[Dict[str, Any]]: + """ + 特定のアノテーションを削除する + + Args: + project_id: + task_id: + input_data_id: + query: 削除対象のアノテーションを指定するクエリ + + Returns: + `put_annotation`メソッドのレスポン + """ + old_annotation, _ = self.api.get_editor_annotation(project_id, task_id, input_data_id) + old_details = old_annotation["details"] + if len(old_details) == 0: + return None + + if query is None: + new_details = [] + else: + new_details = [self.__to_put_annotation_detail(d) for d in old_details if not self.__match_query_for_annotation(d, query)] + + updated_datetime = old_annotation["updated_datetime"] + request_body = { + "project_id": project_id, + "task_id": task_id, + "input_data_id": input_data_id, + "details": new_details, + "updated_datetime": updated_datetime, + } + return self.api.put_annotation(project_id, task_id, input_data_id, request_body=request_body)[0] + + + ######################################### # Public Method : AnnotationSpecs ######################################### From aaa200bfdbd4bff4c3b40d3669c38358da73fa4a Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 10 Jun 2020 21:49:57 +0900 Subject: [PATCH 02/15] =?UTF-8?q?=E3=82=A2=E3=83=8E=E3=83=86=E3=83=BC?= =?UTF-8?q?=E3=82=B7=E3=83=A7=E3=83=B3=E3=82=92=E5=89=8A=E9=99=A4=E3=81=99?= =?UTF-8?q?=E3=82=8B=E3=83=A1=E3=82=BD=E3=83=83=E3=83=89=E3=82=92=E8=BF=BD?= =?UTF-8?q?=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- generate/swagger/swagger.v2.yaml | 5157 ++-------------- generate/swagger/swagger.yaml | 9891 +++++++++--------------------- 2 files changed, 3564 insertions(+), 11484 deletions(-) diff --git a/generate/swagger/swagger.v2.yaml b/generate/swagger/swagger.v2.yaml index e2810027..7ad27fed 100644 --- a/generate/swagger/swagger.v2.yaml +++ b/generate/swagger/swagger.v2.yaml @@ -1,39 +1,60 @@ -openapi: "3.0.0" +openapi: 3.0.0 info: - description: | + description: > [AnnoFab](https://annofab.com) のWeb API v2です。 + v2 はいくつかの主要なAPIでキャッシュが有効になり、日本を含む多くの国からのアクセスが大幅に高速化されます。 + [API v1はこちら](/docs/api/)です。 + APIベースURL: https://annofab.com/api/v2
+ 例) /projects というAPIを使う場合、 https://annofab.com/api/v2/projects をリクエストします。 + ■APIの変更ポリシー
+ **現在、APIは開発途上版です。予告なく互換性のない変更がある可能性をご了承ください。** + ご要望の実現、あるいは、セキュリティやパフォーマンスの改善などを実現するにあたり、互換性のない変更が必要になる場合があります。 + その場合、開発途上版では開発リソースを改善に集中するため、古いバージョンを共存させずに互換性のない変更を行う場合があります。 + ■機能の要望や不具合報告
+ 「こんな機能が欲しい」というご要望や、「APIが予期せぬ動作をする」といった不具合報告などは、[こちらのお問い合わせフォーム](https://docs.google.com/forms/d/e/1FAIpQLSePryikS_wo_H11pxL2ewUe2d0ud0jxZlBQwH2rVVfcifKyQw/viewform)からご連絡ください。 + # API Client + APIクライアントも提供しています。 + * https://github.com/kurusugawa-computer/annofab-cli + * https://github.com/kurusugawa-computer/annofab-api-python-client + # API Convention + ## 用語 + * **属性○○○を必須**とは、「JSONに属性キー○○○を含め、かつ、その値が`null`以外」であること + * **属性○○○を未指定**とは、「JSONに属性キー○○○を含めない」または「属性○○○のキーはあるが値は`null`」のどちらかであること + ## 更新系APIのリクエストボディに必須の属性 + * 更新系APIとは、HTTPメソッドが **PUT** または **POST** のAPIです。 + * 更新系APIでは、更新対象の「リソースの最終更新日」を必須とする場合があります。 * これは、複数ユーザーからのAPIリクエストのデータ競合を避けるための、一般的なAPI設計慣習によるものです。 * ここで「リソースの最終更新日」とは、`last_updated_datetime` または `updated_datetime` という名前の属性です。 @@ -45,17 +66,23 @@ info: * 更新しようとしたリソースが存在しないとき、またはすでに更新されているときは、更新リクエストは失敗します。 * 「リソースの最終更新日」以外の属性については、新規作成/更新それぞれで必須が異なる場合、API個別に特筆されています。 + ## APIのリクエストボディに指定する _type 属性について + * 一部のAPIではリクエストボディに `_type` 属性を任意で指定することができます。 + * `_type` 属性を指定する場合は、`_type` 属性で指定された型にデコードします。 例えば、`_type` 属性に `ByDirectory` を指定すると `TaskGenerateRuleByDirectory` にデコードされ、`Poliline` を指定すると `InspectionDataPolyline` にデコードされます。 リクエストボディが誤っている場合はエラーになります。 * `_type` 属性を指定しない場合は、リクエストボディで指定された `_type` 以外の属性からデコードすべき型を推論します。適切な型が見つからない場合はエラーになります。 + * `_type` 属性は「推論が失敗して別の型にデコードされる」ことを防ぐために指定することを推奨します。しかし利便性のため指定は必須ではありません。 + ## APIに指定するID/名前の制約 + * APIで使用する各データのIDに使用できる文字種は次の通りです。 * 半角英数字 * `_` (アンダースコア) @@ -65,55 +92,77 @@ info: * 例) `b048c6b3-b36f-4c8d-97ea-96828a50a44c` * 各データのIDは、以下のように特定のデータに対して一意な値である必要があります。 + ID/名前 | 一意制約 + ---|--- + 組織名 | AnnoFab内で一意 + 組織ID | AnnoFab内で一意 + ユーザID | AnnoFab内で一意 + アカウントID | AnnoFab内で一意 + プロジェクトID | AnnoFab内で一意 + タスクID(プレフィックス含む) | プロジェクト内で一意 + 入力データID | プロジェクト内で一意 + アノテーションID | フレーム内(タスクID、入力データIDの組み合わせ)で一意 + 検査ID | プロジェクト内で一意 + 補助情報ID | プロジェクト内で一意 + WebhookID | プロジェクト内で一意 + 作業ガイド画像ID | プロジェクト内で一意 + ラベルID | プロジェクト内で一意 + 属性ID | プロジェクト内で一意 + 選択肢ID | 属性内で一意 + ジョブID | プロジェクト内で一意 + 入力データセットID | 組織内で一意 - プラグインID | 組織内で一意 - version: 0.86.0 + プラグインID | 組織内で一意 + version: 0.88.0 title: AnnoFab Web API x-logo: - url: "https://annofab.com/images/logo_landscape.png" - href: "https://annofab.com/" + url: https://annofab.com/images/logo_landscape.png + href: https://annofab.com/ contact: - url: "https://annofab.com/docs/forms/trouble-shooting.html" + url: https://annofab.com/docs/forms/trouble-shooting.html servers: -- url: https://annofab.com/api/v2 + - url: https://annofab.com/api/v2 tags: -- name: af-annotation-specs-v2 - x-displayName: Annotation Specs - description: アノテーション仕様に対する操作 -- name: af-cache-v2 - x-displayName: Cache - description: キャッシュに関係 -- name: af-organization-v2 - x-displayName: Organization - description: 組織に対する操作 -- name: af-project-member-v2 - x-displayName: Project Member - description: プロジェクトメンバーに対する操作 -- name: af-project-v2 - x-displayName: Project - description: プロジェクトに対する操作 -- name: af-statistics-v2 - x-displayName: Statistics - description: 統計 + - name: af-annotation-specs-v2 + x-displayName: Annotation Specs + description: アノテーション仕様に対する操作 + - name: af-cache-v2 + x-displayName: Cache + description: キャッシュに関係 + - name: af-organization-v2 + x-displayName: Organization + description: 組織に対する操作 + - name: af-project-member-v2 + x-displayName: Project Member + description: プロジェクトメンバーに対する操作 + - name: af-project-v2 + x-displayName: Project + description: プロジェクトに対する操作 + - name: af-statistics-v2 + x-displayName: Statistics + description: 統計 + - name: af-users-v2 + x-displayName: Users + description: 個人データ x-tagGroups: - name: API tags: @@ -123,74 +172,108 @@ x-tagGroups: - af-project-member-v2 - af-project-v2 - af-statistics-v2 + - af-users-v2 +components: + securitySchemes: + SignedCookieKeyPairId: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/SignedCookieKeyPairId + SignedCookiePolicy: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/SignedCookiePolicy + SignedCookieSignature: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/SignedCookieSignature + EveryoneRequestBody: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/EveryoneRequestBody + EveryoneQueryParameter: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/EveryoneQueryParameter + Everyone: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/Everyone + AnnoFabAdminOnly: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AnnoFabAdminOnly + AllProjectMember: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AllProjectMember + ProjectAccepter: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectAccepter + ProjectDataUser: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectDataUser + ProjectAccepterOrDataUser: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectAccepterOrDataUser + ProjectOwner: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectOwner + AllOrganizationMember: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AllOrganizationMember + OrganizationAdministrator: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/OrganizationAdministrator + OrganizationOwner: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/OrganizationOwner paths: /sign-url: get: tags: - - af-cache-v2 + - af-cache-v2 summary: V2系APIへのアクセスに必要なSigned Cookieを発行します - description: | security: - - Everyone: [] + - Everyone: [] operationId: getSignedAccessV2 parameters: - - name: url - in: query - description: | - アクセスしたいページのアドレス(クエリパラメータ含み) - schema: - type: string - example: "/api/v2/projects/{project_id}/statistics/inspections" + - name: url + in: query + description: | + アクセスしたいページのアドレス(クエリパラメータ含み) + schema: + type: string + example: /api/v2/projects/{project_id}/statistics/inspections responses: - 200: + "200": description: 正常 headers: Set-Cookie: schema: type: string - description: 署名付きCookieが発行されます。発行されるCookieの詳細は [こちら](#section/Authentication) を参照ください。 - example: CloudFront-Key-Pair-Id=XXXXYYYZZZZ; Path=/api/v2/projects/xxxx-xxxx-xxx; max-age=84600; HttpOnly; SameSite=Strict; Secure - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/cache: + description: 署名付きCookieが発行されます。発行されるCookieの詳細は [こちら](#section/Authentication) + を参照ください。 + example: CloudFront-Key-Pair-Id=XXXXYYYZZZZ; + Path=/api/v2/projects/xxxx-xxxx-xxx; max-age=84600; HttpOnly; + SameSite=Strict; Secure + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/cache": get: tags: - - af-project-v2 + - af-project-v2 summary: キャッシュレコード - description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getProjectCacheV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/ProjectCacheRecord" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/members: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectCacheRecord + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/members": get: tags: - - af-project-member-v2 + - af-project-member-v2 summary: プロジェクトメンバー一括取得 security: - SignedCookieKeyPairId: [] @@ -198,316 +281,295 @@ paths: SignedCookieSignature: [] operationId: getProjectMembersV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: include_inactive_member - in: query - description: 脱退したプロジェクトメンバーも取得する時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: include_inactive_member + in: query + description: 脱退したプロジェクトメンバーも取得する時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/ProjectMember" - page_no: - type: number - description: 現在のページ番号です。 - total_page_no: - type: number - description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトメンバーが0件であっても、総ページ数は1となります。 - total_count: - type: number - description: 検索結果の総件数。 - over_limit: - type: boolean - description: 検索結果が1万件を超えた場合にtrueとなる。 - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - description: Aggregationによる集約結果。 - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/members/{user_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMemberList + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/members/{user_id}": get: tags: - - af-project-member-v2 + - af-project-member-v2 summary: プロジェクトメンバー取得 - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getProjectMemberV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: user_id - in: path - description: アカウントのユーザID. RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 - required: true - schema: - $ref: "#/components/schemas/UserId" - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: user_id + in: path + description: アカウントのユーザID. + RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/ProjectMember" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/tasks: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/tasks": get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: タスク集計取得 - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getTaskStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/ProjectTaskStatisticsHistory" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/accounts: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectTaskStatisticsHistory + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/accounts": get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: ユーザー別タスク集計取得 - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getAccountStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/ProjectAccountStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/inspections: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectAccountStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/inspections": get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: 検査コメント集計取得 - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getInspectionStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/InspectionStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/task-phases: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InspectionStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/task-phases": get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: フェーズ別タスク集計取得 - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getTaskPhaseStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/TaskPhaseStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/labels: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhaseStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/labels": get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: ラベル別アノテーション数集計取得 - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getLabelStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/LabelStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/worktimes: + $ref: swagger-api-components.redoc.yaml#/components/schemas/LabelStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/worktimes": get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: タスク作業時間集計取得 description: | ヒストグラムは最終日のby_tasks、by_inputsでのみ返却する。 @@ -518,41 +580,41 @@ paths: SignedCookieSignature: [] operationId: getWorktimeStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/WorktimeStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/annotation-specs: + $ref: swagger-api-components.redoc.yaml#/components/schemas/WorktimeStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/annotation-specs": get: tags: - af-annotation-specs-v2 summary: アノテーション仕様取得 - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -564,7 +626,7 @@ paths: description: プロジェクトID required: true schema: - $ref: "#/components/schemas/ProjectId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - name: cache in: query description: | @@ -575,8 +637,10 @@ paths: example: "123456789" - name: history_id in: query - description: | - 過去のアノテーション仕様を取得する場合、[アノテーション仕様履歴取得](#operation/getAnnotationSpecsHistories)APIで取得した `history_id` の値を指定します。 + description: > + 過去のアノテーション仕様を取得する場合、[アノテーション仕様履歴取得](#operation/getAnnotationSpecsHistories)APIで取得した + `history_id` の値を指定します。 + 未指定時は最新のアノテーション仕様を取得します。 required: false schema: @@ -592,28 +656,28 @@ paths: default: "1" example: "2" responses: - 200: + "200": description: 正常 content: application/json: schema: - oneOf: - - $ref: "#/components/schemas/AnnotationSpecsV1" - - $ref: "#/components/schemas/AnnotationSpecsV2" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations-by-name/{organization_name}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecs + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations-by-name/{organization_name}": get: tags: - af-organization-v2 summary: 組織情報取得 - description: | + description: "" security: - - AllOrganizationMember: [] + - SignedCookieKeyPairId: [] + SignedCookiePolicy: [] + SignedCookieSignature: [] operationId: getOrganizationByNameV2 parameters: - name: organization_name @@ -621,7 +685,7 @@ paths: description: 組織名 required: true schema: - $ref: "#/components/schemas/OrganizationName" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName - name: cache in: query description: | @@ -631,24 +695,24 @@ paths: type: string example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Organization" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations-by-name/{organization_name}/cache: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations-by-name/{organization_name}/cache": get: tags: - af-organization-v2 summary: キャッシュレコード - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -660,28 +724,30 @@ paths: description: 組織名 required: true schema: - $ref: "#/components/schemas/OrganizationName" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/OrganizationCacheRecord" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationCacheRecord + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_id}": get: tags: - af-organization-v2 summary: 組織情報取得 - description: | + description: "" security: - - AllOrganizationMember: [] + - SignedCookieKeyPairId: [] + SignedCookiePolicy: [] + SignedCookieSignature: [] operationId: getOrganizationV2 parameters: - name: organization_id @@ -689,7 +755,7 @@ paths: description: 組織ID required: true schema: - $ref: "#/components/schemas/OrganizationId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId - name: cache in: query description: | @@ -699,24 +765,24 @@ paths: type: string example: "123456789" responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Organization" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_id}/cache: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_id}/cache": get: tags: - af-organization-v2 summary: キャッシュレコード - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -728,4189 +794,296 @@ paths: description: 組織ID required: true schema: - $ref: "#/components/schemas/OrganizationId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/OrganizationCacheRecord" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_id}/projects/{project_id}/task-counts: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationCacheRecord + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_id}/projects/{project_id}/task-counts": get: tags: - - af-organization-v2 + - af-organization-v2 summary: プロジェクトのタスク件数取得 - description: | + description: "" security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getProjectTaskCountV2 parameters: - - name: organization_id - in: path - description: 組織ID - required: true - schema: - $ref: "#/components/schemas/OrganizationId" - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: organization_id + in: path + description: 組織ID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/ProjectTaskCounts" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" -components: - securitySchemes: - SignedCookieKeyPairId: - description: | - 認証/認可には、[sign-url](#operation/getSignedAccessV2) APIで取得した署名付きCookieを使います。 - type: "apiKey" - in: "cookie" - name: "CloudFront-Key-Pair-Id" - SignedCookiePolicy: - description: | - 認証/認可には、[sign-url](#operation/getSignedAccessV2) APIで取得した署名付きCookieを使います。 - type: "apiKey" - in: "cookie" - name: "CloudFront-Policy" - SignedCookieSignature: - description: | - 認証/認可には、[sign-url](#operation/getSignedAccessV2) APIで取得した署名付きCookieを使います。 - type: "apiKey" - in: "cookie" - name: "CloudFront-Signature" - EveryoneRequestBody: - description: | - AnnoFabのユーザーなら誰でも利用できます。 - - 認証/認可には、リクエストボディに含まれるパスワード、トークン、または何らかの検証コードを用います。 - 詳しくは個別のAPIの説明を確認してください。 - type: "http" - scheme: "requestBody" - EveryoneQueryParameter: - description: | - AnnoFabのユーザーなら誰でも利用できます。 - - 認証/認可には、クエリパラメータに含まれるトークンまたは何らかの検証コードを用います。 - 詳しくは個別のAPIの説明を確認してください。 - type: "http" - scheme: "requestBody" - Everyone: - description: | - AnnoFabのユーザーなら誰でも利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - AnnoFabAdminOnly: - description: | - AnnoFabのシステム管理者のみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - AllProjectMember: - description: | - プロジェクトに所属するユーザーなら誰でも利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - ProjectAccepter: - description: | - プロジェクトのオーナーまたはプロジェクトのチェッカーのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - ProjectDataUser: - description: | - プロジェクトのオーナーまたはプロジェクトのアノテーションユーザーのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - ProjectAccepterOrDataUser: - description: | - プロジェクトのオーナー/チェッカー/アノテーションユーザーのいずれかのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - ProjectOwner: - description: | - プロジェクトのオーナーのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - AllOrganizationMember: - description: | - 組織に所属するユーザーなら誰でも利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - OrganizationAdministrator: - description: | - 組織のオーナーまたは組織の管理者のみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - OrganizationOwner: - description: | - 組織のオーナーのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - responses: - SuccessMessage: - description: 成功時のメッセージ - content: - application/json: - schema: - $ref: "#/components/schemas/Message" - ErrorForbiddenResource: - description: 権限エラー - content: - application/json: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectTaskCounts + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/users/{account_id}/cache": + get: + tags: + - af-users-v2 + summary: キャッシュレコード + description: "" + security: + - SignedCookieKeyPairId: [] + SignedCookiePolicy: [] + SignedCookieSignature: [] + operationId: getUserCacheV2 + parameters: + - name: account_id + in: path + description: アカウントID + required: true schema: - $ref: "#/components/schemas/ErrorForbiddenResource" - ErrorMissingResource: - description: 存在しないリソースを指定された - content: - application/json: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + responses: + "200": + description: 正常 + content: + application/json: + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/UserCacheRecord + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/users/{account_id}/project-members": + get: + tags: + - af-users-v2 + summary: 個人のプロジェクトメンバー情報一括取得 + description: "" + security: + - SignedCookieKeyPairId: [] + SignedCookiePolicy: [] + SignedCookieSignature: [] + operationId: getUserProjectMembersV2 + parameters: + - name: account_id + in: path + description: アカウントID + required: true schema: - $ref: "#/components/schemas/ErrorMissingResource" - ErrorUnauthorizedApi: - description: 認証エラー - content: - application/json: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false schema: - $ref: "#/components/schemas/ErrorUnauthorizedApi" - ErrorInvalidRequest: - description: リクエスト形式が正しくない。必要な属性が足りなかったり、属性が特定の値 - content: - application/json: + type: string + example: "123456789" + responses: + "200": + description: 正常 + content: + application/json: + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/users/{account_id}/organizations": + get: + tags: + - af-users-v2 + summary: 個人の所属組織一括取得 + description: "" + security: + - SignedCookieKeyPairId: [] + SignedCookiePolicy: [] + SignedCookieSignature: [] + operationId: getUserOrganizationsV2 + parameters: + - name: account_id + in: path + description: アカウントID + required: true schema: - # TODO このエラー定義には複数のschemaのエラーが該当しうる。それを記述する(KRSANNOFAC-1502) - $ref: "#/components/schemas/Errors" - ErrorUnderMaintenance: - description: システムメンテナンス中 - content: - application/json: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false schema: - $ref: "#/components/schemas/ErrorUnderMaintenance" - ErrorRefreshTokenExpired: - description: リフレッシュトークン有効期限切れのため、明示的にログインする必要があります - content: - application/json: + type: string + example: "123456789" + responses: + "200": + description: 正常 + content: + application/json: + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/MyOrganizationList + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/users/{account_id}/projects": + get: + tags: + - af-users-v2 + summary: 自分のプロジェクトメンバー情報一括取得 + description: "" + security: + - SignedCookieKeyPairId: [] + SignedCookiePolicy: [] + SignedCookieSignature: [] + operationId: getUserProjectsV2 + parameters: + - name: account_id + in: path + description: アカウントID + required: true schema: - $ref: "#/components/schemas/ErrorRefreshTokenExpired" - schemas: - ProjectCacheRecord: - type: object - properties: - input: - type: string - members: - type: string - project: - type: string - instruction: - type: string - specs: - type: string - statistics: - type: string - organization: - type: string - supplementary: - type: string - Errors: - type: object - properties: - errors: - type: array - items: - $ref: "#/components/schemas/Error" - context: - type: object - description: 内部補足情報 - Error: - type: object - properties: - error_code: - type: string - message: - type: string - description: エラーの概要 - ext: - type: object - description: 補足情報 - ErrorInvalidBody: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INVALID_BODY - context: - type: object - description: 内部補足情報 - ErrorInvalidQueryParam: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INVALID_QUERYPARAM - context: - type: object - description: 内部補足情報 - ErrorMissingNecessaryQueryParam: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: MISSING_NECESSARY_QUERYPARAM - context: - type: object - description: 内部補足情報 - ErrorInvalidPath: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INVALID_PATH - context: - type: object - description: 内部補足情報 - ErrorUnauthorizedApi: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: UNAUTHORIZED_API - context: - type: object - description: 内部補足情報 - ErrorLoginFailed: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: LOGIN_FAILED - context: - type: object - description: 内部補足情報 - ErrorPasswordResetRequired: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: PASSWORD_RESET_REQUIRED - context: - type: object - description: 内部補足情報 - ErrorExpiredToken: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: EXPIRED_TOKEN - context: - type: object - description: 内部補足情報 - ErrorRefreshTokenExpired: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: EXPIRED_REFRESH_TOKEN - context: - type: object - description: 内部補足情報 - ErrorForbiddenResource: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: FORBIDDEN_RESOURCE - context: - type: object - description: 内部補足情報 - ErrorMissingResource: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: MISSING_RESOURCE - context: - type: object - description: 内部補足情報 - ErrorTimeout: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: TIMEOUT - context: - type: object - description: 内部補足情報 - ErrorAlreadyUpdated: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: ALREADY_UPDATED - context: - type: object - description: 内部補足情報 - ErrorStateMismatch: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: STATE_MISMATCH - context: - type: object - description: 内部補足情報 - ErrorInternalServerError: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INTERNAL_SERVER_ERROR - context: - type: object - description: 内部補足情報 - ErrorUnderMaintenance: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: UNDER_MAINTENANCE - context: - type: object - description: 内部補足情報 - Message: - type: object - properties: - message: - type: string - description: 多言語対応 - InternationalizationMessage: - type: object - properties: - messages: - type: array - items: - type: object - properties: - lang: - type: string - message: - type: string - default_lang: - type: string - SignUpRequest: - type: object - required: - - email - properties: - email: - type: string - format: email - ConfirmSignUpRequest: - type: object - required: - - account_id - - user_id - - password - - username - - lang - - keylayout - - confirmation_code - properties: - account_id: - $ref: "#/components/schemas/AccountId" - user_id: - $ref: "#/components/schemas/UserId" - password: - type: string - username: - type: string - lang: - type: string - keylayout: - type: string - confirmation_code: - type: string - LoginRequest: - type: object - required: - - user_id - - password - properties: - user_id: - $ref: "#/components/schemas/UserId" - password: - type: string - LoginResponse: - type: object - properties: - token: - $ref: "#/components/schemas/Token" - Token: - type: object - properties: - id_token: - type: string - description: 形式は[JWT](https://jwt.io/)。 - access_token: - type: string - description: 形式は[JWT](https://jwt.io/)。 - refresh_token: - type: string - description: 形式は[JWT](https://jwt.io/)。 - RefreshTokenRequest: - type: object - required: - - refresh_token - properties: - refresh_token: - type: string - ChangePasswordRequest: - type: object - required: - - user_id - - old_password - - new_password - properties: - user_id: - $ref: "#/components/schemas/UserId" - old_password: - type: string - new_password: - type: string - PasswordResetRequest: - type: object - required: - - email - properties: - email: - type: string - format: email - ConfirmResetPasswordRequest: - type: object - required: - - user_id - - confirmation_code - - new_password - properties: - user_id: - $ref: "#/components/schemas/UserId" - confirmation_code: - type: string - new_password: - type: string - ResetEmailRequest: - type: object - required: - - email - properties: - email: - type: string - format: email - ConfirmResetEmailRequest: - type: object - required: - - token - properties: - token: - type: string - VerifyEmailRequest: - type: object - required: - - token - properties: - token: - $ref: "#/components/schemas/Token" - ConfirmVerifyEmailRequest: - type: object - required: - - token - - confirmation_code - properties: - token: - $ref: "#/components/schemas/Token" - confirmation_code: - type: string - ConfirmAccountDeleteRequest: - type: object - required: - - token - properties: - token: - type: string - Account: - type: object - required: - - account_id - - user_id - - username - - email - - lang - - keylayout - - authority - properties: - account_id: - $ref: "#/components/schemas/AccountId" - user_id: - $ref: "#/components/schemas/UserId" - username: - type: string - email: - type: string - format: email - lang: - type: string - biography: - $ref: "#/components/schemas/UserBiography" - keylayout: - type: string - authority: - $ref: "#/components/schemas/AccountAuthority" - updated_datetime: - type: string - format: date-time - AccountAuthority: - type: string - enum: - - user - - admin - MyAccount: - allOf: - - $ref: "#/components/schemas/Account" - - type: object - required: - - errors - properties: - reset_requested_email: - type: string - format: email - errors: - type: array - items: - type: string - PutMyAccountRequest: - type: object - required: - - user_id - - username - - lang - - keylayout - properties: - user_id: - $ref: "#/components/schemas/UserId" - username: - type: string - lang: - type: string - keylayout: - type: string - biography: - $ref: "#/components/schemas/UserBiography" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - LastUpdatedDatetime: - type: string - format: date-time - description: | - 新規作成時は未指定、更新時は必須(更新前の日時) - AcceptOrganizationInvitationRequest: - type: object - properties: - token: - type: string - OrganizationActivity: - type: object - required: - - organization_id - - created_datetime - - storage_usage_bytes - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - created_datetime: - type: string - format: date-time - storage_usage_bytes: - type: number - Organization: - type: object - required: - - organization_id - - organization_name - - email - - price_plan - - summary - - created_datetime - - updated_datetime - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - organization_name: - type: string - email: - type: string - format: email - price_plan: - $ref: "#/components/schemas/PricePlan" - summary: - $ref: "#/components/schemas/OrganizationSummary" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - OrganizationCacheRecord: - type: object - properties: - input: - type: string - members: - type: string - statistics: - type: string - organization: - type: string - OrganizationSummary: - type: object - properties: {} - PricePlan: - type: string - enum: - - free - - business - OrganizationMember: - type: object - required: - - organization_id - - account_id - - user_id - - username - - role - - status - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - account_id: - $ref: "#/components/schemas/AccountId" - user_id: - $ref: "#/components/schemas/UserId" - username: - type: string - role: - $ref: "#/components/schemas/OrganizationMemberRole" - status: - $ref: "#/components/schemas/OrganizationMemberStatus" - biography: - $ref: "#/components/schemas/UserBiography" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - OrganizationMemberRole: - type: string - enum: - - owner - - administrator - - contributor - OrganizationMemberStatus: - type: string - enum: - - active - - waiting_response - - inactive - description: | - * `active` - 組織メンバーとして有効で、組織を閲覧したり、権限があれば編集できます。 - * `waiting_response` - 組織に招待され、まだ加入/脱退を返答していません。組織の一部を閲覧のみできます。 - * `inactive` - 脱退したメンバーを表します。組織を閲覧できません。 - OrganizationPlugin: - type: object - required: - - organization_id - - plugin_id - - created_datetime - - updated_datetime - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - plugin_id: - $ref: "#/components/schemas/PluginId" - plugin_name: - $ref: "#/components/schemas/PluginName" - description: - $ref: "#/components/schemas/PluginDescription" - annotation_editor_url: - $ref: "#/components/schemas/AnnotationEditorUrl" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - PutOrganizationPluginRequest: - type: object - properties: - plugin_name: - $ref: "#/components/schemas/PluginName" - description: - $ref: "#/components/schemas/PluginDescription" - annotation_editor_url: - $ref: "#/components/schemas/AnnotationEditorUrl" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - PluginId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - プラグインID。[値の制約についてはこちら。](#section/API-Convention/APIID) - PluginName: - type: string - example: "foo-bar" - description: | - プラグインの名前です。 - プラグイン一覧や、プロジェクトで使うプラグインを選ぶときなどに表示されます。 - PluginDescription: - type: string - example: "desc" - description: | - プラグインの説明です。 - プラグイン一覧や、プロジェクトで使うプラグインを選ぶときなどに表示されます。 - AnnotationEditorUrl: - type: string - example: "https://example.com/my/editors?p={projectId}&t={taskId}" - description: | - カスタムアノテーションエディタでタスクを開くための URL です。 - プラグインを使用するプロジェクトのタスク一覧などで使用されます。 - - この URL には、タスクを特定するための以下のパラメータを必ず埋め込んでください。 - - * `{projectId}` - * `{taskId}` - - 以下のパラメーターは任意で指定します。 - - * `{inputDataId}`: アノテーション一覧などから、特定の入力データにフォーカスした状態でタスクを開くときなどに指定します。 - * `{annotationId}`: アノテーション一覧などから、特定のアノテーションにフォーカスした状態でタスクを開くときなどに指定します。 - - MyOrganization: - type: object - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - name: - type: string - email: - type: string - format: email - price_plan: - $ref: "#/components/schemas/PricePlan" - summary: - $ref: "#/components/schemas/OrganizationSummary" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - my_role: - $ref: "#/components/schemas/OrganizationMemberRole" - my_status: - $ref: "#/components/schemas/OrganizationMemberStatus" - OrganizationRegistrationRequest: - type: object - required: - - organization_name - - organization_email - - price_plan - properties: - organization_name: - $ref: "#/components/schemas/OrganizationName" - organization_email: - type: string - format: email - price_plan: - $ref: "#/components/schemas/PricePlan" - PutOrganizationNameRequest: - type: object - required: - - organization_id - - organization_name - - last_updated_datetime - properties: - organization_id: - type: string - organization_name: - $ref: "#/components/schemas/OrganizationName" - last_updated_datetime: - type: string - format: date-time - PutOrganizationMemberRoleRequest: - type: object - required: - - role - properties: - role: - $ref: "#/components/schemas/OrganizationMemberRole" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - InviteOrganizationMemberRequest: - type: object - properties: - role: - $ref: "#/components/schemas/OrganizationMemberRole" - AccountId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - UserId: - type: string - example: "john_doe" - OrganizationId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - 組織ID。[値の制約についてはこちら。](#section/API-Convention/APIID) - OrganizationName: - type: string - example: "sample-organization" - description: | - 組織名。[値の制約についてはこちら。](#section/API-Convention/APIID) - ProjectId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) - LabelId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - AdditionalDataDefinitionId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - ChoiceId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - PhraseId: - type: string - example: "my_phrase_id" - TaskId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) - InputDataId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) - InputDataSetId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - 入力データセットID。[値の制約についてはこちら。](#section/API-Convention/APIID) - SupplementaryDataId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - TaskHistoryId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - AnnotationId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
- annotation_type が classification の場合は label_id と同じ値が格納されます。 - InspectionId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - 検査ID。[値の制約についてはこちら。](#section/API-Convention/APIID) - MarkerId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - マーカーID。[値の制約についてはこちら。](#section/API-Convention/APIID) - JobId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - WebhookId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - WebhookID。[値の制約についてはこちら。](#section/API-Convention/APIID) - Duration: - type: string - example: "PT34H17M36.789S" - UserBiography: - type: string - description: | - 人物紹介、略歴。 - - この属性は、AnnoFab外の所属先や肩書などを表すために用います。 - AnnoFab上の「複数の組織」で活動する場合、本籍を示すのに便利です。 - minLength: 0 - maxLength: 100 - example: "Annotation Manager, ABC Company" - AnnotationFormatVersion: - type: string - example: "1.0.0" - description: | - アノテーションフォーマットのバージョンです。 - アノテーションフォーマットとは、プロジェクト個別のアノテーション仕様ではなく、AnnoFabのアノテーション構造のことです。 - したがって、アノテーション仕様を更新しても、このバージョンは変化しません。 - - バージョンの読み方と更新ルールは、業界慣習の[Semantic Versioning](https://semver.org/)にもとづきます。 - - JSONに出力されるアノテーションフォーマットのバージョンは、アノテーションZIPが作成される時点のものが使われます。 - すなわち、`1.0.0`の時点のタスクで作成したアノテーションであっても、フォーマットが `1.0.1` に上がった次のZIP作成時では `1.0.1` となります。 - バージョンを固定してZIPを残しておきたい場合は、プロジェクトが完了した時点でZIPをダウンロードして保管しておくか、またはプロジェクトを「停止中」にします。 - Project: - type: object - required: - - project_id - - organization_id - - title - - project_status - - input_data_type - - created_datetime - - updated_datetime - - configuration - - summary - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - organization_id: - $ref: "#/components/schemas/OrganizationId" - title: - type: string - description: プロジェクトのタイトル - overview: - type: string - description: プロジェクトの概要 - project_status: - $ref: "#/components/schemas/ProjectStatus" - input_data_type: - $ref: "#/components/schemas/InputDataType" - configuration: - $ref: "#/components/schemas/ProjectConfiguration" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - summary: - $ref: "#/components/schemas/ProjectSummary" - ProjectStatus: - type: string - enum: - - active - - suspended - description: | - プロジェクトの状態 - * `active` - プロジェクトが進行中 - * `suspended` - プロジェクトが停止中 - AssigneeRuleOfResubmittedTask: - type: string - enum: - - no_assignee - - fixed - description: | - 再提出されたタスクの検査/受入担当者の割当方法 - * `no_assignee` - 以前の担当者で固定せず、未割当てにします。 - * `fixed` - 以前の担当者が再度担当します。以前の担当者がいない(1回目の検査/受入)場合は未割当てになります。 - InputDataType: - type: string - description: | - アノテーションする入力データの種類。プロジェクトの作成時のみ指定可能(未指定の場合は `image`)です。更新時は無視されます。 - * `image` - 画像 - * `movie` - 動画 - enum: - - image - - movie - ProjectConfiguration: - type: object - properties: - number_of_inspections: - description: | - 検査回数。 - * 0回:教師付け -> 受入 - * 1回:教師付け -> 検査 -> 受入 - * n回(n >= 2):教師付け -> 検査1 -> ... -> 検査n -> 受入 - type: integer - default: 0 - minimum: 0 - assignee_rule_of_resubmitted_task: - description: 再提出されたタスクの検査/受入担当者ルール。 - $ref: "#/components/schemas/AssigneeRuleOfResubmittedTask" - default: no_assignee - task_assignment_type: - $ref: "#/components/schemas/TaskAssignmentType" - max_tasks_per_member: - description: 保留中のタスクを除き、1人(オーナー以外)に割り当てられるタスク数上限。未指定の場合は10件として扱う。 - type: integer - default: 10 - minimum: 1 - maximum: 100 - max_tasks_per_member_including_hold: - description: 保留中のタスクを含めて、1人(オーナー以外)に割り当てられるタスク数上限。未指定の場合は20件として扱う。 - type: integer - default: 20 - minimum: 1 - maximum: 100 - input_data_set_id_list: - description: このフィールドは内部用でまだ何も意味を成しません。今は空配列を指定してください。 - type: array - items: - $ref: "#/components/schemas/InputDataSetId" - example: "[]" - input_data_max_long_side_length: - description: | - 入力データ画像の長辺の最大値(未指定時は4096px)。 - - 画像をアップロードすると、長辺がこの値になるように画像が自動で圧縮されます。 - アノテーションの座標は、もとの解像度の画像でつけたものに復元されます。 - - 大きな数値を設定すると入力データ画像のサイズが大きくなり、生産性低下やブラウザで画像を表示できない懸念があります。注意して設定してください。 - type: integer - default: 4096 - minimum: 0 - sampling_inspection_rate: - description: 抜取検査率。0-100のパーセント値で指定し、未指定の場合は100%として扱う。 - type: integer - sampling_acceptance_rate: - description: 抜取受入率。0-100のパーセント値で指定し、未指定の場合は100%として扱う。 - type: integer - private_storage_aws_iam_role_arn: - type: string - description: | - AWS IAMロール。ビジネスプランでのS3プライベートストレージの認可で使います。 - [S3プライベートストレージの認可の設定についてはこちら](/docs/faq/#m0b240)をご覧ください。 - example: "arn:aws:iam::123456789012:role/AnnoFabPrivateStorageAccessor" - ProjectSummary: - type: object - properties: - last_tasks_updated_datetime: - type: string - format: date-time - description: タスクの最終更新日時 - TaskAssignmentType: - type: string - default: random - enum: - - random - - selection - - random_and_selection - description: | - プロジェクトで使用するタスクの割当方式。 - - * `random` - タスクフェーズのみを指定してランダムにタスクを自身に割当する方式です。 - * `selection` - 担当者とタスクを明示的に指定してタスクを割当する方式です。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。 - * `random_and_selection` - ランダム割当と選択割当の両機能を使用する方式です。 - JobInfo: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - job_type: - $ref: "#/components/schemas/JobType" - job_id: - $ref: "#/components/schemas/JobId" - job_status: - $ref: "#/components/schemas/JobStatus" - job_execution: - type: object - description: ジョブの内部情報 - job_detail: - type: object - description: ジョブ結果の内部情報 - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - JobType: - type: string - enum: - - copy-project - - gen-inputs - - gen-tasks - - gen-annotation - - gen-tasks-list - - gen-inputs-list - - delete-project - - invoke-hook - description: | - * `copy-project` - プロジェクトのコピー。[initiateProjectCopy](#operation/initiateProjectCopy) APIを実行したときに登録されるジョブ。 - * `gen-inputs` - zipファイルから入力データの作成。[putInputData](#operation/putInputData) APIを実行して、zipファイルから入力データを作成したときに登録されるジョブ。 - * `gen-tasks` - タスクの一括作成。[initiateTasksGeneration](#operation/initiateTasksGeneration) APIを実行したときに登録されるジョブ。 - * `gen-annotation` - アノテーションZIPの更新。[postAnnotationArchiveUpdate](#operation/postAnnotationArchiveUpdate) APIを実行したときに登録されるジョブ。 - * `gen-tasks-list` - タスク全件ファイルの更新。[postProjectTasksUpdate](#operation/postProjectTasksUpdate) APIを実行したときに登録されるジョブ。 - * `gen-inputs-list` - 入力データ情報全件ファイルの更新。[postProjectInputsUpdate](#operation/postProjectInputsUpdate) APIを実行したときに登録されるジョブ。 - * `delete-project` - プロジェクトの削除。[deleteProject](#operation/deleteProject) APIを実行したときに登録されるジョブ。 - * `invoke-hook` - Webhookの起動。 - JobStatus: - type: string - enum: - - progress - - succeeded - - failed - PostAnnotationArchiveUpdateResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - PostProjectTasksUpdateResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - ProjectCopyResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - dest_project: - $ref: "#/components/schemas/Project" - DeleteProjectResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - project: - $ref: "#/components/schemas/Project" - TaskGenerateResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - project: - $ref: "#/components/schemas/Project" - ProjectInputsUpdateResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - Webhook: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - event_type: - $ref: "#/components/schemas/WebhookEventType" - webhook_id: - $ref: "#/components/schemas/WebhookId" - webhook_status: - $ref: "#/components/schemas/WebhookStatus" - method: - $ref: "#/components/schemas/WebhookHttpMethod" - headers: - type: array - items: - $ref: "#/components/schemas/WebhookHeader" - body: - type: string - example: '{\"message\": \"{{PROJECT_ID}} is updated at {{COMPLETE_DATETIME}}\"}' - url: - type: string - format: uri - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - WebhookHeader: - type: object - properties: - name: - type: string - value: - type: string - WebhookStatus: - type: string - enum: - - active - - inactive - WebhookHttpMethod: - type: string - enum: - - POST - - PUT - - DELETE - - PATCH - - GET - - HEAD - WebhookEventType: - type: string - enum: - - task-completed - - annotation-archive-updated - - input-data-zip-registered - - project-copy-completed - description: | - * `task-completed` - タスク受入完了 - * `annotation-archive-updated` - アノテーションZIP作成完了 - * `input-data-zip-registered` - 入力データZIP登録完了 - * `project-copy-completed` - プロジェクトコピー完了 - PutProjectRequest: - type: object - required: - - title - - status - - organization_name - - configuration - properties: - title: - type: string - description: プロジェクトのタイトル - overview: - type: string - description: プロジェクトの概要 - status: - $ref: "#/components/schemas/ProjectStatus" - input_data_type: - $ref: "#/components/schemas/InputDataType" - organization_name: - type: string - description: | - プロジェクトの所属組織を変更する場合は、ここに変更先の組織名を指定します。 - - * 所属組織を変更する前にプロジェクトを停止する必要があります。 - * APIを呼び出すアカウントは、変更先組織の管理者またはオーナーである必要があります。 - * 変更後の組織に所属していないプロジェクトメンバーも残りますが、作業はできません。あらためて組織に招待してください。 - configuration: - $ref: "#/components/schemas/ProjectConfiguration" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - force_suspend: - type: boolean - description: 作業中タスクがあるプロジェクトを停止する時trueにして下さい - default: false - ProjectCopyRequest: - type: object - required: - - dest_project_id - - dest_title - properties: - dest_project_id: - $ref: "#/components/schemas/ProjectId" - dest_title: - type: string - description: コピー先プロジェクトのタイトル - dest_overview: - type: string - description: コピー先プロジェクトの概要 - copy_inputs: - type: boolean - description: | - 「入力データ」をコピーするかどうかを指定します。 - default: false - copy_tasks: - type: boolean - description: | - 「タスク」をコピーするかどうかを指定します。 - - この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 - - * copy_inputs の値を true とする - default: false - copy_annotations: - type: boolean - description: | - 「アノテーション」をコピーするかどうかを指定します。 - - この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 - - * copy_inputs の値を true とする - * copy_tasks の値を true とする - default: false - copy_webhooks: - type: boolean - description: | - 「Webhook」をコピーするかどうかを指定します。 - default: false - copy_supplementaly_data: - type: boolean - description: | - 「補助情報」をコピーするかどうかを指定します。 - - この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 - - * copy_inputs の値を true とする - default: false - copy_instructions: - type: boolean + $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + - name: page + in: query description: | - 「作業ガイド」をコピーするかどうかを指定します。 - default: false - ProjectMember: - type: object - required: - - project_id - - account_id - - user_id - - username - - member_status - - member_role - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - account_id: - $ref: "#/components/schemas/AccountId" - user_id: - $ref: "#/components/schemas/UserId" - username: - type: string - member_status: - $ref: "#/components/schemas/ProjectMemberStatus" - member_role: - $ref: "#/components/schemas/ProjectMemberRole" - biography: - $ref: "#/components/schemas/UserBiography" - updated_datetime: - type: string - format: date-time - created_datetime: - type: string - format: date-time - sampling_inspection_rate: - description: メンバー固有の抜取検査率(0-100のパーセント値)。 - type: integer - sampling_acceptance_rate: - description: メンバー固有の抜取受入率(0-100のパーセント値)。 - type: integer - ProjectMemberStatus: - type: string - enum: - - active - - inactive - description: | - * `active` - プロジェクトメンバーとして有効で、プロジェクトを閲覧したり、権限があれば編集できます。 - * `inactive` - 脱退したプロジェクトメンバーを表します。プロジェクトを閲覧できません。 - ProjectMemberRole: - type: string - enum: - - owner - - worker - - accepter - - training_data_user - ProjectMemberRequest: - type: object - properties: - member_status: - $ref: "#/components/schemas/ProjectMemberStatus" - member_role: - $ref: "#/components/schemas/ProjectMemberRole" - sampling_inspection_rate: - description: メンバー固有の抜取検査率。0-100のパーセント値で指定する。値が指定された場合、プロジェクトの抜取検査率を指定の値で上書きする。 - type: integer - sampling_acceptance_rate: - description: メンバー固有の抜取受入率。0-100のパーセント値で指定する。値が指定された場合、プロジェクトの抜取受入率を指定の値で上書きする。 - type: integer - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - ProjectTaskStatisticsHistory: - type: object - properties: - date: - type: string - format: date - tasks: - type: array - items: - $ref: "#/components/schemas/ProjectTaskStatistics" - ProjectTaskStatistics: - type: object - required: - - phase - - status - - count - - work_timespan - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - status: - $ref: "#/components/schemas/TaskStatus" - count: - type: integer - minimum: 0 - description: タスク数 - work_timespan: - type: integer - description: 累計実作業時間(ミリ秒) - ProjectAccountStatistics: - type: object - required: - - account_id - - histories - properties: - account_id: - $ref: "#/components/schemas/AccountId" - histories: - type: array - items: - $ref: "#/components/schemas/ProjectAccountStatisticsHistory" - ProjectAccountStatisticsHistory: - type: object - required: - - date - - tasks_completed - - tasks_rejected - - worktime - properties: - date: - type: string - format: date - tasks_completed: - type: integer - description: 教師付を担当したタスクが完了状態になった回数 - tasks_rejected: - type: integer - description: 教師付を担当したタスクが差し戻された回数 - worktime: - type: string - example: "PT34H17M36.789S" - description: 作業時間(ISO 8601 duration) - InspectionStatistics: - type: object - required: - - project_id - - date - - breakdown - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - date: - description: 集計日 - type: string - format: date - breakdown: - $ref: "#/components/schemas/InspectionStatisticsBreakdown" - InspectionStatisticsBreakdown: - type: object - description: 検査コメント数の集計結果 - required: - - labels - - no_label - properties: - labels: - description: ラベルごとの指摘集計結果。キーは`label_id` - type: object - additionalProperties: { - $ref: "#/components/schemas/InspectionStatisticsPhrases" - } - no_label: - $ref: "#/components/schemas/InspectionStatisticsPhrases" - InspectionStatisticsPhrases: - type: object - description: ラベル外指摘の集計結果 - required: - - phrases - - no_phrase - properties: - phrases: - description: 定型指摘ごとの合計数。キーは定型指摘ID、値は指摘数 - type: object - additionalProperties: { + 表示するページ番号 + required: false + schema: type: integer - } - no_phrase: - description: 非定型指摘の合計数 - type: integer - TaskPhaseStatistics: - type: object - required: - - project_id - - date - - phases - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - date: - type: string - format: date - phases: - description: タスクのフェーズごとの集計結果 - type: array - items: - $ref: "#/components/schemas/PhaseStatistics" - PhaseStatistics: - type: object - required: - - phase - - worktime - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - worktime: - description: 累積作業時間(ISO 8601 duration) - type: string - example: "PT34H17M36.789S" - LabelStatistics: - type: object - required: - - label_id - - completed - - wip - properties: - label_id: - $ref: "#/components/schemas/LabelId" - completed: - type: integer - minimum: 0 - description: ラベルごとの受入が完了したアノテーション数 - wip: - type: integer - minimum: 0 - description: ラベルごとの受入が完了していないアノテーション数 - WorktimeStatistics: - type: object - required: - - project_id - - date - - by_tasks - - by_inputs - - by_minutes - - accounts - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - date: - type: string - format: date - by_tasks: - type: array - description: タスク1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - by_inputs: - type: array - description: 画像1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - by_minutes: - type: array - description: 動画1分当たりの作業時間情報(画像プロジェクトの場合は空リスト) - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - accounts: - type: array - description: ユーザごとの作業時間情報 - items: - $ref: "#/components/schemas/AccountWorktimeStatistics" - WorktimeStatisticsItem: - type: object - required: - - phase - - histogram - - average - - standard_deviation - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - histogram: - type: array - items: - $ref: "#/components/schemas/HistogramItem" - average: - description: 作業時間の平均(ISO 8601 duration) - type: string - example: "PT34H17M36.789S" - standard_deviation: - description: 作業時間の標準偏差(ISO 8601 duration) - type: string - example: "PT34H17M36.789S" - HistogramItem: - type: object - required: - - begin - - end - - count - properties: - begin: - type: number - end: - type: number - count: - type: integer - AccountWorktimeStatistics: - type: object - required: - - account_id - - by_tasks - - by_inputs - - by_minutes - properties: - account_id: - $ref: "#/components/schemas/AccountId" - by_tasks: - description: ユーザごとのタスク1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) - type: array - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - by_inputs: - description: ユーザごとの画像1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) - type: array - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - by_minutes: - description: ユーザごとの動画1分当たりの作業時間情報(画像プロジェクトの場合は空リスト) - type: array - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - Marker: - type: object - properties: - marker_id: - $ref: "#/components/schemas/MarkerId" - title: - type: string - graph_type: - description: マーカーの配置先グラフ - $ref: "#/components/schemas/GraphType" - marked_at: - description: グラフ上のマーカー位置(x軸) - type: string - format: date - Markers: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - markers: - type: array - items: - $ref: "#/components/schemas/Marker" - updated_datetime: - type: string - format: date - GraphType: - type: string - enum: - - task_progress - - cumulative_labor_time_By_task_phase - - number_of_inspections_per_inspection_phrase - - number_of_task_rejections_by_member - - labor_time_per_member - - mean_labor_time_per_image - - mean_labor_time_per_minute_of_movie - - mean_labor_time_per_image_by_member - - mean_labor_time_per_minute_of_movie_by_member - description: | - * `task_progress` - タスク進捗状況 - * `cumulative_labor_time_by_task_phase` - タスクフェーズ別累積作業時間 - * `number_of_inspections_per_inspection_phrase` - 検査コメント内容別指摘回数 - * `number_of_task_rejections_by_member` - メンバー別タスクが差戻された回数 - * `labor_time_per_member` - メンバー別作業時間 - * `mean_labor_time_per_image` - 画像一枚当たりの作業時間平均 - * `mean_labor_time_per_minute_of_movie` - 動画一分当たりの作業時間平均 - * `mean_labor_time_per_image_by_member` - メンバー別画像一枚当たりの作業時間平均 - * `mean_labor_time_per_minute_of_movie_by_member` - メンバー別動画一分当たりの作業時間平均 - PutMarkersRequest: - type: object - properties: - markers: - type: array - items: - $ref: "#/components/schemas/Marker" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - AnnotationSpecsV1: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - labels: - type: array - items: - $ref: "#/components/schemas/LabelV1" - inspection_phrases: - type: array - items: - $ref: "#/components/schemas/InspectionPhrase" - updated_datetime: - type: string - format: date-time - description: | - アノテーション仕様の最終更新時刻 - AnnotationSpecsV2: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - labels: - type: array - items: - $ref: "#/components/schemas/LabelV2" - additionals: - type: array - items: - $ref: "#/components/schemas/AdditionalDataDefinitionV2" - restrictions: - type: array - items: - $ref: "#/components/schemas/AdditionalDataRestriction" - inspection_phrases: - type: array - items: - $ref: "#/components/schemas/InspectionPhrase" - format_version: - type: string - default: "2.1.0" - updated_datetime: - type: string - format: date-time - description: | - アノテーション仕様の最終更新時刻 - AnnotationSpecsRequestV1: - type: object - required: - - labels - - inspection_phrases - - comment - - auto_marking - properties: - labels: - type: array - items: - $ref: "#/components/schemas/LabelV1" - inspection_phrases: - type: array - items: - $ref: "#/components/schemas/InspectionPhrase" - comment: - type: string - auto_marking: - type: boolean - default: false - description: | - trueが指定された場合、各統計グラフにマーカーを自動追加します。 - マーカーのタイトルには `comment` に指定された文字列が設定されます。 - `comment` が指定されていなかった場合は "アノテーション仕様の変更" という文字列が設定されます。 - last_updated_datetime: - allOf: - - $ref: "#/components/schemas/LastUpdatedDatetime" - description: | - 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 - 新規作成時は未指定。 - AnnotationSpecsRequestV2: - type: object - required: - - labels - - additionals - - restrictions - - inspection_phrases - - comment - - auto_marking - - format_version - properties: - labels: - type: array - items: - $ref: "#/components/schemas/LabelV2" - additionals: - type: array - items: - $ref: "#/components/schemas/AdditionalDataDefinitionV2" - restrictions: - type: array - items: - $ref: "#/components/schemas/AdditionalDataRestriction" - inspection_phrases: - type: array - items: - $ref: "#/components/schemas/InspectionPhrase" - comment: - type: string - auto_marking: - type: boolean - default: false + minimum: 1 + default: 1 + - name: limit + in: query description: | - trueが指定された場合、各統計グラフにマーカーを自動追加します。 - マーカーのタイトルには `comment` に指定された文字列が設定されます。 - `comment` が指定されていなかった場合は "アノテーション仕様の変更" という文字列が設定されます。 - format_version: - type: string - default: "2.1.0" - last_updated_datetime: - allOf: - - $ref: "#/components/schemas/LastUpdatedDatetime" + 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 0 + maximum: 200 + - name: organization_id + in: query description: | - 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 - 新規作成時は未指定。 - AnnotationSpecsHistory: - type: object - properties: - history_id: - type: string - project_id: - $ref: "#/components/schemas/ProjectId" - updated_datetime: - type: string - format: date-time - url: - type: string - account_id: - $ref: "#/components/schemas/AccountId" - comment: - type: string - InspectionPhrase: - type: object - properties: - id: - type: string - text: - $ref: "#/components/schemas/InternationalizationMessage" - AnnotationType: - type: string - enum: - - bounding_box - - segmentation - - segmentation_v2 - - polygon - - polyline - - point - - classification - - range - description: | - * `bounding_box` - 矩形を表します。 - * `segmentation` - ピクセルレベルでの塗りつぶし(ラスター)を表します。 - * `segmentation_v2` - 塗りつぶしv2を表します。v2はSemantic Segmentationに特化しています。 - * `polygon` - ポリゴン(閉じた頂点集合)を表します。 - * `polyline` - ポリライン(開いた頂点集合)を表します。 - * `point` - 点を表します。 - * `classification` - 入力データ全体に対するアノテーションを表します。 - * `range` - 動画の区間を表します。 - AdditionalDataDefinitionType: - type: string - enum: - - flag - - integer - - text - - comment - - choice - - select - - tracking - - link - description: | - * `flag` - 真偽値 - * `integer` - 整数値 - * `text` - 自由記述(1行) - * `comment` - 自由記述(複数行) - * `choice` - 選択肢(ラジオボタン式) - * `select` - 選択肢(ドロップダウン式) - * `tracking` - 自由記述 (トラッキングID自動挿入) - * `link` - アノテーションリンク - PositionForMinimumBoundingBoxInsertion: - type: object - description: | - `annotation_type` が `bounding_box` かつ `min_warn_rule` が `and` または `or` の場合のみ、挿入する最小矩形アノテーションの原点を指定できます。 - 画像左上の座標が「x=0, y=0」です。 - 未指定、もしくは「画像外に飛び出たアノテーション」を許可していないにも関わらず飛び出してしまう場合は、表示範囲の中央に挿入されます。 - 「スキャンした帳票の記入欄」や「定点カメラで撮影した製品ラベル」など、アノテーションしたい位置やサイズが多くの画像で共通している場合に便利です。 - - `annotation_type` が `bounding_box` 以外の場合は必ず未指定となります。 - required: - - x - - y - properties: - x: - type: integer - y: - type: integer - LabelV1: - type: object - properties: - label_id: - $ref: "#/components/schemas/LabelId" - label_name: - $ref: "#/components/schemas/InternationalizationMessage" - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - annotation_type: - $ref: "#/components/schemas/AnnotationType" - bounding_box_metadata: - type: object - properties: - min_width: - type: integer - min_height: - type: integer - min_warn_rule: - type: string - default: or - min_area: - type: integer - minimum: 1 - maximum: 1000000 - max_vertices: - type: integer - min_vertices: - type: integer - position_for_minimum_bounding_box_insertion: - $ref: "#/components/schemas/PositionForMinimumBoundingBoxInsertion" - tolerance: - type: integer - segmentation_metadata: - type: object - properties: - min_width: - type: integer - min_height: - type: integer - min_warn_rule: - type: string - default: or - tolerance: - type: integer - additional_data_definitions: - type: array - items: - $ref: "#/components/schemas/AdditionalDataDefinitionV1" - color: - $ref: "#/components/schemas/Color" - annotation_editor_feature: - $ref: "#/components/schemas/AnnotationEditorFeature" - allow_out_of_image_bounds: - type: boolean - default: false - LabelV2: - type: object - properties: - label_id: - $ref: "#/components/schemas/LabelId" - label_name: - $ref: "#/components/schemas/InternationalizationMessage" - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - annotation_type: - $ref: "#/components/schemas/AnnotationType" - bounding_box_metadata: - type: object - properties: - min_width: - type: integer - min_height: - type: integer - min_warn_rule: - type: string - default: or - min_area: - type: integer - minimum: 1 - maximum: 1000000 - max_vertices: - type: integer - min_vertices: - type: integer - position_for_minimum_bounding_box_insertion: - $ref: "#/components/schemas/PositionForMinimumBoundingBoxInsertion" - tolerance: - type: integer - segmentation_metadata: - type: object - properties: - min_width: - type: integer - min_height: - type: integer - min_warn_rule: - type: string - default: or - tolerance: - type: integer - additional_data_definitions: - type: array - items: - $ref: "#/components/schemas/AdditionalDataDefinitionId" - color: - $ref: "#/components/schemas/Color" - annotation_editor_feature: - $ref: "#/components/schemas/AnnotationEditorFeature" - allow_out_of_image_bounds: - type: boolean - default: false - Color: - type: object - properties: - red: - type: integer - minimum: 0 - maximum: 255 - green: - type: integer - minimum: 0 - maximum: 255 - blue: - type: integer - minimum: 0 - maximum: 255 - AnnotationEditorFeature: - type: object - properties: - append: - type: boolean - erase: - type: boolean - freehand: - type: boolean - rectangle_fill: - type: boolean - polygon_fill: - type: boolean - fill_near: - type: boolean - AdditionalDataDefinitionV1: - type: object - properties: - additional_data_definition_id: - $ref: "#/components/schemas/AdditionalDataDefinitionId" - read_only: - type: boolean - default: false - name: - $ref: "#/components/schemas/InternationalizationMessage" - default: - oneOf: - - type: boolean - - type: integer - - type: string + 指定した組織に属するプロジェクトに絞り込む。未指定時は全プロジェクト。 + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId + - name: title + in: query description: | - 属性の初期値です。 - - 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 - - * type が flag の場合: 真偽値(`true` or `false`) - * type が integer の場合: 整数値 - * type が text の場合: 文字列 - * type が comment の場合: 文字列 - * type が choice の場合: 選択肢(`choices`)の `choice_id` - * type が select の場合: 選択肢(`choices`)の `choice_id` - - 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 - - なお、トラッキングとリンクには初期値を設定できません。 - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - type: - $ref: "#/components/schemas/AdditionalDataDefinitionType" - choices: - type: array - items: - type: object - properties: - choice_id: - $ref: "#/components/schemas/ChoiceId" - name: - $ref: "#/components/schemas/InternationalizationMessage" - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - regex: - type: string - label_ids: - type: array - description: リンク属性において、リンク先として指定可能なラベルID(空の場合制限なし) - items: + プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 + required: false + schema: type: string - required: - type: boolean - description: リンク属性において、入力を必須とするかどうか - AdditionalDataDefinitionV2: - type: object - properties: - additional_data_definition_id: - $ref: "#/components/schemas/AdditionalDataDefinitionId" - read_only: - type: boolean - default: false - name: - $ref: "#/components/schemas/InternationalizationMessage" - default: - oneOf: - - type: boolean - - type: integer - - type: string - description: | - 属性の初期値です。 - - 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 - - * type が flag の場合: 真偽値(`true` or `false`) - * type が integer の場合: 整数値 - * type が text の場合: 文字列 - * type が comment の場合: 文字列 - * type が choice の場合: 選択肢(`choices`)の `choice_id` - * type が select の場合: 選択肢(`choices`)の `choice_id` - - 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 - - なお、トラッキングとリンクには初期値を設定できません。 - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - type: - $ref: "#/components/schemas/AdditionalDataDefinitionType" - choices: - type: array - items: - type: object - properties: - choice_id: - $ref: "#/components/schemas/ChoiceId" - name: - $ref: "#/components/schemas/InternationalizationMessage" - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - AdditionalDataRestriction: - type: object - properties: - additional_data_definition_id: - $ref: "#/components/schemas/AdditionalDataDefinitionId" - condition: - $ref: "#/components/schemas/AdditionalDataRestrictionCondition" - AdditionalDataRestrictionCondition: - oneOf: - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionCanInput" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionEquals" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionNotEquals" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionMatches" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionNotMatches" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionHasLabel" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionImply" - AdditionalDataRestrictionConditionCanInput: - type: object - description: | - enable=false とすることで、入力を許可しないようにできます。 - Imply との組み合わせで、特定条件下のみ入力を許すといった制限ができます。 - properties: - _type: - type: string - example: "CanInput" - enable: - type: boolean - AdditionalDataRestrictionConditionEquals: - type: object - description: 指定された値と等しいことを要求します。 - properties: - _type: - type: string - example: "Equals" - value: - type: string - AdditionalDataRestrictionConditionNotEquals: - type: object - description: | - 指定された値と異なることを要求します。 - value に "" を指定することで、入力を必須とすることができます。 - properties: - _type: - type: string - example: "NotEquals" - value: - type: string - AdditionalDataRestrictionConditionMatches: - type: object - description: 指定された正規表現に合致することを要求します。 - properties: - _type: - type: string - example: "Matches" - value: - type: string - AdditionalDataRestrictionConditionNotMatches: - type: object - description: 指定された正規表現に合致しないことを要求します。 - properties: - _type: - type: string - example: "NotMatches" - value: - type: string - AdditionalDataRestrictionConditionHasLabel: - type: object - description: リンク属性において、リンク先として指定可能なラベルIDを制限します。 - properties: - _type: - type: string - example: "HasLabel" - values: - type: string - AdditionalDataRestrictionConditionImply: - type: object - description: | - premise で指定された条件を満たすとき、condition で指定された条件を満たすことを要求します。 - properties: - premise: - $ref: "#/components/schemas/AdditionalDataRestriction" - condition: - $ref: "#/components/schemas/AdditionalDataRestrictionCondition" - Keybind: - type: object - properties: - code: - type: string - shift: - type: boolean - ctrl: - type: boolean - alt: - type: boolean - Task: - type: object - required: - - project_id - - task_id - - phase - - phase_stage - - status - - input_data_id_list - - work_time_span - - updated_datetime - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - phase: - $ref: "#/components/schemas/TaskPhase" - phase_stage: - $ref: "#/components/schemas/TaskPhaseStage" - status: - $ref: "#/components/schemas/TaskStatus" - input_data_id_list: - type: array - description: タスクに含まれる入力データのID - items: - $ref: "#/components/schemas/InputDataId" - account_id: - $ref: "#/components/schemas/AccountId" - histories_by_phase: - type: array - description: 簡易的なタスク履歴(あるフェーズを誰が担当したか) - items: - $ref: "#/components/schemas/TaskHistoryShort" - work_time_span: - type: integer - description: 累計実作業時間(ミリ秒) - number_of_rejections: - type: integer - deprecated: true - description: | - このタスクが差戻しされた回数(すべてのフェーズでの差戻し回数の合計 - - このフィールドは、どのフェーズで何回差戻されたかを区別できないため、廃止予定です。 - `histories_by_phase` で各フェーズの回数を計算することで、差戻し回数が分かります。 - - 例)`acceptance`フェーズが3回ある場合、`acceptance`フェーズで2回差し戻しされたことになります。 - started_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - sampling: - type: string - enum: - - inspection_skipped - - inspection_stages_skipped - - acceptance_skipped - - inspection_and_acceptance_skipped - description: | - * `inspection_skipped` - このタスクが抜取検査の対象外となり、検査フェーズをスキップしたことを表す。 - * `inspection_stages_skipped` - このタスクが抜取検査の対象外となり、検査フェーズのステージを一部スキップしたことを表す。 - * `acceptance_skipped` - このタスクが抜取検査の対象外となり、受入フェーズをスキップしたことを表す。 - * `inspection_and_acceptance_skipped` - このタスクが抜取検査の対象外となり、検査・受入フェーズをスキップしたことを表す - - 未指定時はこのタスクが抜取検査の対象となったことを表す。(通常のワークフローを通過する) - TaskPhase: - type: string - enum: - - annotation - - inspection - - acceptance - description: | - * `annotation` - 教師付け。 - * `inspection` - 中間検査。ワークフローが3フェーズのときのみ。 - * `acceptance` - 受入。 - TaskPhaseStage: - type: integer - minimum: 1 - TaskStatus: - type: string - enum: - - not_started - - working - - on_hold - - break - - complete - - rejected - - cancelled - description: | - * `not_started` - 未着手。 - * `working` - 作業中。誰かが実際にエディタ上で作業している状態。 - * `on_hold` - 保留。作業ルールの確認などで作業できない状態。 - * `break` - 休憩中。 - * `complete` - 完了。次のフェーズへ進む - * `rejected` - 差戻し。修正のため、`annotation`フェーズへ戻る。[operateTask](#operation/operateTask) APIのリクエストボディに渡すときのみ利用する。その他のAPIのリクエストやレスポンスには使われない。 - * `cancelled` - 提出取消し。修正のため、前フェーズへ戻る。[operateTask](#operation/operateTask) APIのリクエストボディに渡すときのみ利用する。その他のAPIのリクエストやレスポンスには使われない。 - TaskRequest: - type: object - required: - - input_data_id_list - properties: - input_data_id_list: - type: array - items: - $ref: "#/components/schemas/InputDataId" - TaskGenerateRequest: - type: object - required: - - task_generate_rule - - project_last_updated_datetime - properties: - task_generate_rule: - description: | - * `TaskGenerateRuleByCount`: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 - * `TaskGenerateRuleByDirectory`: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。 - * `TaskGenerateRuleByInputDataCsv`: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 - oneOf: - - $ref: "#/components/schemas/TaskGenerateRuleByCount" - - $ref: "#/components/schemas/TaskGenerateRuleByDirectory" - - $ref: "#/components/schemas/TaskGenerateRuleByInputDataCsv" - project_last_updated_datetime: - type: string - format: date-time - description: プロジェクトの最終更新日時([getProject](#operation/getProject) APIのレスポンス `updated_datetime`)。タスク生成の排他制御に使用。 - TaskGenerateRuleByCount: - description: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 - type: object - required: - - task_id_prefix - - allow_duplicate_input_data - - input_data_count - - input_data_order - properties: - task_id_prefix: - type: string - description: | - 生成するタスクIDのプレフィックス。[値の制約についてはこちら。](#section/API-Convention/APIID) - allow_duplicate_input_data: - type: boolean - description: falseのときは、既にタスクに使われている入力データを除外し、まだタスクに使われていない入力データだけを新しいタスクに割り当てます。trueのときは、既にタスクに使われている入力データを除外しません。 - input_data_count: - type: integer - description: 1つのタスクに割り当てる入力データの個数 - example: 10 - input_data_order: - $ref: "#/components/schemas/InputDataOrder" - _type: - type: string - description: | - `ByCount` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "ByCount" - TaskGenerateRuleByDirectory: - description: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。
- type: object - required: - - task_id_prefix - properties: - task_id_prefix: - type: string - description: | - 生成するタスクIDのプレフィックス。[値の制約についてはこちら。](#section/API-Convention/APIID) - input_data_name_prefix: - type: string - description: タスク生成対象の入力データ名プレフィックス - _type: - type: string - description: | - `ByDirectory` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "ByDirectory" - TaskGenerateRuleByInputDataCsv: - description: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 - type: object - required: - - csv_data_path - properties: - csv_data_path: - type: string - description: 各タスクへの入力データへの割当を記入したCSVへのS3上のパス - example: "s3://ANNOFAB-BUCKET/PATH/TO/CSV" - _type: - type: string - description: | - `ByInputDataCsv` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "ByInputDataCsv" - InputDataOrder: - type: string - enum: - - name_asc - - name_desc - - random - description: | - タスクに割り当てる入力データの順序 - - * `name_asc` - 入力データ名 昇順(a, b, c, ...)。日付や番号などの連続するデータ名を扱う場合に推奨 - * `name_desc` - 入力データ名 降順(z, y, x, ...) - * `random` - ランダム - TaskOperation: - type: object - required: - - status - - last_updated_datetime - properties: - status: - description: | - 次に遷移させるタスクの状態。[詳細はこちら](#section/TaskStatus)。 - allOf: - - $ref: "#/components/schemas/TaskStatus" - last_updated_datetime: - allOf: - - $ref: "#/components/schemas/LastUpdatedDatetime" - description: | - タスクの最終更新日時 - account_id: - allOf: - - $ref: "#/components/schemas/AccountId" - description: 変更後の担当者のアカウントID。担当者を未割り当てにする場合は未指定。 - force: - type: boolean - default: false - description: | - タスクの強制操作を行う場合に立てるフラグ。現在、強制操作は強制差戻しのみがサポートされています。 - TaskStart: - type: object - properties: - phase: - allOf: - - $ref: "#/components/schemas/TaskPhase" - - description: 開始するタスクのフェーズ - TaskAssignRequest: - type: object - required: - - request_type - properties: - request_type: - description: | - * `TaskAssignRequestTypeRandom`: タスクフェーズのみを指定してランダムにタスクを自身に割当します。プロジェクト設定でタスクのランダム割当を有効にした場合のみ利用できます。 - * `TaskAssignRequestTypeSelection`: 担当者とタスクを明示的に指定してタスクを割当します。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。プロジェクト設定でタスクの選択割当を有効にした場合のみ利用できます。 - oneOf: - - $ref: "#/components/schemas/TaskAssignRequestTypeRandom" - - $ref: "#/components/schemas/TaskAssignRequestTypeSelection" - TaskAssignRequestTypeRandom: - type: object - required: - - phase - properties: - phase: - description: 割当するタスクフェーズ。[詳細はこちら](#section/TaskPhase) - allOf: - - $ref: "#/components/schemas/TaskPhase" - _type: - type: string - description: Random - example: "Random" - TaskAssignRequestTypeSelection: - type: object - required: - - user_id - - task_ids - properties: - user_id: - description: タスクを誰に割当するか - allOf: - - $ref: "#/components/schemas/UserId" - task_ids: - description: 割当するタスクのID - type: array - items: - $ref: "#/components/schemas/TaskId" - _type: - type: string - description: Selection - example: "Selection" - TaskHistoryShort: - description: タスクのあるフェーズを誰が担当したかを表します。 - type: object - required: - - phase - - phase_stage - - account_id - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - phase_stage: - type: integer - default: 1 - minimum: 1 - account_id: - $ref: "#/components/schemas/AccountId" - worked: - type: boolean - description: そのフェーズでタスクの作業を行ったかどうか(行った場合はtrue) - default: false - TaskHistory: - description: タスクのあるフェーズで、誰がいつどれくらいの作業時間を費やしたかを表すタスク履歴です。 - type: object - required: - - project_id - - task_id - - task_history_id - - accumulated_labor_time_milliseconds - - phase - - phase_stage - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - task_history_id: - $ref: "#/components/schemas/TaskHistoryId" - started_datetime: - type: string - format: date-time - ended_datetime: - type: string - format: date-time - accumulated_labor_time_milliseconds: - type: string - description: 累計実作業時間(ISO 8601 duration) - example: "PT34H17M36.789S" - phase: - $ref: "#/components/schemas/TaskPhase" - phase_stage: - type: integer - minimum: 1 - account_id: - $ref: "#/components/schemas/AccountId" - TaskHistoryEvent: - description: タスク履歴イベントは、タスクの状態が変化した1時点を表します。作業時間は、複数のこれらイベントを集約して計算するものなので、このオブジェクトには含まれません。 - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - task_history_id: - $ref: "#/components/schemas/TaskHistoryId" - created_datetime: - type: string - format: date-time - phase: - $ref: "#/components/schemas/TaskPhase" - phase_stage: - type: integer - default: 1 - minimum: 1 - status: - $ref: "#/components/schemas/TaskStatus" - account_id: - $ref: "#/components/schemas/AccountId" - request: - $ref: "#/components/schemas/TaskOperation" - TaskValidation: - description: タスクの全入力データに対するバリデーション結果です。 - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - inputs: - type: array - items: - $ref: "#/components/schemas/InputDataSummary" - InputDataSummary: - description: ある入力データのバリデーション結果です。入力データIDをキーに引けるようにMap[入力データID, バリデーション結果]となっています - type: object - properties: - input_data_id: - $ref: "#/components/schemas/InputDataId" - inspection_summary: - $ref: "#/components/schemas/InspectionSummary" - annotation_summaries: - type: array - items: - $ref: "#/components/schemas/ValidationError" - InspectionSummary: - type: string - enum: - - no_inspection - - no_comment_inspection - - new_reply_to_unprocessed - - new_unprocessed_inspection - - unprocessed - - complete - description: | - - `no_inspection` - 入力データに検査コメントが付けられていない。 - - `no_comment_inspection` - 入力データに空の検査コメントが付けられている。 - - `new_reply_to_unprocessed` - 現在進行中の検査・受入フェーズで未処理の検査コメントに対して新たに返信が付けられている。 - - `new_unprocessed_inspection` - 現在進行中の検査・受入フェーズでつけられた検査コメントのうち、未処理のものが1つ以上ある。 - - `unprocessed` - 過去の検査・受入フェーズでつけられた検査コメントのうち、未処理のものが1つ以上ある。 - - `complete` - 入力データにつけられた検査コメントで未処理のものがない。 - InputData: - description: 入力データの情報を表すデータ構造です。 - type: object - required: - - input_data_id - - project_id - - input_data_name - - input_data_path - - updated_datetime - properties: - input_data_id: - $ref: "#/components/schemas/InputDataId" - project_id: - $ref: "#/components/schemas/ProjectId" - input_data_name: - type: string - description: 表示用の名前です。 - input_data_path: - type: string - example: "s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA" - description: | - 入力データの実体が保存されたパスです。 - s3スキーマまたはhttpsスキーマのみサポートしています。 - url: - type: string - description: | - 入力データを取得するためのhttpsスキーマのURLです。 - - このURLはセキュリティのために認証認可が必要となっており、URLだけでは入力データを参照できません。 - このURLは内部用であり、常に変更になる可能性があります。そのため、アクセスは保証外となります。 - また、このURLのレスポンスは最低1時間キャッシュされます。 - キャッシュを無効にしたい場合は、クエリパラメータにアクセス毎にランダムなUUIDなどを付与してください。 - - 設定の不備等でデータが取得できない場合、この属性は設定されません。 - etag: - type: string - original_input_data_path: - type: string - example: "s3://YOUR-BUCKET/PATH/TO/INPUT_DATA" - description: | - AF外部のストレージから登録された場合、その外部ストレージ中のパス。 - それ以外の場合は値なし - original_resolution: - allOf: - - $ref: "#/components/schemas/Resolution" - - description: | - 入力データの元画像サイズ。 - 入力データ登録時に画像がリサイズされた場合のみ設定される。 - resized_resolution: - allOf: - - $ref: "#/components/schemas/Resolution" - - description: | - 入力データのリサイズ後サイズ。 - 入力データ登録時に画像がリサイズされた場合のみ設定される。 - input_duration: - type: number + - name: status + in: query description: | - 入力データが動画の場合、動画の長さ(秒)。小数点以下はミリ秒以下を表します。 - - 動画の長さが取得できなかった場合、あるいは入力データが画像の場合は値なし。 - updated_datetime: - type: string - format: date-time - sign_required: - type: boolean + 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectStatus + - name: input_data_type + in: query description: | - データがSigned Cookieによるクロスオリジン配信に対応しているか否かです。 - metadata: - type: object + 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataType + - name: sort_by + in: query description: | - ユーザーが自由に登録できるkey-value型のメタデータです。主にカスタムエディタで使われることを想定しています。 - additionalProperties: + `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 + 未指定時はプロジェクト名でソートする。 + required: false + schema: type: string - InputDataRequest: - type: object - required: - - input_data_name - - input_data_path - properties: - input_data_name: - type: string - description: 表示用の名前 - input_data_path: - type: string - example: "s3://YOUR-BUCKET/PATH/TO/OBJECT" - description: | - AnnoFabに登録する入力データの実体が保存されたパスです。 - - 対応スキーマ: - * s3 - * https - - 場面別の使い分け: - * [一時データ保存先取得API](#operation/createTempPath)を使ってAFにアップロードした場合: `s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA` - * [プライベートストレージ](/docs/faq/#prst9c)の場合 - * `https://YOUR-DOMAIN/PATH/TO/INPUT_DATA` - * `s3://YOUR-BUCKET-FOR-PRIVATE-STORAGE/PATH/TO/INPUT_DATA` - * S3プライベートストレージのパスを登録する場合、[事前に認可の設定が必要](/docs/faq/#m0b240)です。 - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - sign_required: - type: boolean - description: | - データがSigned Cookieによるクロスオリジン配信に対応しているか否かです。
- このオプションを有効にする場合は、`input_data_path`として、AnnoFabのAWS IDをTrusted Signerとして登録したCloudFrontのURLを指定してください。 - metadata: - type: object + example: date + - name: cache + in: query description: | - ユーザーが自由に登録できるkey-value型のメタデータです。主にカスタムエディタで使われることを想定しています。 - additionalProperties: + CACHE TIMESTAMP + required: false + schema: type: string - SupplementaryData: - type: object - required: - - project_id - - input_data_id - - supplementary_data_id - - supplementary_data_name - - supplementary_data_path - - supplementary_data_type - - supplementary_data_number - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - supplementary_data_id: - $ref: "#/components/schemas/SupplementaryDataId" - supplementary_data_name: - type: string - description: 表示用の名前 - supplementary_data_path: - type: string - example: "s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA" - description: | - 補助情報の実体が保存されたパスです。 - s3スキーマまたはhttpsスキーマのみサポートしています。 - url: - type: string - format: uri - deprecated: true - description: このフィールドはAF内部での利用のみを想定しており、依存しないでください。 - etag: - type: string - supplementary_data_type: - $ref: "#/components/schemas/SupplementaryDataType" - supplementary_data_number: - type: integer - description: 表示順を表す数値(昇順)。同じ入力データに対して複数の補助情報で表示順が重複する場合、順序不定になります。 - updated_datetime: - type: string - format: date-time - SupplementaryDataType: - type: string - enum: - - image - - text - SupplementaryDataRequest: - type: object - required: - - supplementary_data_name - - supplementary_data_path - - supplementary_data_type - - supplementary_data_number - properties: - supplementary_data_name: - type: string - description: 表示用の名前 - supplementary_data_path: - type: string - example: "s3://YOUR-BUCKET/PATH/TO/OBJECT" - description: | - AnnoFabに登録する補助情報の実体が保存されたパスです。 - - 対応スキーマ:s3, https - - * [一時データ保存先取得API](#operation/createTempPath)を使ってAFにアップロードしたファイルパスの場合 - * `s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA` - * 補助情報作成/更新API成功時、アップロードしたファイルが一時データ保存先からコピーされます。 - * APIのレスポンスからアップロードしたファイルのコピー先パス(s3スキーマ)を取得できます。 - * すでにAFに登録されている補助情報のパスの場合 - * `s3://ANNOFAB-SUPPLEMENTARY-BUCKET/PATH/TO/INPUT_DATA` - * ファイルはコピーされません。 - * [プライベートストレージ](/docs/faq/#prst9c)のパスの場合 - * `https://YOUR-DOMAIN/PATH/TO/INPUT_DATA` - * `s3://YOUR-BUCKET-FOR-PRIVATE-STORAGE/PATH/TO/INPUT_DATA` - * S3プライベートストレージのパスを登録する場合、[事前に認可の設定が必要](/docs/faq/#m0b240)です。 - * AFにファイルはコピーされません。 - supplementary_data_type: - $ref: "#/components/schemas/SupplementaryDataType" - - supplementary_data_number: - type: integer - description: 表示順を表す数値(昇順)。同じ入力データに対して複数の補助情報で表示順が重複する場合、順序不定になります。 - last_updated_datetime: - type: string - format: date-time - WebhookTestRequest: - type: object - properties: - placeholders: - description: プレースホルダ名と置換する値 - type: object - example: - SOME_PLACEHOLDER: value - SOME_NAME: value2 - WebhookTestResponse: - type: object - properties: - result: - description: | - * success: 通知先から正常なレスポンス(2xx系)を受け取った - * failure: 通知先からエラーレスポンス(2xx系以外)を受け取った - * error: リクエスト送信に失敗した、もしくはレスポンスを受信できなかった - type: string - enum: [success, failure, error] - example: success - request_body: - description: 実際に送信されたリクエストボディ - type: string - response_status: - description: 通知先から返されたHTTPステータスコード - type: integer - example: 200 - response_body: - description: 通知先から返されたレスポンスボディ - type: string - message: - description: result="error" 時のエラー内容等 - type: string - BatchInputDataRequestItemDelete: - type: object - description: 入力データ削除 - required: - - project_id - - input_data_id - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - _type: - type: string - description: | - `Delete` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Delete" - BatchTaskRequestItemDelete: - type: object - description: タスク削除 - required: - - project_id - - task_id - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - _type: - type: string - description: | - `Delete` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Delete" - DataPath: - type: object - properties: - url: - type: string - format: uri - example: "https://s3..amazonaws.com///?param1=...¶m2=..." - description: ファイルアップロード用の一時URLです。このURLにファイルをアップロードします。 - path: - type: string - example: s3://// - description: アップロードしたファイルをAFの [入力データ](#tag/af-input) や [補助情報](#tag/af-supplementary) に登録するとき、この`path`を指定します。 - InstructionImagePath: - type: object - required: - - url - - path - properties: - url: - type: string - format: uri - example: "https://s3..amazonaws.com///?param1=...¶m2=..." - description: ファイルアップロード用の一時URLです。このURLにファイルをアップロードします。 - path: - type: string - format: url - example: https://annofab.com/projects/{project_id}/instruction-images/{image_id} - description: 作業ガイド画像のURL - AnnotationQuery: - type: object - properties: - task_id: - $ref: "#/components/schemas/TaskId" - exact_match_task_id: - description: | - タスクIDの検索方法を指定します。 - trueの場合は完全一致検索、falseの場合は中間一致検索です。 - type: boolean - default: true - input_data_id: - $ref: "#/components/schemas/InputDataId" - exact_match_input_data_id: - description: | - 入力データIDの検索方法を指定します。 - trueの場合は完全一致検索、falseの場合は中間一致検索です。 - type: boolean - default: true - label_id: - $ref: "#/components/schemas/LabelId" - attributes: - type: array - items: - $ref: "#/components/schemas/AdditionalData" - Annotation: - type: object - required: - - project_id - - task_id - - input_data_id - - details - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - details: - type: array - description: 矩形、ポリゴン、全体アノテーションなど個々のアノテーションの配列。 - items: - $ref: "#/components/schemas/AnnotationDetail" - updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - AnnotationDataHoldingType: - type: string - enum: - - inner - - outer - description: | - * `inner` - アノテーションのデータ部をJSON内部に保持します。 - * `outer` - アノテーションのデータ部を外部ファイルの形式(画像など)で保持します - AnnotationDetail: - type: object - required: - - annotation_id - - account_id - - label_id - - is_protected - - data_holding_type - - additional_data_list - properties: - annotation_id: - $ref: "#/components/schemas/AnnotationId" - account_id: - description: アノテーションを作成したユーザのアカウントID。 - allOf: - - $ref: "#/components/schemas/AccountId" - label_id: - description: ラベルID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 - allOf: - - $ref: "#/components/schemas/LabelId" - is_protected: - description: | - `true`の場合、アノテーションをアノテーションエディタ上での削除から保護できます。 - 外部から取り込んだアノテーションに属性を追加するときなどに指定すると、データの削除を防げます。 - type: boolean - default: false - data_holding_type: - $ref: "#/components/schemas/AnnotationDataHoldingType" - data: - oneOf: - - type: string - - $ref: "#/components/schemas/FullAnnotationData" - description: | - アノテーションの座標値や区間などのデータ。レスポンスの場合は`string`形式、[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は`string`または`object`形式です。 - `annotation_type`に応じて`string`,`object`の形式が変わります。 - - - - - - - - - - -
annotation_typedata_holding_typestring形式object形式
bounding_box inner左上x,左上y,右下x,右下yFullAnnotationDataBoundingBox
pointinnerx1,y1FullAnnotationDataSinglePoint
polygon / polyline innerx1,y1,x2,y2, ... FullAnnotationDataPoints
range inner開始時間(ミリ秒),終了時間(ミリ秒) FullAnnotationDataRange
classification innernull FullAnnotationDataClassification / null
segmentationouternull FullAnnotationDataSegmentation / null
segmentation_v2 outernull FullAnnotationDataSegmentationV2 / null
- path: - type: string - description: | - 外部ファイルに保存されたアノテーションのパス。`data_holding_type`が`inner`の場合は未指定です。 - レスポンスの場合は`annotation_id`と同じ値が格納されます。 - - [putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は、[createTempPath](#operation/createTempPath) APIで取得できる一時データ保存先S3パスを格納してください。 - 更新しない場合は、[getEditorAnnotation](#operation/getEditorAnnotation) APIで取得した`path`をそのまま渡せます。 - - 外部ファイルのフォーマットは下表の通りです。 - - - - -
annotation_type形式
segmentation / segmentation_v2 PNG画像。塗りつぶした部分はrgba(255, 255, 255, 1) 、塗りつぶしていない部分はrgba(0, 0, 0, 0)
- etag: - type: string - description: 外部ファイルに保存されたアノテーションのETag。`data_holding_type`が`inner`の場合、または[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は未指定です。 - url: - type: string - format: uri - description: 外部ファイルに保存されたアノテーションの認証済み一時URL。`data_holding_type`が`inner`の場合、または[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は未指定です。 - additional_data_list: - type: array - description: | - 各要素は、 [アノテーション仕様](#operation/getAnnotationSpecs)で定義された属性(`additional_data_definitions`内)のいずれかの要素と対応づけます。 - 各要素は、どの属性なのかを表す`additional_data_definition_id`と値が必要です。値は、属性の種類に対応するキーに格納します(下表)。 - - - - - - - - -
アノテーション属性の種類
additional_data_definitiontype
属性の値を格納するキーデータ型
text, comment または trackingcommentstring
flagflagboolean
integerintegerinteger
choice または selectchoicestring(選択肢ID)
linkcommentstring(アノテーションID)
- items: - $ref: "#/components/schemas/AdditionalData" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - AdditionalData: - type: object - required: - - additional_data_definition_id - properties: - additional_data_definition_id: - description: 属性ID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 - allOf: - - $ref: "#/components/schemas/AdditionalDataDefinitionId" - flag: - type: boolean - description: | - `additional_data_definition`の`type`が`flag`のときの属性値。 - integer: - type: integer - description: | - `additional_data_definition`の`type`が`integer`のときの属性値。 - comment: - type: string - description: | - `additional_data_definition`の`type`が`text`,`comment`,`link` または `tracking`のときの属性値。 - choice: - description: | - `additional_data_definition`の`type`が`choice` または `select `のときの属性値(選択肢ID)。 - allOf: - - $ref: "#/components/schemas/ChoiceId" - AdditionalDataValue: - oneOf: - - type: object - - $ref: "#/components/schemas/AdditionalDataValueFlag" - - $ref: "#/components/schemas/AdditionalDataValueInteger" - - $ref: "#/components/schemas/AdditionalDataValueComment" - - $ref: "#/components/schemas/AdditionalDataValueChoice" - - $ref: "#/components/schemas/AdditionalDataValueTracking" - - $ref: "#/components/schemas/AdditionalDataValueLink" - AdditionalDataValueFlag: - type: object - required: - - _type - - value - properties: - _type: - type: string - description: Flag - example: "Flag" - value: - type: boolean - description: フラグのON(true)またはOFF(false) - AdditionalDataValueInteger: - type: object - required: - - _type - properties: - _type: - type: string - description: Integer - example: "Integer" - value: - type: integer - description: 整数値 - AdditionalDataValueComment: - type: object - required: - - _type - properties: - _type: - type: string - description: Comment - example: "Comment" - value: - type: string - description: 自由記述 - AdditionalDataValueChoice: - type: object - required: - - _type - properties: - _type: - type: string - description: Choice - example: "Choice" - value: - $ref: "#/components/schemas/AdditionalDataChoiceValue" - AdditionalDataChoiceValue: - type: object - required: - - id - - name - properties: - id: - allOf: - - $ref: "#/components/schemas/ChoiceId" - - description: 選択された選択肢のID - name: - allOf: - - $ref: "#/components/schemas/InternationalizationMessage" - - description: 選択された選択肢の表示名 - AdditionalDataValueTracking: - type: object - required: - - _type - properties: - _type: - type: string - description: Tracking - example: "Tracking" - value: - type: string - description: トラッキングID - AdditionalDataValueLink: - type: object - required: - - _type - properties: - _type: - type: string - description: Link - example: "Link" - value: - type: string - description: リンク先アノテーションID - SingleAnnotation: - type: object - required: - - project_id - - task_id - - input_data_id - - detail - - updated_datetime - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - detail: - $ref: "#/components/schemas/SingleAnnotationDetail" - updated_datetime: - type: string - format: date-time - SimpleAnnotation: - type: object - required: - - annotation_format_version - - project_id - - task_id - - task_phase - - task_phase_stage - - task_status - - input_data_id - - input_data_name - - details - properties: - annotation_format_version: - $ref: "#/components/schemas/AnnotationFormatVersion" - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - task_phase: - $ref: "#/components/schemas/TaskPhase" - task_phase_stage: - type: integer - default: 1 - minimum: 1 - task_status: - $ref: "#/components/schemas/TaskStatus" - input_data_id: - $ref: "#/components/schemas/InputDataId" - input_data_name: - type: string - description: 入力データ名 - details: - type: array - description: 矩形、ポリゴン、全体アノテーションなど個々のアノテーションの配列。 - items: - $ref: "#/components/schemas/SimpleAnnotationDetail" - updated_datetime: - type: string - format: date-time - description: 更新日時。アノテーションが一つもない場合(教師付作業が未着手のときなど)は、未指定。 - BatchAnnotation: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - annotation_id: - $ref: "#/components/schemas/AnnotationId" - label_id: - $ref: "#/components/schemas/LabelId" - additional_data_list: - type: array - items: - $ref: "#/components/schemas/AdditionalData" - updated_datetime: - type: string - format: date-time - BatchAnnotationRequestItemPut: - type: object - description: アノテーション更新 - required: - - data - properties: - data: - $ref: "#/components/schemas/BatchAnnotation" - _type: - type: string - description: | - `Put` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Put" - BatchAnnotationRequestItemDelete: - type: object - description: アノテーション削除 - required: - - project_id - - task_id - - input_data_id - - annotation_id - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - annotation_id: - $ref: "#/components/schemas/AnnotationId" - updated_datetime: - type: string - format: date-time - _type: - type: string - description: | - `Delete` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Delete" - SingleAnnotationDetail: - type: object - required: - - annotation_id - - account_id - - label_id - - data_holding_type - - additional_data_list - - created_datetime - - updated_datetime - properties: - annotation_id: - $ref: "#/components/schemas/AnnotationId" - account_id: - $ref: "#/components/schemas/AccountId" - label_id: - $ref: "#/components/schemas/LabelId" - data_holding_type: - $ref: "#/components/schemas/AnnotationDataHoldingType" - data: - $ref: "#/components/schemas/FullAnnotationData" - etag: - type: string - description: data_holding_typeがouterの場合のみ存在し、データのETagが格納される - url: - type: string - format: uri - description: data_holding_typeがouterの場合のみ存在し、データへの一時URLが格納される - additional_data_list: - type: array - items: - $ref: "#/components/schemas/AdditionalData" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - SimpleAnnotationDetail: - type: object - required: - - label - - annotation_id - - data - - attributes - properties: - label: - type: string - example: "pedestrian" - description: | - アノテーション仕様のラベル名です。 - annotation_id: - type: string - example: "acb5359e-be2e-402b-b59a-b5fdbb378ad9" - description: | - 個々のアノテーションにつけられたIDです。 - data: - $ref: "#/components/schemas/FullAnnotationData" - attributes: - type: object - description: | - キーに属性の名前、値に各属性の値が入った辞書構造です。 - example: - maker: "AAA Motors" - size: 12345 - is_foo_bar_buz: true - FullAnnotation: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - task_phase: - $ref: "#/components/schemas/TaskPhase" - task_phase_stage: - type: integer - default: 1 - minimum: 1 - task_status: - $ref: "#/components/schemas/TaskStatus" - input_data_id: - $ref: "#/components/schemas/InputDataId" - input_data_name: - type: string - details: - type: array - items: - $ref: "#/components/schemas/FullAnnotationDetail" - updated_datetime: - type: string - format: date-time - annotation_format_version: - $ref: "#/components/schemas/AnnotationFormatVersion" - FullAnnotationDetail: - type: object - properties: - annotation_id: - $ref: "#/components/schemas/AnnotationId" - user_id: - $ref: "#/components/schemas/UserId" - label_id: - $ref: "#/components/schemas/LabelId" - label_name: - $ref: "#/components/schemas/InternationalizationMessage" - annotation_type: - $ref: "#/components/schemas/AnnotationType" - data_holding_type: - $ref: "#/components/schemas/AnnotationDataHoldingType" - data: - $ref: "#/components/schemas/FullAnnotationData" - additional_data_list: - type: array - items: - $ref: "#/components/schemas/FullAnnotationAdditionalData" - FullAnnotationData: - oneOf: - - type: object - - $ref: "#/components/schemas/FullAnnotationDataClassification" - - $ref: "#/components/schemas/FullAnnotationDataSegmentation" - - $ref: "#/components/schemas/FullAnnotationDataSegmentationV2" - - $ref: "#/components/schemas/FullAnnotationDataBoundingBox" - - $ref: "#/components/schemas/FullAnnotationDataPoints" - - $ref: "#/components/schemas/FullAnnotationDataSinglePoint" - - $ref: "#/components/schemas/FullAnnotationDataRange" - - $ref: "#/components/schemas/FullAnnotationDataUnknown" - description: | - アノテーションのデータが格納されます。 - * `FullAnnotationDataClassification`: 入力データ全体に対するアノテーションデータです。 - * `FullAnnotationDataSegmentation`: ピクセルレベルでの塗りつぶし(ラスター)のアノテーションデータです。 - * `FullAnnotationDataSegmentationV2`: 塗りつぶしv2ののアノテーションデータです。塗りつぶしv2はSemantic Segmentationに特化しています。 - * `FullAnnotationDataBoundingBox`: 矩形のアノテーションデータです。 - * `FullAnnotationDataPoints`: ポリゴン(閉じた頂点集合)のアノテーションデータです。 - * `FullAnnotationDataSegmentation`: 点のアノテーションデータです。 - * `FullAnnotationDataRange`: 動画区間のアノテーションデータです。 - FullAnnotationDataClassification: - type: object - required: - - _type - properties: - _type: - type: string - description: Classification - example: "Classification" - FullAnnotationDataSegmentation: - description: 塗っていないところは rgba(0,0,0,0)、塗ったところは rgba(255,255,255,1) の PNGデータをBase64エンコードしたもの。 - type: object - required: - - data_uri - - _type - properties: - data_uri: - type: string - _type: - type: string - description: Segmentation - example: "Segmentation" - FullAnnotationDataSegmentationV2: - type: object - required: - - data_uri - - _type - properties: - data_uri: - type: string - _type: - type: string - description: SegmentationV2 - example: "SegmentationV2" - FullAnnotationDataBoundingBox: - description: annotation_type が bounding_boxの場合に、[左上頂点座標, 右下頂点座標]を {"x":int, "y":int} の形式で記述したもの。 - type: object - required: - - left_top - - right_bottom - - _type - properties: - left_top: - $ref: "#/components/schemas/Point" - right_bottom: - $ref: "#/components/schemas/Point" - _type: - type: string - description: BoundingBox - example: "BoundingBox" - FullAnnotationDataPoints: - description: | - 頂点座標 {"x":int, "y":int} の配列。 - - * annotation_type が polygon/polyline の場合: ポリゴン/ポリラインを構成する頂点の配列。 - type: object - required: - - points - - _type - properties: - points: - type: array - items: - $ref: "#/components/schemas/Point" - _type: - type: string - description: Points - example: "Points" - FullAnnotationDataSinglePoint: - description: annotation_type が pointの場合。 - type: object - required: - - point - - _type - properties: - point: - $ref: "#/components/schemas/Point" - _type: - type: string - description: SinglePoint。 - example: "SinglePoint" - FullAnnotationDataRange: - description: annotation_type が rangeの場合に、[開始時間, 終了時間]を {"begin":number, "end":number} の形式で記述したもの。開始時間・終了時間の単位は秒で、精度はミリ秒まで。 - type: object - required: - - begin - - end - - _type - properties: - begin: - type: number - description: 開始時間(ミリ秒)。小数点以下はミリ秒以下を表します。 - end: - type: number - description: 終了時間(ミリ秒)。小数点以下はミリ秒以下を表します。 - _type: - type: string - description: Range - example: "Range" - FullAnnotationDataUnknown: - description: annotation_typeにデータ構造が一致していない場合に、元のdata文字列をそのまま記述したもの。 - type: object - required: - - data - - _type - properties: - data: - type: string - _type: - type: string - description: Unknown - example: "Unknown" - Point: - description: 座標 - type: object - required: - - x - - y - properties: - x: - type: integer - y: - type: integer - FullAnnotationAdditionalData: - type: object - properties: - additional_data_definition_id: - allOf: - - $ref: "#/components/schemas/AdditionalDataDefinitionId" - - description: 属性ID - additional_data_definition_name: - allOf: - - $ref: "#/components/schemas/InternationalizationMessage" - - description: 属性表示名 - type: - $ref: "#/components/schemas/AdditionalDataDefinitionType" - value: - $ref: "#/components/schemas/AdditionalDataValue" - BatchInspectionRequestItemPut: - type: object - description: 検査コメント更新 - required: - - data - properties: - data: - $ref: "#/components/schemas/Inspection" - _type: - type: string - description: | - `Put` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Put" - BatchInspectionRequestItemDelete: - type: object - description: 検査コメント削除 - required: - - project_id - - task_id - - input_data_id - - inspection_id - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - inspection_id: - $ref: "#/components/schemas/InspectionId" - _type: - type: string - description: | - `Delete` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Delete" - Inspection: - type: object - description: 検査コメント - required: - - project_id - - task_id - - input_data_id - - inspection_id - - phase - - phase_stage - - commenter_account_id - - data - - status - - comment - - created_datetime - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - inspection_id: - $ref: "#/components/schemas/InspectionId" - phase: - description: 検査コメントを付与したときのタスクフェーズ。[詳細はこちら](#section/TaskPhase) - allOf: - - $ref: "#/components/schemas/TaskPhase" - phase_stage: - type: integer - description: 検査コメントを付与したときのフェーズのステージ - default: 1 - minimum: 1 - commenter_account_id: - allOf: - - $ref: "#/components/schemas/AccountId" - description: 検査コメントを付与したユーザのアカウントID - annotation_id: - description: | - 検査コメントに紐づくアノテーションのID。アノテーションに紐付けられていない場合(アノテーションの付け忘れに対する指定など)は未指定。 - [詳細はこちら](#section/AnnotationId)。 - allOf: - - $ref: "#/components/schemas/AnnotationId" - data: - description: | - 検査コメントの座標値や区間。 - - * `InspectionDataPoint`:点で検査コメントを付与したときの座標値 - * `InspectionDataPolyline`:ポリラインで検査コメントを付与したときの座標値 - * `InspectionDataTime`:検査コメントを付与した区間(動画プロジェクトの場合) - oneOf: - - $ref: "#/components/schemas/InspectionDataPoint" - - $ref: "#/components/schemas/InspectionDataPolyline" - - $ref: "#/components/schemas/InspectionDataTime" - parent_inspection_id: - description: | - 返信先の検査コメントの検査ID。返信先の検査コメントは「スレッド内の直前のコメント」ではなく「スレッドの先頭のコメント」を指します。 - allOf: - - $ref: "#/components/schemas/InspectionId" - phrases: - type: array - description: 参照している定型指摘のID。 - items: - $ref: "#/components/schemas/PhraseId" - comment: - description: | - 検査コメントの中身 - type: string - example: 枠がズレています - status: - $ref: "#/components/schemas/InspectionStatus" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - InspectionDataPoint: - type: object - description: | - 問題のある部分を示す座標 - required: - - x - - y - properties: - x: - type: integer - y: - type: integer - _type: - type: string - description: | - `Point` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Point" - InspectionDataPolyline: - type: object - description: | - 問題のある部分を示すポリライン - required: - - coordinates - properties: - coordinates: - type: array - description: | - ポリラインを構成する頂点の配列 - items: - type: object - properties: - x: - type: integer - y: - type: integer - _type: - type: string - description: | - `Polyline` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Polyline" - InspectionDataTime: - type: object - description: | - 問題のある時間帯を表す区間 - required: - - start - - end - properties: - start: - type: number - description: 開始時間(ミリ秒)。小数点以下はミリ秒以下を表します。 - end: - type: number - description: 終了時間(ミリ秒)。小数点以下はミリ秒以下を表します。 - _type: - type: string - description: | - `Time` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Time" - Resolution: - type: object - required: - - width - - height - properties: - width: - type: number - height: - type: number - InspectionStatus: - type: string - enum: - - annotator_action_required - - no_correction_required - - error_corrected - - no_comment_inspection - description: | - * `annotator_action_required` - 未処置。`annotation`フェーズ担当者が何らかの回答をする必要あり - * `no_correction_required` - 処置不要。`annotation`フェーズ担当者が、検査コメントによる修正は不要、と回答した - * `error_corrected` - 修正済み。`annotation`フェーズ担当者が、検査コメントの指示どおり修正した - * `no_comment_inspection` - 作成途中。検査コメントの中身が未入力 - AggregationResult: - oneOf: - - type: object - - $ref: "#/components/schemas/CountResult" - CountResult: - type: object - properties: - _type: - type: string - example: "CountResult" - description: | - 他と区別するために `CountResult` を指定します - name: - type: string - field: - type: string - items: - type: array - items: - $ref: "#/components/schemas/Count" - Count: - type: object - properties: - key: - type: string - count: - type: integer - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - Instruction: - type: object - properties: - html: - type: string - description: 作業ガイドのHTML - example: "

test

" - last_updated_datetime: - type: string - format: date-time - description: | - * [getInstruction](#operation/getInstruction) APIのレスポンスの場合: 最後に作業ガイドを更新した日時。 - * [putInstruction](#operation/putInstruction) APIのリクエストボディの場合: 最後に作業ガイドを更新した日時を指定する。まだ一度も保存した事がない場合は指定しない。 - InstructionHistory: - type: object - required: - - history_id - - account_id - - updated_datetime - properties: - history_id: - type: string - description: 作業ガイドの履歴ID - account_id: - type: string - description: 作業ガイドを更新したユーザのアカウントID - updated_datetime: - type: string - format: date-time - description: 作業ガイドの最終更新日時 - InstructionImage: - type: object - required: - - image_id - - path - - url - - etag - properties: - image_id: - type: string - description: 作業ガイド画像ID - path: - type: string - example: "s3://ANNOFAB-BUCKET/PATH/TO/INSTRUCTION_IMAGE" + example: "123456789" + responses: + "200": + description: 正常 + content: + application/json: + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectContainer + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/users/{account_id}": + get: + tags: + - af-users-v2 + summary: 個人情報取得 + description: "" + security: + - SignedCookieKeyPairId: [] + SignedCookiePolicy: [] + SignedCookieSignature: [] + operationId: getAccountV2 + parameters: + - name: account_id + in: path + description: アカウントID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + - name: cache + in: query description: | - 作業ガイド画像の実体が保存されたパスです。 - url: - type: string - format: uri - example: https://annofab.com/projects/{project_id}/instruction-images/{image_id} - description: - 作業ガイド画像を取得するための内部用URLです。 - etag: - type: string - ValidationError: - oneOf: - - type: object - - $ref: "#/components/schemas/InvalidAnnotationData" - - $ref: "#/components/schemas/DuplicatedSegmentationV2" - - $ref: "#/components/schemas/InvalidCommentFormat" - - $ref: "#/components/schemas/UnknownLinkTarget" - - $ref: "#/components/schemas/InvalidLinkTarget" - - $ref: "#/components/schemas/EmptyAttribute" - - $ref: "#/components/schemas/Duplicated" - - $ref: "#/components/schemas/UnknownAdditionalData" - - $ref: "#/components/schemas/OutOfImageBounds" - - $ref: "#/components/schemas/UnknownLabel" - InvalidAnnotationData: - type: object - description: アノテーションデータ不正エラー - properties: - labelId: - type: string - annotationId: - type: string - message: - type: string - _type: - type: string - description: InvalidAnnotationData - example: "InvalidAnnotationData" - DuplicatedSegmentationV2: - type: object - description: 塗りつぶしv2のラベルに対する1ラベルにつき1アノテーションまでの制約違反エラー - properties: - labelId: - type: string - annotationIds: - type: array - items: + CACHE TIMESTAMP + required: false + schema: type: string - _type: - type: string - description: DuplicatedSegmentationV2 - example: "DuplicatedSegmentationV2" - InvalidCommentFormat: - type: object - description: コメントが正規表現に合致しないエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: InvalidCommentFormat - example: "InvalidCommentFormat" - UnknownLinkTarget: - type: object - description: 指定されたIDに該当するアノテーションが存在しないエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: UnknownLinkTarget - example: "UnknownLinkTarget" - InvalidLinkTarget: - type: object - description: リンク先アノテーションが許可されているラベルでないエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: InvalidLinkTarget - example: "InvalidLinkTarget" - EmptyAttribute: - type: object - description: 属性が未入力であるエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: EmptyAttribute - example: "EmptyAttribute" - Duplicated: - type: object - description: 値の重複が許可されていない属性の重複エラー - properties: - labelId: - type: string - annotationId: - type: string - additionalData: - $ref: "#/components/schemas/AdditionalData" - _type: - type: string - description: Duplicated - example: "Duplicated" - UnknownAdditionalData: - type: object - description: 何らかの原因で、アノテーション仕様にない属性がついているエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: UnknownAdditionalData - example: "UnknownAdditionalData" - OutOfImageBounds: - type: object - description: 画像範囲外にアノテーションがはみ出しているエラー - properties: - labelId: - type: string - annotationId: - type: string - _type: - type: string - description: OutOfImageBounds - example: "OutOfImageBounds" - UnknownLabel: - type: object - description: 何らかの原因で、アノテーション仕様にないラベルがついているエラー - properties: - labelId: - type: string - annotationId: - type: string - _type: - type: string - description: UnknownLabel - example: "UnknownLabel" - ProjectTaskCounts: - type: object - properties: - task_counts: - type: array - items: - type: object - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - status: - $ref: "#/components/schemas/TaskStatus" - count: - description: 該当するタスクの数 - type: number + example: "123456789" + responses: + "200": + description: 正常 + content: + application/json: + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/MyAccount + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance diff --git a/generate/swagger/swagger.yaml b/generate/swagger/swagger.yaml index 6f52c972..8cfad982 100644 --- a/generate/swagger/swagger.yaml +++ b/generate/swagger/swagger.yaml @@ -1,39 +1,58 @@ - -openapi: "3.0.0" +openapi: 3.0.0 info: - description: | + description: > [AnnoFab](https://annofab.com) のWeb APIです。 + キャッシュが有効になって[大幅に高速化された v2 はこちら](/docs/api/v2) です。 + APIベースURL: https://annofab.com/api/v1
+ 例) /projects というAPIを使う場合、 https://annofab.com/api/v1/projects をリクエストします。 + ■APIの変更ポリシー
+ **現在、APIは開発途上版です。予告なく互換性のない変更がある可能性をご了承ください。** + ご要望の実現、あるいは、セキュリティやパフォーマンスの改善などを実現するにあたり、互換性のない変更が必要になる場合があります。 + その場合、開発途上版では開発リソースを改善に集中するため、古いバージョンを共存させずに互換性のない変更を行う場合があります。 + ■機能の要望や不具合報告
+ 「こんな機能が欲しい」というご要望や、「APIが予期せぬ動作をする」といった不具合報告などは、[こちらのお問い合わせフォーム](https://docs.google.com/forms/d/e/1FAIpQLSePryikS_wo_H11pxL2ewUe2d0ud0jxZlBQwH2rVVfcifKyQw/viewform)からご連絡ください。 + # API Client + APIクライアントも提供しています。 + * https://github.com/kurusugawa-computer/annofab-cli + * https://github.com/kurusugawa-computer/annofab-api-python-client + # API Convention + ## 用語 + * **属性○○○を必須**とは、「JSONに属性キー○○○を含め、かつ、その値が`null`以外」であること + * **属性○○○を未指定**とは、「JSONに属性キー○○○を含めない」または「属性○○○のキーはあるが値は`null`」のどちらかであること + ## 更新系APIのリクエストボディに必須の属性 + * 更新系APIとは、HTTPメソッドが **PUT** または **POST** のAPIです。 + * 更新系APIでは、更新対象の「リソースの最終更新日」を必須とする場合があります。 * これは、複数ユーザーからのAPIリクエストのデータ競合を避けるための、一般的なAPI設計慣習によるものです。 * ここで「リソースの最終更新日」とは、`last_updated_datetime` または `updated_datetime` という名前の属性です。 @@ -45,17 +64,23 @@ info: * 更新しようとしたリソースが存在しないとき、またはすでに更新されているときは、更新リクエストは失敗します。 * 「リソースの最終更新日」以外の属性については、新規作成/更新それぞれで必須が異なる場合、API個別に特筆されています。 + ## APIのリクエストボディに指定する _type 属性について + * 一部のAPIではリクエストボディに `_type` 属性を任意で指定することができます。 + * `_type` 属性を指定する場合は、`_type` 属性で指定された型にデコードします。 例えば、`_type` 属性に `ByDirectory` を指定すると `TaskGenerateRuleByDirectory` にデコードされ、`Poliline` を指定すると `InspectionDataPolyline` にデコードされます。 リクエストボディが誤っている場合はエラーになります。 * `_type` 属性を指定しない場合は、リクエストボディで指定された `_type` 以外の属性からデコードすべき型を推論します。適切な型が見つからない場合はエラーになります。 + * `_type` 属性は「推論が失敗して別の型にデコードされる」ことを防ぐために指定することを推奨します。しかし、利便性のために一部APIを除き指定は必須ではありません。 + ## APIに指定するID/名前の制約 + * APIで使用する各データのIDに使用できる文字種は次の通りです。 * 半角英数字 * `_` (アンダースコア) @@ -65,222 +90,267 @@ info: * 例) `b048c6b3-b36f-4c8d-97ea-96828a50a44c` * 各データのIDは、以下のように特定のデータに対して一意な値である必要があります。 + ID/名前 | 一意制約 + ---|--- + 組織名 | AnnoFab内で一意 + 組織ID | AnnoFab内で一意 + ユーザID | AnnoFab内で一意 + アカウントID | AnnoFab内で一意 + プロジェクトID | AnnoFab内で一意 + タスクID(プレフィックス含む) | プロジェクト内で一意 + 入力データID | プロジェクト内で一意 + アノテーションID | フレーム内(タスクID、入力データIDの組み合わせ)で一意 + 検査ID | プロジェクト内で一意 + 補助情報ID | プロジェクト内で一意 + WebhookID | プロジェクト内で一意 + 作業ガイド画像ID | プロジェクト内で一意 + ラベルID | プロジェクト内で一意 + 属性ID | プロジェクト内で一意 + 選択肢ID | 属性内で一意 + ジョブID | プロジェクト内で一意 + 入力データセットID | 組織内で一意 - プラグインID | 組織内で一意 - version: 0.86.0 + プラグインID | 組織内で一意 + version: 0.88.0 title: AnnoFab Web API x-logo: - url: "https://annofab.com/images/logo_landscape.png" - href: "https://annofab.com/" + url: https://annofab.com/images/logo_landscape.png + href: https://annofab.com/ contact: - url: "https://annofab.com/docs/forms/trouble-shooting.html" + url: https://annofab.com/docs/forms/trouble-shooting.html servers: -- url: https://annofab.com/api/v1 + - url: https://annofab.com/api/v1 tags: -- name: af-account - x-displayName: Account - description: ユーザーアカウントに対する操作 -- name: af-annotation - x-displayName: Annotation - description: アノテーションに対する操作 -- name: af-annotation-specs - x-displayName: Annotation Specs - description: アノテーション仕様に対する操作 -- name: af-input - x-displayName: Input - description: | - **入力データ(input data)**に対する操作です。 - - 入力データとは、アノテーションする対象となる画像、動画、CSVなどのファイル全般のことです。 - 入力データは、プロジェクトごとに作成されます。 - - すべてのAF利用プランで、入力データをAnnoFabにアップロードできます。 - AnnoFabにアップロードされた入力データは、AnnoFabからアノテーションツール上に配信されます。 - - ビジネスプランでは、入力データをお客様が管理される**プライベートストレージ**に置き、URLだけをAnnoFabに登録できます。 - プライベートストレージには、**httpsサーバーに対応したNAS**または**AWS S3**を利用できます。 - プライベートストレージに置かれた入力データは、AnnoFabのサーバーを経由せず、直接アノテーションツール上に配信されます。 - セキュリティ要件のためお客様の入力データを社外(AnnoFab含む)に非公開にしたい場合、プライベートストレージを利用することができます。 - また場合によっては、AnnoFabから入力データを配信するよりも配信速度が改善する場合があります。 - - 関連 - * [af-supplementary](#tag/af-supplementary): 入力データを補う補助情報 -- name: af-inspection - x-displayName: Inspection - description: 検査コメントに対する操作 -- name: af-instruction - x-displayName: Instruction - description: 作業ガイドに対する操作 -- name: af-job - x-displayName: Job - description: バッチ処理ジョブに対する操作 -- name: af-login - x-displayName: Login - description: ログイン関連の操作 -- name: af-my - x-displayName: My - description: 自身のリソースに対する操作 -- name: af-organization - x-displayName: Organization - description: 組織に対する操作 -- name: af-organization-member - x-displayName: Organization Member - description: 組織メンバーに対する操作 -- name: af-organization-plugin - x-displayName: Organization Plugin - description: | - 組織で使用するプラグインに対する操作 - - **このAPIは AnnoFab に許可された組織だけで使用できます。またアルファ版につき、予告なく変更されることがあります。** -- name: af-project - x-displayName: Project - description: プロジェクトに対する操作 -- name: af-project-member - x-displayName: Project Member - description: プロジェクトメンバーに対する操作 -- name: af-statistics - x-displayName: Statistics - description: 集計に関する操作 -- name: af-supplementary - x-displayName: Supplementary - description: | - **補助情報(supprementary data)**に対する操作です。 - - 補助情報とは、アノテーションする対象となる[入力データ](#tag/af-input)では*ありません*が、 - アノテーションするときに何らかの手がかりや文脈を与えるデータのことです。 - 例えば、次のようなものです。 - * 現在の写真に対する、過去の写真 - * 光学写真に対する、暗視写真 - * 前方を撮影した写真に対する、左側面・右側面・後方の写真 - * 写真や動画を撮影した日時、緯度経度、撮影者などのメタデータ(テキスト) - - 補助情報は、画像やテキストで、プロジェクトの入力データごとにひも付けられます。 - 補助情報で扱う画像は、入力データと同様にAnnoFabにアップロードする他に、プライベートストレージの画像を利用することもできます。 - - 関連 - * [af-input](#tag/af-input): 補助情報をひもづける入力データ - * [af-project](#tag/af-project): 補助情報をひもづけるプロジェクト -- name: af-task - x-displayName: Task - description: タスクに対する操作 -- name: af-webhook - x-displayName: Webhook - description: Webhookに対する操作 -- name: x-annotation-zip - x-displayName: Annotation ZIP - description: | - AnnoFabで作成したアノテーションは、元となった入力データ(画像や動画など)に対応する形で1ファイルのJSONとなります。 - これらのJSONはZIP形式で圧縮され、一括で取得できます。 - - AnnoFabから取得できるアノテーションの構造は、現在2種類あります。 - - 1. Simple - * バウンディングボックスや属性など、いわゆるアノテーションにしぼった軽量な構造。 - * いかなるプロジェクトでも取得できます。 - * 推奨版です。 - * アノテーションZIPおよびアノテーション構造の詳細は、 [Simple Annotation ZIP](#section/Simple-Annotation-ZIP) を参照ください。 - 2. Full - * バウンディングボックスや属性に加え、アノテーションを作成したタスクに関する構造が含まれる重厚長大な構造。 - * Businessプラン組織のプロジェクトでのみ取得できます。 - * 非推奨版です。長期的には廃止予定なので、新規の使用は控え、Simpleへ移行してください。 - * アノテーションZIPおよびアノテーション構造の詳細は、 [Full Annotation ZIP](#section/Full-Annotation-ZIP) を参照ください。 - - アノテーションは、各プロジェクトのトップページでダウンロードできます。また、次のAPIを利用して取得することもできます。 - - * Simple版アノテーションZIP取得API: [getAnnotationArchive](#operation/getAnnotationArchive) - * Full版アノテーションZIP取得API: [getArchiveFullWithProId](#operation/getArchiveFullWithProId) - - なお、アノテーションZIPは毎日AM 03:00 JSTごろに自動更新されます。 - - ## Simple Annotation ZIP - ### ファイル名 - `af-annotation-{プロジェクトID}-{更新日時: yyyyMMdd-hhmmss}.zip` - - ### ZIPファイル内の構造 - * / (ZIPファイルのルートディレクトリ) - * {タスクID}/ - * {入力データ名}.json - * アノテーションJSONデータ (詳細は次節を参照) - * {入力データ名}/ (塗りつぶしアノテーション時のみ) - * {アノテーションデータID} (塗りつぶしのPNG画像) - - ### アノテーションJSONデータの構造 - Simple版アノテーションZIPに含まれるアノテーションJSONは、機械学習の一般的な利用で扱いやすい構造になっています。 - - - ### 注意事項 - 同じ入力データ名を持つ入力データが複数存在する場合、Simple版アノテーションZIP内のファイル名およびディレクトリ名が `{入力データ名__入力データID}` となる場合があります。 - - この現象は[入力データ更新API](#operation/putInputData)を使用して、複数の入力データの入力データ名を重複させた場合に発生することがあります。 - AnnoFabの画像アップロード機能のみ使用していた場合には発生しません。 - - この現象を回避したい場合、入力データ更新APIを使用して入力データ名の重複を解消した後、アノテーションZIPを再作成してください。 - - ## Full Annotation ZIP - ### ファイル名 - `af-annotation-{プロジェクトID}-{更新日時: yyyyMMdd-hhmmss}.zip` - - ### ZIPファイル内の構造 - * / (ZIPファイルのルートディレクトリ) - * {タスクID}/ - * {入力データID}.json - * アノテーションJSONデータ (詳細は次節を参照) - * {入力データID}/ (塗りつぶしアノテーション時のみ) - * {アノテーションデータID} (塗りつぶしのPNG画像) - - ### アノテーションJSONデータの構造 - Full版アノテーションZIPに含まれるアノテーションJSONは、画像やアノテーションやアノテーション作成者など管理用の詳細情報が付随しています。 - - -- name: x-data-types - x-displayName: Data Types - description: | - # Task - - - # TaskHistory - - - # TaskHistoryEvent - - - # Inspection - - - # TaskStatus - - - # TaskPhase - - - # AnnotationId - - - # InputData - - - # JobType - + - name: af-account + x-displayName: Account + description: ユーザーアカウントに対する操作 + - name: af-annotation + x-displayName: Annotation + description: アノテーションに対する操作 + - name: af-annotation-specs + x-displayName: Annotation Specs + description: アノテーション仕様に対する操作 + - name: af-input + x-displayName: Input + description: | + **入力データ(input data)**に対する操作です。 + + 入力データとは、アノテーションする対象となる画像、動画、CSVなどのファイル全般のことです。 + 入力データは、プロジェクトごとに作成されます。 + + すべてのAF利用プランで、入力データをAnnoFabにアップロードできます。 + AnnoFabにアップロードされた入力データは、AnnoFabからアノテーションツール上に配信されます。 + + ビジネスプランでは、入力データをお客様が管理される**プライベートストレージ**に置き、URLだけをAnnoFabに登録できます。 + プライベートストレージには、**httpsサーバーに対応したNAS**または**AWS S3**を利用できます。 + プライベートストレージに置かれた入力データは、AnnoFabのサーバーを経由せず、直接アノテーションツール上に配信されます。 + セキュリティ要件のためお客様の入力データを社外(AnnoFab含む)に非公開にしたい場合、プライベートストレージを利用することができます。 + また場合によっては、AnnoFabから入力データを配信するよりも配信速度が改善する場合があります。 + + 関連 + * [af-supplementary](#tag/af-supplementary): 入力データを補う補助情報 + - name: af-inspection + x-displayName: Inspection + description: 検査コメントに対する操作 + - name: af-instruction + x-displayName: Instruction + description: 作業ガイドに対する操作 + - name: af-job + x-displayName: Job + description: バッチ処理ジョブに対する操作 + - name: af-login + x-displayName: Login + description: ログイン関連の操作 + - name: af-my + x-displayName: My + description: 自身のリソースに対する操作 + - name: af-organization + x-displayName: Organization + description: 組織に対する操作 + - name: af-organization-member + x-displayName: Organization Member + description: 組織メンバーに対する操作 + - name: af-organization-plugin + x-displayName: Organization Plugin + description: | + 組織で使用するプラグインに対する操作 + + **このAPIは AnnoFab に許可された組織だけで使用できます。またアルファ版につき、予告なく変更されることがあります。** + - name: af-project + x-displayName: Project + description: プロジェクトに対する操作 + - name: af-project-member + x-displayName: Project Member + description: プロジェクトメンバーに対する操作 + - name: af-statistics + x-displayName: Statistics + description: 集計に関する操作 + - name: af-supplementary + x-displayName: Supplementary + description: | + **補助情報(supprementary data)**に対する操作です。 + + 補助情報とは、アノテーションする対象となる[入力データ](#tag/af-input)では*ありません*が、 + アノテーションするときに何らかの手がかりや文脈を与えるデータのことです。 + 例えば、次のようなものです。 + * 現在の写真に対する、過去の写真 + * 光学写真に対する、暗視写真 + * 前方を撮影した写真に対する、左側面・右側面・後方の写真 + * 写真や動画を撮影した日時、緯度経度、撮影者などのメタデータ(テキスト) + + 補助情報は、画像やテキストで、プロジェクトの入力データごとにひも付けられます。 + 補助情報で扱う画像は、入力データと同様にAnnoFabにアップロードする他に、プライベートストレージの画像を利用することもできます。 + + 関連 + * [af-input](#tag/af-input): 補助情報をひもづける入力データ + * [af-project](#tag/af-project): 補助情報をひもづけるプロジェクト + - name: af-task + x-displayName: Task + description: タスクに対する操作 + - name: af-webhook + x-displayName: Webhook + description: Webhookに対する操作 + - name: x-annotation-zip + x-displayName: Annotation ZIP + description: > + AnnoFabで作成したアノテーションは、元となった入力データ(画像や動画など)に対応する形で1ファイルのJSONとなります。 + + これらのJSONはZIP形式で圧縮され、一括で取得できます。 + + + AnnoFabから取得できるアノテーションの構造は、現在2種類あります。 + + + 1. Simple + * バウンディングボックスや属性など、いわゆるアノテーションにしぼった軽量な構造。 + * いかなるプロジェクトでも取得できます。 + * 推奨版です。 + * アノテーションZIPおよびアノテーション構造の詳細は、 [Simple Annotation ZIP](#section/Simple-Annotation-ZIP) を参照ください。 + 2. Full + * バウンディングボックスや属性に加え、アノテーションを作成したタスクに関する構造が含まれる重厚長大な構造。 + * Businessプラン組織のプロジェクトでのみ取得できます。 + * 非推奨版です。長期的には廃止予定なので、新規の使用は控え、Simpleへ移行してください。 + * アノテーションZIPおよびアノテーション構造の詳細は、 [Full Annotation ZIP](#section/Full-Annotation-ZIP) を参照ください。 + + アノテーションは、各プロジェクトのトップページでダウンロードできます。また、次のAPIを利用して取得することもできます。 + + + * Simple版アノテーションZIP取得API: [getAnnotationArchive](#operation/getAnnotationArchive) + + * Full版アノテーションZIP取得API: [getArchiveFullWithProId](#operation/getArchiveFullWithProId) + + + なお、アノテーションZIPは毎日AM 03:00 JSTごろに自動更新されます。 + + + ## Simple Annotation ZIP + ### ファイル名 + + `af-annotation-{プロジェクトID}-{更新日時: yyyyMMdd-hhmmss}.zip` + + + ### ZIPファイル内の構造 + + * / (ZIPファイルのルートディレクトリ) + * {タスクID}/ + * {入力データ名}.json + * アノテーションJSONデータ (詳細は次節を参照) + * {入力データ名}/ (塗りつぶしアノテーション時のみ) + * {アノテーションデータID} (塗りつぶしのPNG画像) + + ### アノテーションJSONデータの構造 + + Simple版アノテーションZIPに含まれるアノテーションJSONは、機械学習の一般的な利用で扱いやすい構造になっています。 + + + + + ### 注意事項 + + 同じ入力データ名を持つ入力データが複数存在する場合、Simple版アノテーションZIP内のファイル名およびディレクトリ名が `{入力データ名__入力データID}` となる場合があります。 + + + この現象は[入力データ更新API](#operation/putInputData)を使用して、複数の入力データの入力データ名を重複させた場合に発生することがあります。 + + AnnoFabの画像アップロード機能のみ使用していた場合には発生しません。 + + + この現象を回避したい場合、入力データ更新APIを使用して入力データ名の重複を解消した後、アノテーションZIPを再作成してください。 + + + ## Full Annotation ZIP + + ### ファイル名 + + `af-annotation-{プロジェクトID}-{更新日時: yyyyMMdd-hhmmss}.zip` + + + ### ZIPファイル内の構造 + + * / (ZIPファイルのルートディレクトリ) + * {タスクID}/ + * {入力データID}.json + * アノテーションJSONデータ (詳細は次節を参照) + * {入力データID}/ (塗りつぶしアノテーション時のみ) + * {アノテーションデータID} (塗りつぶしのPNG画像) + + ### アノテーションJSONデータの構造 + + Full版アノテーションZIPに含まれるアノテーションJSONは、画像やアノテーションやアノテーション作成者など管理用の詳細情報が付随しています。 + + + - name: x-data-types + x-displayName: Data Types + description: | + # Task + + + # TaskHistory + + + # TaskHistoryEvent + + + # Inspection + + + # TaskStatus + + + # TaskPhase + + + # AnnotationId + + + # InputData + + + # JobType + + + # AnnotationQuery + x-tagGroups: - name: API tags: @@ -306,85 +376,136 @@ x-tagGroups: tags: - x-annotation-zip - x-data-types +components: + securitySchemes: + EveryoneRequestBody: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/EveryoneRequestBody + EveryoneQueryParameter: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/EveryoneQueryParameter + Everyone: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/Everyone + AnnoFabAdminOnly: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AnnoFabAdminOnly + AllProjectMember: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AllProjectMember + ProjectAccepter: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectAccepter + ProjectDataUser: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectDataUser + ProjectAccepterOrDataUser: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectAccepterOrDataUser + ProjectOwner: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectOwner + AllOrganizationMember: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AllOrganizationMember + OrganizationAdministrator: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/OrganizationAdministrator + OrganizationOwner: + $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/OrganizationOwner + schemas: + SimpleAnnotation: + $ref: swagger-api-components.redoc.yaml#/components/schemas/SimpleAnnotation + FullAnnotation: + $ref: swagger-api-components.redoc.yaml#/components/schemas/FullAnnotation + Task: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + TaskHistory: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskHistory + TaskHistoryEvent: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskHistoryEvent + Inspection: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Inspection + TaskStatus: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskStatus + TaskPhase: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhase + AnnotationId: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationId + InputData: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData + JobType: + $ref: swagger-api-components.redoc.yaml#/components/schemas/JobType + AnnotationQuery: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationQuery paths: /login: post: tags: - - af-login + - af-login summary: ログイン description: "" security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: login requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/LoginRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/LoginRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/LoginResponse" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/LoginResponse + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /logout: post: tags: - - af-login + - af-login summary: ログアウト - description: "" + description: 本人認証にはリクエストボディのトークンを使用します。 security: - - Everyone: [] + - EveryoneRequestBody: [] operationId: logout requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/Token" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Token responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /refresh-token: post: tags: - - af-login + - af-login summary: トークン リフレッシュ description: "" security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: refreshToken requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/RefreshTokenRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/RefreshTokenRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Token" - 401: - $ref: "#/components/responses/ErrorRefreshTokenExpired" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Token + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorRefreshTokenExpired + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /sign-up: post: tags: - - af-account + - af-account summary: サインアップstep1(開始) description: "" operationId: initiateSignup @@ -393,329 +514,332 @@ paths: content: application/json: schema: - $ref: "#/components/schemas/SignUpRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/SignUpRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest /confirm-sign-up: post: tags: - - af-account + - af-account summary: サインアップstep2(確定) description: "" operationId: confirmSignup security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/ConfirmSignUpRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmSignUpRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /change-password: post: tags: - - af-account + - af-account summary: パスワード変更 description: "" security: - - Everyone: [] + - Everyone: [] operationId: changePassword requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/ChangePasswordRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ChangePasswordRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /request-password-reset: post: tags: - - af-account + - af-account summary: パスワードリセットstep1(開始) - description: | + description: > パスワードリセットに必要な確認コードをメールで送付します。 + 後続の[新しいパスワードに変更](#operation/confirmResetPassword)を実行することで、新しいパスワードに変更できます。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: initiatePasswordReset requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/PasswordResetRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PasswordResetRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /confirm-reset-password: post: tags: - - af-account + - af-account summary: パスワードリセットstep2(新しいパスワードに変更) - description: | + description: > 新しいパスワードに変更します。 + 本人確認のため、[パスワードリセットを要求](#operation/initiateResetPassword)で受信したメールに記載された検証コードを使用します。 + パスワードリセットプロセスの最終ステップです。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: confirmResetPassword requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/ConfirmResetPasswordRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmResetPasswordRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /reset-email: post: tags: - - af-account + - af-account summary: メールアドレスリセットstep1(開始) description: | メールアドレス変更プロセスを開始します。 本人からの要求かどうかを検証するための確認コードがメールで送付されます。 security: - - Everyone: [] + - Everyone: [] operationId: initiateResetEmail requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/ResetEmailRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ResetEmailRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /confirm-reset-email: post: tags: - - af-account + - af-account summary: メールアドレスstep2(確定) description: | [受け取った確認コード](#operation/initiateResetEmail)を使い、メールアドレスを変更します。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: confirmResetEmail requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/ConfirmResetEmailRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmResetEmailRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /verify-email: post: tags: - - af-account + - af-account summary: メールアドレス検証step1(開始) description: | メールアドレスが有効かどうかの確認プロセスを開始します。 本人からの要求かどうかを検証するための確認コードがメールで送付されます。 security: - - Everyone: [] + - Everyone: [] operationId: initiateVerifyEmail requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/VerifyEmailRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/VerifyEmailRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /confirm-verify-email: post: tags: - - af-account + - af-account summary: メールアドレス検証step2(確定) description: | [受け取った確認コード](#operation/initiateVerifyEmail)を使い、メールアドレスが有効であることを確認します。 security: - - Everyone: [] + - Everyone: [] operationId: confirmVerifyEmail requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/ConfirmVerifyEmailRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmVerifyEmailRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /my/account: get: tags: - - af-my + - af-my summary: 自分のアカウント取得 description: "" security: - - Everyone: [] + - Everyone: [] operationId: getMyAccount responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/MyAccount" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/MyAccount + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-my + - af-my summary: 自分のアカウント情報更新 description: "" security: - - Everyone: [] + - Everyone: [] operationId: putMyAccount requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/PutMyAccountRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PutMyAccountRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/MyAccount" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/MyAccount + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /my/account/delete-request: post: tags: - - af-my + - af-my summary: アカウント削除step1 description: | アカウント削除プロセスを開始します。 本人からの要求かどうかを検証するための確認コードがメールで送付されます。 security: - - Everyone: [] + - Everyone: [] operationId: initiateMyAccountDelete responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /my/account/delete-request/confirm: post: tags: - - af-my + - af-my summary: アカウント削除step2(確定) description: | [受け取った確認コード](#operation/initiateMyAccountDelete)を使い、アカウントを削除します。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: confirmMyAccountDelete requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/ConfirmAccountDeleteRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmAccountDeleteRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 409: + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "409": description: 自身のみがオーナーのプロジェクト、または組織が1つ以上存在した content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /my/project-members: get: tags: - - af-my + - af-my summary: 自分のプロジェクトメンバー情報一括取得 description: "" security: - - Everyone: [] + - Everyone: [] operationId: getMyProjectMembers responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/ProjectMember" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi /organizations: post: tags: @@ -731,150 +855,127 @@ paths: content: application/json: schema: - $ref: "#/components/schemas/OrganizationRegistrationRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationRegistrationRequest responses: - 200: + "200": description: 作成に成功すると、その組織 content: application/json: schema: - $ref: "#/components/schemas/Organization" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /my/organizations: get: tags: - - af-my + - af-my summary: 所属組織一括取得 description: "" security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getMyOrganizations parameters: - - name: page - in: query - description: | - 表示するページ番号 - - 現在は未実装のパラメータです。(今後対応予定) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: | - 1ページあたりの取得するデータ件数 - - 現在は未実装のパラメータです。(今後対応予定) - required: false - schema: - type: integer - minimum: 1 - default: 30 - maximum: 200 + - name: page + in: query + description: | + 表示するページ番号 + + 現在は未実装のパラメータです。(今後対応予定) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: | + 1ページあたりの取得するデータ件数 + + 現在は未実装のパラメータです。(今後対応予定) + required: false + schema: + type: integer + minimum: 1 + default: 30 + maximum: 200 responses: - 200: + "200": description: 正常 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/MyOrganization" - description: 現在のページ番号に含まれる0件以上の所属組織です。 - page_no: - type: number - description: 現在のページ番号です。 - total_page_no: - type: number - description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる所属組織が0件であっても、総ページ数は1となります。 - total_count: - type: number - description: 検索結果の総件数。 - over_limit: - type: boolean - description: 検索結果が1万件を超えた場合にtrueとなる。 - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - description: Aggregationによる集約結果。 - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/MyOrganizationList + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-my + - af-my summary: 組織名変更 description: | 同じ name の組織が既に存在する場合は失敗(400)します。 security: - - OrganizationOwner: [] + - OrganizationOwner: [] operationId: updateOrganization requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/PutOrganizationNameRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PutOrganizationNameRequest responses: - 200: + "200": description: 変更に成功すると、その組織 content: application/json: schema: - $ref: "#/components/schemas/Organization" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "409": description: 先に更新されているため失敗 content: application/json: schema: - $ref: "#/components/schemas/ErrorAlreadyUpdated" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorAlreadyUpdated + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}": get: tags: - - af-organization + - af-organization summary: 組織情報取得 - description: | + description: "" security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getOrganization parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Organization" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance delete: tags: - af-organization @@ -896,421 +997,378 @@ paths: schema: type: string responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Organization" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: プロジェクトが存在する組織を削除しようとした content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}/projects: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}/projects": get: tags: - - af-organization + - af-organization summary: 組織配下プロジェクト一括取得 description: | 指定した組織のプロジェクトを一括で取得します。 security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getProjectsOfOrganization parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: page - in: query - description: | - 表示するページ番号 - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: | - 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 1 - default: 30 - maximum: 200 - - name: account_id - in: query - description: | - 指定したアカウントIDをメンバーに持つプロジェクトで絞り込む。 - required: false - schema: - $ref: "#/components/schemas/AccountId" - - name: except_account_id - in: query - description: | - 指定したアカウントIDをメンバーに持たないプロジェクトで絞り込む。 - required: false - schema: - $ref: "#/components/schemas/AccountId" - - name: title - in: query - description: | - プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 - required: false - schema: - type: string - - name: status - in: query - description: | - 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 - required: false - schema: - $ref: "#/components/schemas/ProjectStatus" - - name: input_data_type - in: query - description: | - 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト。 - schema: - $ref: "#/components/schemas/InputDataType" - - name: sort_by - in: query - description: | - `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 - 未指定時はプロジェクト名でソートする。 - required: false - schema: - type: string - example: date + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: page + in: query + description: | + 表示するページ番号 + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: | + 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 1 + default: 30 + maximum: 200 + - name: account_id + in: query + description: | + 指定したアカウントIDをメンバーに持つプロジェクトで絞り込む。 + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + - name: except_account_id + in: query + description: | + 指定したアカウントIDをメンバーに持たないプロジェクトで絞り込む。 + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + - name: title + in: query + description: | + プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 + required: false + schema: + type: string + - name: status + in: query + description: | + 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectStatus + - name: input_data_type + in: query + description: | + 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト。 + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataType + - name: sort_by + in: query + description: | + `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 + 未指定時はプロジェクト名でソートする。 + required: false + schema: + type: string + example: date responses: - 200: + "200": description: 正常 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/Project" - description: 現在のページ番号に含まれる0件以上のプロジェクトです。 - page_no: - type: number - description: 現在のページ番号です。 - total_page_no: - type: number - description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 - total_count: - type: number - description: 検索結果の総件数。 - over_limit: - type: boolean - description: 検索結果が1万件を超えた場合にtrueとなる。 - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - description: Aggregationによる集約結果。 - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}/members: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectList + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}/members": get: tags: - - af-organization-member + - af-organization-member summary: 組織メンバー一括取得 description: | 脱退したメンバーは含まれません。 security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getOrganizationMembers parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string responses: - 200: + "200": description: 正常 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/OrganizationMember" - page_no: - type: number - description: 現在のページ番号です。 - total_page_no: - type: number - description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる組織メンバーが0件であっても、総ページ数は1となります。 - total_count: - type: number - description: 検索結果の総件数。 - over_limit: - type: boolean - description: 検索結果が1万件を超えた場合にtrueとなる。 - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - description: Aggregationによる集約結果。 - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}/members/{user_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMemberList + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}/members/{user_id}": get: tags: - - af-organization-member + - af-organization-member summary: 組織メンバー取得 description: | 指定したユーザーが指定した組織にどのようなロールで参加しているかを取得します。 security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getOrganizationMember parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザID - required: true - schema: - $ref: "#/components/schemas/UserId" + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/OrganizationMember" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMember + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance delete: tags: - - af-organization-member + - af-organization-member summary: 組織メンバー削除 description: | 指定したメンバーを指定した組織から削除します。 組織の管理者が実行する場合、組織のオーナーは削除できません。(権限エラーになります) security: - - OrganizationAdministrator: [] + - OrganizationAdministrator: [] operationId: deleteOrganizationMember parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザID - required: true - schema: - $ref: "#/components/schemas/UserId" - responses: - 200: + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId + responses: + "200": description: 正常。削除したメンバーを返します content: application/json: schema: - $ref: "#/components/schemas/OrganizationMember" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}/members/{user_id}/role: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMember + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}/members/{user_id}/role": put: tags: - - af-organization-member + - af-organization-member summary: 組織メンバーのロール更新 - description: | + description: "" security: - - OrganizationOwner: [] + - OrganizationOwner: [] operationId: updateOrganizationMemberRole parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザID - required: true - schema: - $ref: "#/components/schemas/UserId" + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/PutOrganizationMemberRoleRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PutOrganizationMemberRoleRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/OrganizationMember" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}/members/{user_id}/invitation: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMember + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}/members/{user_id}/invitation": post: tags: - - af-organization-member + - af-organization-member summary: 組織への招待送信 - description: | + description: > 指定したユーザーに、組織への招待(メール)を送信します。 + 組織の管理者が実行する場合、リクエストボディ内の `role` には `contributor` を指定してください。(それ以外の値を指定した場合エラーとなります) security: - - OrganizationAdministrator: [] + - OrganizationAdministrator: [] operationId: inviteOrganizationMember parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザ名 - required: true - schema: - $ref: "#/components/schemas/UserId" + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザ名 + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/InviteOrganizationMemberRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/InviteOrganizationMemberRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/OrganizationMember" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}/members/{user_id}/invitation/accept: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMember + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}/members/{user_id}/invitation/accept": post: tags: - - af-organization-member + - af-organization-member summary: 組織への招待受諾 - description: | + description: > 組織への招待を受諾し、組織へのメンバー登録を完了します。 + [組織招待API](#operation/postInviteOrganizationMember)で送信されたメールに記載されているトークンが必要です。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: acceptOrganizationInvitation parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザ名 - required: true - schema: - $ref: "#/components/schemas/UserId" + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザ名 + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/AcceptOrganizationInvitationRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/AcceptOrganizationInvitationRequest responses: - 200: - $ref: "#/components/responses/SuccessMessage" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}/activity: + "200": + $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}/activity": get: tags: - - af-organization + - af-organization summary: 組織活動サマリー取得 - description: | + description: "" security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getOrganizationActivity parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/OrganizationActivity" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}/plugins: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationActivity + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}/plugins": get: operationId: getOrganizationPlugins summary: プラグイン一括取得 @@ -1327,36 +1385,22 @@ paths: in: path required: true schema: - $ref: "#/components/schemas/OrganizationName" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName description: 組織名 responses: - 200: + "200": description: 正常 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/OrganizationPlugin" - page_no: - type: number - description: 現在のページ番号です。 - total_page_no: - type: number - description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 - total_count: - type: number - description: 検索結果の総件数。 - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /organizations/{organization_name}/plugins/{plugin_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationPluginList + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/organizations/{organization_name}/plugins/{plugin_id}": get: operationId: getOrganizationPlugin summary: プラグイン取得 @@ -1373,27 +1417,27 @@ paths: in: path required: true schema: - $ref: "#/components/schemas/OrganizationName" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName description: 組織名 - name: plugin_id in: path required: true schema: - $ref: "#/components/schemas/PluginId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PluginId description: プラグインID responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/OrganizationPlugin" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationPlugin + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: operationId: putOrganizationPlugin summary: プラグイン更新 @@ -1411,33 +1455,33 @@ paths: in: path required: true schema: - $ref: "#/components/schemas/OrganizationName" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName description: 組織名 - name: plugin_id in: path required: true schema: - $ref: "#/components/schemas/PluginId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PluginId description: プラグインID requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/PutOrganizationPluginRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PutOrganizationPluginRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/OrganizationPlugin" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationPlugin + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance delete: operationId: deleteOrganizationPlugin summary: プラグイン削除 @@ -1455,198 +1499,215 @@ paths: in: path required: true schema: - $ref: "#/components/schemas/OrganizationName" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName description: 組織名 - name: plugin_id in: path required: true schema: - $ref: "#/components/schemas/PluginId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PluginId description: プラグインID responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/OrganizationPlugin" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationPlugin + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance /my/projects: get: tags: - - af-my + - af-my summary: 所属プロジェクト一括取得 description: | 自身が所属するプロジェクトを一括で取得します。 security: - - Everyone: [] + - Everyone: [] operationId: getMyProjects parameters: - - name: page - in: query - description: | - 表示するページ番号 - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: | - 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 0 - maximum: 200 - - name: organization_id - in: query - description: | - 指定した組織に属するプロジェクトに絞り込む。未指定時は全プロジェクト。 - required: false - schema: - $ref: "#/components/schemas/OrganizationId" - - name: title - in: query - description: | - プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 - required: false - schema: - type: string - - name: status - in: query - description: | - 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 - required: false - schema: - $ref: "#/components/schemas/ProjectStatus" - - name: input_data_type - in: query - description: | - 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト - required: false - schema: - $ref: "#/components/schemas/InputDataType" - - name: sort_by - in: query - description: | - `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 - 未指定時はプロジェクト名でソートする。 - required: false - schema: - type: string - example: date + - name: page + in: query + description: | + 表示するページ番号 + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: | + 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 0 + maximum: 200 + - name: organization_id + in: query + description: | + 指定した組織に属するプロジェクトに絞り込む。未指定時は全プロジェクト。 + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId + - name: title + in: query + description: | + プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 + required: false + schema: + type: string + - name: status + in: query + description: | + 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectStatus + - name: input_data_type + in: query + description: | + 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataType + - name: sort_by + in: query + description: | + `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 + 未指定時はプロジェクト名でソートする。 + required: false + schema: + type: string + example: date responses: - 200: + "200": description: 正常 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/Project" - has_next: - type: boolean - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectContainer + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}": get: tags: - - af-project + - af-project summary: プロジェクト取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getProject parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Project" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Project + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-project + - af-project summary: プロジェクト作成/更新 - description: | + description: > プロジェクトを新規作成または更新します。 + ### 新規作成する場合 + ユーザーは、作成するプロジェクトをひもづける組織の [OrganizationAdministrator](#section/Authentication/OrganizationAdministrator) である必要があります。 + ### 更新する場合 + ユーザーは、更新するプロジェクトの [ProjectOwner](#section/Authentication/ProjectOwner) である必要があります。 + また所属組織を変更する場合は、新しくひもづける組織の [OrganizationAdministrator](#section/Authentication/OrganizationAdministrator) である必要があります。 + なお、プロジェクト状態を「停止中」にした場合、アノテーションZIPやタスク進捗状況などの集計情報は自動更新されなくなります。 security: - - OrganizationAdministrator: [] - ProjectOwner: [] + - OrganizationAdministrator: [] + ProjectOwner: [] operationId: putProject parameters: - - name: project_id - in: path - description: | - プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: | + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Project + - "2":PutProjectResponse + required: false + schema: + type: string + default: "1" + example: "2" requestBody: content: application/json: schema: - $ref: "#/components/schemas/PutProjectRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PutProjectRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Project" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Project + "202": + description: 組織変更実施時 + content: + application/json: + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/PutProjectResponseWrapper + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "409": description: 現在のプロジェクトやタスクの状態ではできない操作をしようとした content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance delete: tags: - - af-project + - af-project summary: プロジェクト削除 description: | プロジェクトを完全に削除します。 @@ -1655,164 +1716,180 @@ paths: 削除されたプロジェクトは元に戻せません。 完了したプロジェクトは削除せず、プロジェクト状態を「停止中」に変更するのをおすすめします。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteProject parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: v - in: query - description: | - APIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":Project - - "2":DeleteProjectResponse - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Project + - "2":DeleteProjectResponse + required: false + schema: + type: string + default: "1" + example: "2" responses: - 202: + "202": description: バッチにてプロジェクトの削除開始 content: application/json: schema: - oneOf: - - $ref: "#/components/schemas/Project" - - $ref: "#/components/schemas/DeleteProjectResponse" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/DeleteProjectResponseWrapper + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: 停止中ではないプロジェクトを削除しようとした content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/organization: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/organization": get: tags: - - af-project + - af-project summary: プロジェクトの所属組織取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getOrganizationOfProject parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Organization" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/copy: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/copy": post: tags: - - af-project + - af-project summary: プロジェクト複製 - description: | + description: > 指定したプロジェクトのデータを引き継いだ新しいプロジェクトを作成します。 + 新しいプロジェクトに引き継がれるデータは次の通りです。 + * プロジェクト設定 + * プロジェクトメンバー + * アノテーション仕様 + また、オプションを指定することで新しいプロジェクトに次のデータを引き継ぐことも可能です。 + |引き継ぎ対象|同時に引き継ぐ必要があるデータ| + |:--|:--| + |入力データ|| + |タスク|入力データ| + |アノテーション|入力データ、タスク| + |補助情報|入力データ| + |作業ガイド|| + |Webhook|| + このAPIを利用するには、プロジェクトを登録する組織の[OrganizationAdministrator](#section/Authentication/OrganizationAdministrator) かつ コピー元プロジェクトの [ProjectOwner](#section/Authentication/ProjectOwner) である必要があります。 + 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`copy-project`)。 security: - - OrganizationAdministrator: [] - ProjectOwner: [] + - OrganizationAdministrator: [] + ProjectOwner: [] operationId: initiateProjectCopy parameters: - - name: project_id - in: path - description: コピー元となるプロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: v - in: query - description: | - APIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":Project - - "2":ProjectCopyResponse - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: コピー元となるプロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Project + - "2":ProjectCopyResponse + required: false + schema: + type: string + default: "1" + example: "2" requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/ProjectCopyRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectCopyRequest responses: - 202: + "202": description: 正常 content: application/json: schema: - oneOf: - - $ref: "#/components/schemas/Project" - - $ref: "#/components/schemas/ProjectCopyResponse" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/rawdata/inputs: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectCopyResponseWrapper + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/rawdata/inputs": get: tags: - af-project summary: プロジェクトの入力データ情報全件URLの取得 - description: | + description: > 入力データ情報全件ファイルにアクセスするための、認証済み一時URLを取得します。 + 取得したURLは1時間で失効し、アクセスできなくなります。 + ### 入力データ情報全件ファイル + 入力データ情報全件ファイルには、プロジェクトの入力データ情報がJSON形式([InputData](#section/InputData)の配列)で記録されています。 + ただし`InputData`中の`url`は常に`null`です。 + このファイルは毎日AM 02:00 JSTに更新されます。 security: - ProjectOwner: [] @@ -1823,9 +1900,9 @@ paths: description: プロジェクトID required: true schema: - $ref: "#/components/schemas/ProjectId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 headers: Location: @@ -1836,32 +1913,32 @@ paths: content: application/json: schema: - type: object - required: - - url - properties: - url: - type: string - description: 認証済み一時URL - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance post: tags: - af-project summary: プロジェクトの入力データ情報全件ファイル更新開始 - description: | + description: > プロジェクト内の入力データ情報全件ファイルの更新を開始します。 + ファイルの更新時間は、データ量に応じて数分~数十分程度かかります。 + 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-inputs-list`)。 + 入力データ情報全件ファイルは毎日AM 02:00 JSTに自動更新されます。 + 本APIを用いると、自動更新を待たずに更新を要求できます。 + ただし、入力データ情報全件ファイル以外は更新されません。 + 入力データ情報全件ファイルについては、[getProjectInputsUrl](#operation/getProjectInputsUrl) APIを参照ください。 security: - ProjectOwner: [] @@ -1872,45 +1949,50 @@ paths: description: プロジェクトID required: true schema: - $ref: "#/components/schemas/ProjectId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 202: + "202": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/ProjectInputsUpdateResponse" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/rawdata/tasks: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectInputsUpdateResponse + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/rawdata/tasks": get: tags: - - af-project + - af-project summary: プロジェクトのタスク全件URLの取得 - description: | + description: > タスク全件ファイルにアクセスするための、認証済み一時URLを取得します。 + 取得したURLは1時間で失効し、アクセスできなくなります。 + ### タスク全件ファイル + タスク全件ファイルには、プロジェクトのタスク情報がJSON形式([Task](#section/Task)の配列)で記録されています。 + このファイルは毎日AM 02:00 JSTに更新されます。 + また、[postProjectTasksUpdate](#operation/postProjectTasksUpdate) APIを利用することで、手動でタスク全件ファイルを更新することも可能です。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: getProjectTasksUrl parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 headers: Location: @@ -1921,32 +2003,32 @@ paths: content: application/json: schema: - type: object - required: - - url - properties: - url: - type: string - description: 認証済み一時URL - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance post: tags: - - af-project + - af-project summary: プロジェクトのタスク全件ファイル更新開始 - description: | + description: > プロジェクト内のタスク全件ファイルの更新を開始します。 + ファイルの更新時間は、データ量に応じて数分~数十分程度かかります。 + 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-tasks-list`)。 + タスク全件ファイルは毎日AM 02:00 JSTに自動更新されます。 + 本APIを用いると、自動更新を待たずに更新を要求できます。 + ただし、タスク全件ファイル以外は更新されません。 + タスク全件ファイルについては、[getProjectTasksUrl](#operation/getProjectTasksUrl) APIを参照ください。 security: - ProjectOwner: [] @@ -1957,7 +2039,7 @@ paths: description: プロジェクトID required: true schema: - $ref: "#/components/schemas/ProjectId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - name: v in: query description: | @@ -1971,44 +2053,46 @@ paths: default: "1" example: "2" responses: - 202: + "202": description: 正常 content: application/json: schema: - oneOf: - - $ref: "#/components/schemas/Message" - - $ref: "#/components/schemas/PostProjectTasksUpdateResponse" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/rawdata/inspections: + $ref: swagger-api-components.redoc.yaml#/components/schemas/PostProjectTasksUpdateResponseWrapper + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/rawdata/inspections": get: tags: - - af-project + - af-project summary: プロジェクトの検査コメント全件URLの取得 - description: | + description: > 検査コメント全件ファイルにアクセスするための、認証済み一時URLを取得します。 + 取得したURLは1時間で失効し、アクセスできなくなります。 + ### 検査コメント全件ファイル + 検査コメント全件ファイルには、プロジェクトの検査コメント情報がJSON形式([Inspection](#section/Inspection)の配列)で記録されています。 + このファイルは毎日AM 02:00 JSTに更新されます。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: getProjectInspectionsUrl parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 headers: Location: @@ -2019,44 +2103,42 @@ paths: content: application/json: schema: - type: object - required: - - url - properties: - url: - type: string - description: 認証済み一時URL - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/rawdata/task_history_events: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/rawdata/task_history_events": get: deprecated: true tags: - - af-project + - af-project summary: プロジェクトのタスク履歴イベント全件URLの取得 - description: | + description: > タスク履歴イベント全件ファイルにアクセスするための、認証済み一時URLを取得します。 + 取得したURLは1時間で失効し、アクセスできなくなります。 + ### タスク履歴イベント全件ファイル + タスク履歴イベント全件ファイルには、プロジェクトのタスク履歴イベント情報がJSON形式([TaskHistoryEvent](#section/TaskHistoryEvent)の配列)で記録されています。 + このファイルは毎日AM 02:00 JSTに更新されます。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: getProjectTaskHistoryEventsUrl parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 headers: Location: @@ -2067,30 +2149,28 @@ paths: content: application/json: schema: - type: object - required: - - url - properties: - url: - type: string - description: 認証済み一時URL - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/rawdata/task_histories: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/rawdata/task_histories": get: tags: - af-project summary: プロジェクトのタスク履歴全件URLの取得 - description: | + description: > タスク履歴全件ファイルにアクセスするための、認証済み一時URLを取得します。 + 取得したURLは1時間で失効し、アクセスできなくなります。 + ### タスク履歴全件ファイル + タスク履歴イベント全件ファイルには、プロジェクトのタスク履歴情報がJSON形式(キーがタスクID、値が[TaskHistory](#section/TaskHistory)の配列となるマップ)で記録されています。 + このファイルは毎日AM 02:00 JSTに更新されます。 security: - ProjectOwner: [] @@ -2101,9 +2181,9 @@ paths: description: プロジェクトID required: true schema: - $ref: "#/components/schemas/ProjectId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 headers: Location: @@ -2114,221 +2194,197 @@ paths: content: application/json: schema: - type: object - required: - - url - properties: - url: - type: string - description: 認証済み一時URL - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /my/projects/{project_id}/member: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/my/projects/{project_id}/member": get: tags: - - af-my + - af-my summary: 自分のプロジェクトメンバー取得 - description: | - 備考: システム管理者が自身が所属しないプロジェクトに対して実行した場合、オーナーであるというダミーのプロジェクトメンバー情報が取得できます。ダミーには更新日は含まれません。 + description: > + 備考: + システム管理者が自身が所属しないプロジェクトに対して実行した場合、オーナーであるというダミーのプロジェクトメンバー情報が取得できます。ダミーには更新日は含まれません。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getMyMemberInProject parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/ProjectMember" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/members: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/members": get: tags: - - af-project-member + - af-project-member summary: プロジェクトメンバー一括取得 - description: | - 備考: 組織に加入していないメンバーも取得できることがあります([プロジェクト更新](#operation/putProject)でプロジェクトの組織移動をおこなった場合)。 + description: > + 備考: + 組織に加入していないメンバーも取得できることがあります([プロジェクト更新](#operation/putProject)でプロジェクトの組織移動をおこなった場合)。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getProjectMembers parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: include_inactive_member - in: query - description: 脱退したプロジェクトメンバーも取得する時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: include_inactive_member + in: query + description: 脱退したプロジェクトメンバーも取得する時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string responses: - 200: + "200": description: 正常 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/ProjectMember" - page_no: - type: number - description: 現在のページ番号です。 - total_page_no: - type: number - description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトメンバーが0件であっても、総ページ数は1となります。 - total_count: - type: number - description: 検索結果の総件数。 - over_limit: - type: boolean - description: 検索結果が1万件を超えた場合にtrueとなる。 - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - description: Aggregationによる集約結果。 - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/members/{user_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMemberList + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/members/{user_id}": get: tags: - - af-project-member + - af-project-member summary: プロジェクトメンバー取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getProjectMember parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: user_id - in: path - description: アカウントのユーザID. RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 - required: true - schema: - $ref: "#/components/schemas/UserId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: user_id + in: path + description: アカウントのユーザID. + RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/ProjectMember" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-project-member + - af-project-member summary: プロジェクトメンバー作成/更新 - description: | + description: "" security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putProjectMember parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: user_id - in: path - description: アカウントのユーザID. RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 - required: true - schema: - $ref: "#/components/schemas/UserId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: user_id + in: path + description: アカウントのユーザID. + RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/ProjectMemberRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMemberRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/ProjectMember" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/tasks: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/tasks": get: tags: - - af-statistics + - af-statistics summary: タスク集計取得 description: | 日ごと、タスクフェーズごと、タスクステータスごとに集計した以下のデータを取得します。 * タスク数 * 累計作業時間 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTaskStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/ProjectTaskStatisticsHistory" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/accounts: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectTaskStatisticsHistory + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/accounts": get: tags: - - af-statistics + - af-statistics summary: ユーザー別タスク集計取得 description: | ユーザごと、日ごとに集計した以下のデータを取得します。 @@ -2336,151 +2392,153 @@ paths: * 教師付を担当したタスクが差し戻された回数 * 作業時間 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAccountStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/ProjectAccountStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/inspections: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectAccountStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/inspections": get: tags: - - af-statistics + - af-statistics summary: 検査コメント集計取得 description: | ラベルごと、定型指摘ごとに集計した検査コメント数を取得します。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInspectionStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/InspectionStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/task-phases: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InspectionStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/task-phases": get: tags: - - af-statistics + - af-statistics summary: フェーズ別タスク集計取得 description: | 日ごと、フェーズごとに集計した以下のデータを取得します。 * 累積作業時間 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTaskPhaseStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/TaskPhaseStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/labels: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhaseStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/labels": get: tags: - - af-statistics + - af-statistics summary: ラベル別アノテーション数集計取得 description: | ラベルごとの以下集計データを取得します。 * 受入が完了したアノテーション数 * 受入が完了していないアノテーション数 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getLabelStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/LabelStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/worktimes: + $ref: swagger-api-components.redoc.yaml#/components/schemas/LabelStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/worktimes": get: tags: - - af-statistics + - af-statistics summary: タスク作業時間集計取得 - description: | + description: > 単位当たり(タスク1個、画像1個、動画1分)の作業時間情報が格納されたファイルに対して、認証済み一時URLを取得します。認証済み一時URLはLocationヘッダに格納されています。 + ヒストグラムは最終日のby_tasks、by_inputsでのみ返却する。 + アカウント毎の集計のby_tasks、by_inputsには、最終日であってもヒストグラムを返却しない。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getWorktimeStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 headers: Location: @@ -2492,217 +2550,210 @@ paths: schema: type: array items: - $ref: "#/components/schemas/WorktimeStatistics" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/statistics/markers: + $ref: swagger-api-components.redoc.yaml#/components/schemas/WorktimeStatistics + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/statistics/markers": get: tags: - - af-statistics + - af-statistics summary: 統計グラフマーカー取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getMarkers parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Markers" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Markers + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-statistics + - af-statistics summary: 統計グラフマーカー更新 - description: | + description: "" security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putMarkers parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/PutMarkersRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/PutMarkersRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Markers" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/jobs: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Markers + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/jobs": get: tags: - - af-job + - af-job summary: バックグラウンドジョブ情報取得 description: | バックグラウンドジョブの情報を取得する。 取得されるジョブの情報は作成日付の新しい順にソートされる。 バックグラウンドジョブ情報は完了(失敗含む)から14日経過後に削除される。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getProjectJob parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: type - in: query - description: 取得するジョブの種別。[詳細はこちら](#section/JobType)。 - required: true - schema: - $ref: "#/components/schemas/JobType" - - name: page - in: query - description: | - 検索結果のうち、取得したいページの番号(1始まり) - - 現在は未実装のパラメータです。(今後対応予定) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: | - 1ページあたりの取得するデータ件数。 - 未指定時は1件のみ取得。 - required: false - schema: - type: integer - minimum: 0 - maximum: 200 - default: 1 - - name: exclusive_start_created_datetime - in: query - description: 取得するデータの直前の作成日時 - required: false - schema: - type: string + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: type + in: query + description: 取得するジョブの種別。[詳細はこちら](#section/JobType)。 + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/JobType + - name: page + in: query + description: | + 検索結果のうち、取得したいページの番号(1始まり) + + 現在は未実装のパラメータです。(今後対応予定) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: | + 1ページあたりの取得するデータ件数。 + 未指定時は1件のみ取得。 + required: false + schema: + type: integer + minimum: 0 + maximum: 200 + default: 1 + - name: exclusive_start_created_datetime + in: query + description: 取得するデータの直前の作成日時 + required: false + schema: + type: string responses: - 200: + "200": description: 正常 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/JobInfo" - has_next: - type: boolean - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/jobs/gen-inputs/{job_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/JobInfoContainer + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/jobs/gen-inputs/{job_id}": delete: tags: - - af-job + - af-job summary: バックグラウンドジョブ情報削除 - description: | + description: "" security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteProjectJob parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: job_id - in: path - description: ジョブID - required: true - schema: - $ref: "#/components/schemas/JobId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: job_id + in: path + description: ジョブID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/JobId responses: - 200: + "200": description: 正常 - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/webhooks: + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/webhooks": get: tags: - - af-webhook + - af-webhook summary: プロジェクトのWebhookをすべて取得 - description: | + description: "" security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: getWebhooks parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/Webhook" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/webhooks/{webhook_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Webhook + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/webhooks/{webhook_id}": put: tags: - - af-webhook + - af-webhook summary: プロジェクトのWebhookを更新 description: | プロジェクトのWebhookを新規登録/更新することができます。 @@ -2738,83 +2789,82 @@ paths: * {{DEST_PROJECT_TITLE}} : コピー先プロジェクトタイトル * {{COMPLETE_DATETIME}} : 完了日時 * 例 : 2019-05-08T10:00:00.000+09:00 - security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putWebhook parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: webhook_id - in: path - description: | - WebhookID。[値の制約についてはこちら。](#section/API-Convention/APIID) - required: true - schema: - $ref: "#/components/schemas/WebhookId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: webhook_id + in: path + description: | + WebhookID。[値の制約についてはこちら。](#section/API-Convention/APIID) + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/Webhook" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Webhook responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Webhook" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Webhook + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance delete: tags: - - af-webhook + - af-webhook summary: プロジェクトのWebhookを削除 - description: | + description: "" security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteWebhook parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: webhook_id - in: path - description: WebhookID - required: true - schema: - $ref: "#/components/schemas/WebhookId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: webhook_id + in: path + description: WebhookID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Webhook" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/webhooks/{webhook_id}/test: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Webhook + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/webhooks/{webhook_id}/test": post: tags: - af-webhook summary: プロジェクトのWebhookをテスト実行 - description: | + description: "" security: - ProjectOwner: [] operationId: testWebhook @@ -2824,201 +2874,199 @@ paths: description: プロジェクトID required: true schema: - $ref: "#/components/schemas/ProjectId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - name: webhook_id in: path description: WebhookID required: true schema: - $ref: "#/components/schemas/WebhookId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/WebhookTestRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookTestRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/WebhookTestResponse" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/annotation-specs: + $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookTestResponse + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/annotation-specs": get: tags: - - af-annotation-specs + - af-annotation-specs summary: アノテーション仕様取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAnnotationSpecs parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: history_id - in: query - description: | - 過去のアノテーション仕様を取得する場合、[アノテーション仕様履歴取得](#operation/getAnnotationSpecsHistories)APIで取得した `history_id` の値を指定します。 - 未指定時は最新のアノテーション仕様を取得します。 - required: false - schema: - type: string - example: "123456789" - - name: v - in: query - description: | - 取得するアノテーション仕様のフォーマットバージョンを指定します。 - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: history_id + in: query + description: > + 過去のアノテーション仕様を取得する場合、[アノテーション仕様履歴取得](#operation/getAnnotationSpecsHistories)APIで取得した + `history_id` の値を指定します。 + + 未指定時は最新のアノテーション仕様を取得します。 + required: false + schema: + type: string + example: "123456789" + - name: v + in: query + description: | + 取得するアノテーション仕様のフォーマットバージョンを指定します。 + required: false + schema: + type: string + default: "1" + example: "2" responses: - 200: + "200": description: 正常 content: application/json: schema: - oneOf: - - $ref: "#/components/schemas/AnnotationSpecsV1" - - $ref: "#/components/schemas/AnnotationSpecsV2" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecs + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-annotation-specs + - af-annotation-specs summary: アノテーション仕様更新 - description: | + description: "" security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putAnnotationSpecs parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - requestBody: - required: true + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + requestBody: + required: true content: application/json: schema: - oneOf: - - $ref: "#/components/schemas/AnnotationSpecsRequestV2" - - $ref: "#/components/schemas/AnnotationSpecsRequestV1" + $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecsRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/AnnotationSpecsV2" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/annotation-specs-histories: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecsV2 + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/annotation-specs-histories": get: tags: - - af-annotation-specs + - af-annotation-specs summary: アノテーション仕様履歴取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAnnotationSpecsHistories parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/AnnotationSpecsHistory" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/start-task: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecsHistory + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/start-task": post: deprecated: true tags: - - af-task + - af-task summary: タスク割当 description: | タスクの割当を要求します。 個々のタスクの情報を取得する場合は、[タスク取得](#operation/getTask)を使います。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: startTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/TaskStart" + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskStart responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Task" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: タスクを開始できる状態ではない content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/tasks: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/tasks": get: tags: - - af-task + - af-task summary: タスク一括取得 description: | プロジェクトに含まれる複数のタスクをまとめて取得します。 @@ -3027,163 +3075,135 @@ paths: パフォーマンスのため、結果はページング形式で返ります。全件取得したい場合は、レスポンスを見て、ページ移動してください。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTasks parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: page - in: query - description: 検索結果のうち、取得したいページの番号(1始まり) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 1 - maximum: 200 - default: 30 - - name: task_id - in: query - description: タスクIDでの部分一致検索で使用。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません - required: false - schema: - $ref: "#/components/schemas/TaskId" - - name: input_data_ids - in: query - description: 指定された入力データIDを使用しているタスクを絞り込みます。カンマ区切りで複数の入力データIDを指定可能です。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません - required: false - schema: - $ref: "#/components/schemas/InputDataId" - - name: phase - in: query - description: 絞り込み条件となるフェーズ名。未指定時は全フェーズ - required: false - schema: - $ref: "#/components/schemas/TaskPhase" - - name: phase_stage - in: query - description: 絞り込み条件となるステージ。未指定時は全ステージ - required: false - schema: - $ref: "#/components/schemas/TaskPhaseStage" - - name: status - in: query - description: 絞り込み条件となる状態名。未指定時は全ステータス。 - required: false - schema: - $ref: "#/components/schemas/TaskStatus" - - name: account_id - in: query - description: 絞り込み条件となる作業中のアカウントID。未指定時は全アカウント - required: false - schema: - $ref: "#/components/schemas/AccountId" - - name: no_user - in: query - description: 未割り当てのタスクを絞り込む時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string - - name: previous_account_id - in: query - description: そのタスクをこれまでに担当したことのあるユーザー(現在の担当者含む)のアカウントID。未指定時は全ユーザ - required: false - schema: - $ref: "#/components/schemas/AccountId" - - name: previous_phase - in: query - description: そのタスクがこれまでに遷移したことのあるフェーズ名(現在のフェーズ含む)。未指定時は全フェーズ - required: false - schema: - $ref: "#/components/schemas/TaskPhase" - - name: previous_phase_stage - in: query - description: そのタスクがこれまでに遷移したことのあるステージ(現在のステージ含む)。未指定時は全ステージ - required: false - schema: - $ref: "#/components/schemas/TaskPhaseStage" - - name: rejected_only - in: query - description: 差し戻されたタスクだけを絞り込む時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string - - name: auto_accepted_only - in: query - description: 「抜取検査の対象外となり、自動受入されたタスク」だけを絞り込む時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string - - name: sort - in: query - description: | - ソート順の指定。 - 使用可能キーはtask_id、updated_datetime、number_of_rejections、phase、phase_stage、status、account_idのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 - 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 - required: false - example: account_id,-updated_datetime - schema: - type: string + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: page + in: query + description: 検索結果のうち、取得したいページの番号(1始まり) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 1 + maximum: 200 + default: 30 + - name: task_id + in: query + description: タスクIDでの部分一致検索で使用。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: input_data_ids + in: query + description: 指定された入力データIDを使用しているタスクを絞り込みます。カンマ区切りで複数の入力データIDを指定可能です。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: phase + in: query + description: 絞り込み条件となるフェーズ名。未指定時は全フェーズ + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhase + - name: phase_stage + in: query + description: 絞り込み条件となるステージ。未指定時は全ステージ + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhaseStage + - name: status + in: query + description: 絞り込み条件となる状態名。未指定時は全ステータス。 + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskStatus + - name: account_id + in: query + description: 絞り込み条件となる作業中のアカウントID。未指定時は全アカウント + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + - name: no_user + in: query + description: 未割り当てのタスクを絞り込む時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string + - name: previous_account_id + in: query + description: そのタスクをこれまでに担当したことのあるユーザー(現在の担当者含む)のアカウントID。未指定時は全ユーザ + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + - name: previous_phase + in: query + description: そのタスクがこれまでに遷移したことのあるフェーズ名(現在のフェーズ含む)。未指定時は全フェーズ + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhase + - name: previous_phase_stage + in: query + description: そのタスクがこれまでに遷移したことのあるステージ(現在のステージ含む)。未指定時は全ステージ + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhaseStage + - name: rejected_only + in: query + description: 差し戻されたタスクだけを絞り込む時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string + - name: auto_accepted_only + in: query + description: 「抜取検査の対象外となり、自動受入されたタスク」だけを絞り込む時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string + - name: sort + in: query + description: > + ソート順の指定。 + + 使用可能キーはtask_id、updated_datetime、number_of_rejections、phase、phase_stage、status、account_idのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 + + 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 + required: false + example: account_id,-updated_datetime + schema: + type: string responses: - 200: + "200": description: 指定された条件にあてはまるタスクを返します。条件にあてはまるタスクが多数に及ぶことがあるので、すべての結果を得るにはページングしてください。 content: application/json: schema: - type: object - required: - - list - - page_no - - total_page_no - - total_count - - over_limit - - aggregations - properties: - list: - type: array - items: - $ref: "#/components/schemas/Task" - description: 現在のページ番号に含まれる0件以上のタスクです。 - page_no: - type: number - description: 現在のページ番号です。 - total_page_no: - type: number - description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるタスク0件であっても、総ページ数は1となります。 - total_count: - type: number - description: 検索結果の総件数。 - over_limit: - type: boolean - description: 検索結果が1万件を超えた場合にtrueとなる。 - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - description: Aggregationによる集約結果。 - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskList + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance post: tags: - - af-task + - af-task summary: タスク一括更新 description: | タスクを一括更新します。 @@ -3194,15 +3214,15 @@ paths: 複数の操作のうち、1つでも失敗するとAPIのレスポンス全体としては失敗になります。 成功した部分までは反映されます。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: batchUpdateTasks parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId requestBody: required: true content: @@ -3210,65 +3230,82 @@ paths: schema: type: array items: - oneOf: - - $ref: "#/components/schemas/BatchTaskRequestItemDelete" + $ref: swagger-api-components.redoc.yaml#/components/schemas/BatchTaskRequestItem responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/Task" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: - # TODO Error定義構造化(KRSANNOFAC-1502) + $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: "#/components/schemas/Errors" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/generate-tasks: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/generate-tasks": post: tags: - - af-task + - af-task summary: タスク一括作成 - description: | + description: > 典型的なタスク作成ルールにもとづいた、一括作成を行うAPIです。 + タスク作成ルールは、リクエストペイロードの `task_generate_rule` フィールドで指定できます。
+ `ByCount` を指定した場合、1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。この作成ルールは、画像を同じ枚数均等にタスクに割り振りたい場合に便利です。
+ `ByDirectory` を指定した場合、入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。この作成ルールは、動画などから切り出した画像をディレクトリ別に格納し、、その動画(ディレクトリ)の単位でタスクを作りたい場合に便利です。 + `ByInputDataCsv` を指定した場合、入力データを各タスクに割り振ったCSVへのS3パスを指定してタスクを生成できます。この作成ルールは特定のデータの組み合わせを持ったタスクを作成したい場合に便利です。
+ 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-tasks`)。 + #### ByDirectory: ディレクトリ単位でのタスク一括生成の使い方 + 例えば、次のような `input_data_name_` の入力データが登録されているとします。 + * a.zip/dir1/image1.png + * a.zip/dir1/image2.png + * a.zip/dir1/subdir/image3.png + * a.zip/dir1/subdir/image4.png + * a.zip/dir1/subdir/image5.png + * b.zip/dir2/subdir1/image6.png + * b.zip/dir2/subdir1/image7.png + * b.zip/dir2/subdir1/image8.png + * b.zip/dir2/subdir2/image9.png + * b.zip/dir2/subdir2/image10.png + ここで、`input_data_name_prefix`フィールド に `a.zip` を指定すると、次の2タスクが生成されます。 + 1. タスク: `{task_id_prefix}_a.zip_dir1` * a.zip/dir1/image1.png * a.zip/dir1/image2.png @@ -3279,6 +3316,7 @@ paths: 次に、`input_data_name_prefix` に `b.zip/dir2` を指定すると、次の2タスクが生成されます。 + 1. タスク: `{task_id_prefix}_b.zip_dir2_subdir1` * b.zip/dir2/subdir1/image6.png * b.zip/dir2/subdir1/image7.png @@ -3289,6 +3327,7 @@ paths: `input_data_name_prefix` が未指定の時は、全ディレクトリごとにタスクが作成されます。つまり次のように4つのタスクが生成されます。 + 1. タスク: `{task_id_prefix}_a.zip_dir1` * a.zip/dir1/image1.png * a.zip/dir1/image2.png @@ -3305,215 +3344,237 @@ paths: * b.zip/dir2/subdir2/image10.png 画像プロジェクトの場合、タスクに割り当てられる「ディレクトリ内の入力データ」の順序は、名前の昇順となります。
+ 動画プロジェクトの場合、タスクに割り当てられる「ディレクトリ内の入力データ」の順序は、動画の入力データが先頭に来るようにソートされたうえで、名前の昇順となります。 + **注意:** `ByDirectory`では、入力データ名がファイルパス形式になっていない入力データはタスクの作成対象になりません。 + 例えば、`foo/bar.png` はタスクの作成対象になりますが、ディレクトリを含まない`bar.png` や、最後がディレクトリになっている`foo/bar.png/` は対象になりません。 + **注意:** 動画プロジェクトの場合、ディレクトリに含まれる動画の入力データは一つに制限してください。 + これが守られない場合、作成されたタスクで動画を再生できない場合があります。 + #### ByInputDataCsv: CSVによるタスク一括生成の使い方 + 以下のように「タスクID,入力データ名,入力データID」を1行毎に指定したCSVを作成します。 + ``` + task_1,a001.jpg,ca0cb2f9-fec5-49b4-98df-dc34490f9785 + task_1,a002.jpg,5ac1987e-ca7c-42a0-9c19-b5b23a41836b + task_1,centinel.jpg,81d6407b-2172-4fa8-8525-2e43c49267ee + task_2,b001.jpg,4f2ae4d0-7a38-4f9a-be6f-170ba76aba73 + task_2,b002.jpg,45ac5852-f20c-4938-9ee9-cc0274401df7 + task_2,centinel.jpg,81d6407b-2172-4fa8-8525-2e43c49267ee + task_3,c001.jpg,3260c7a0-4820-424d-a26e-db7e91dbc139 + task_3,centinel.jpg,81d6407b-2172-4fa8-8525-2e43c49267ee + ``` + CSVのエンコーディングは UTF-8(BOM付き)、UTF-8(BOMなし)、UTF-16(BOM付きLE) のいずれかのみ対応しています。 + **注意:** 動画プロジェクトの場合、一つのタスクに含まれる動画の入力データは一つに制限し、動画の入力データの位置は先頭にしてください。 + これが守られない場合、作成されたタスクで動画を再生できない場合があります。 + [createTempPath](#operation/createTempPath) APIを使ってアップロード用のURLとS3パスを取得してCSVをアップロードした上で`csv_data_path` フィールドに取得したS3パスを記述します。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: initiateTasksGeneration parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: v - in: query - description: | - APIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":Project - - "2":TaskGenerateResponse - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Project + - "2":TaskGenerateResponse + required: false + schema: + type: string + default: "1" + example: "2" requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/TaskGenerateRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskGenerateRequest responses: - 202: + "202": description: 正常 content: application/json: schema: - oneOf: - - $ref: "#/components/schemas/Project" - - $ref: "#/components/schemas/TaskGenerateResponse" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskGenerateResponseWrapper + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "409": description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/tasks/{task_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/tasks/{task_id}": get: tags: - - af-task + - af-task summary: タスク取得 description: | 個々のタスクの情報を取得します。 タスクを割り当てる場合は、[タスク割当](#operation/startTask)を使います。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: "#/components/schemas/TaskId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Task" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-task + - af-task summary: タスク作成/更新 - description: | + description: > 1つのタスクを作成または更新します。 + 複数のタスクを一括生成する場合は、効率のよい[一括作成API](#operation/initiateTasksGeneration)を検討してください。 + このAPIで変更できるのは、タスクの入力データ(`input_data_list`)のみです。タスクに割り当てた画像や動画などの入力データを差し替えることができます。 + タスクの担当者やステータスを変更するには、[タスク割当](#operation/startTask)や[タスクの状態遷移](#operation/operateTask)を使用します。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: | - タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) - required: true - schema: - $ref: "#/components/schemas/TaskId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: | + タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/TaskRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Task" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "409": description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance delete: tags: - - af-task + - af-task summary: タスク削除 description: | 不要になったタスクや、間違って投入したタスクを削除します。教師データなどは削除せず残すので、あとから復元することも可能です。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: "#/components/schemas/TaskId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId responses: - 200: + "200": description: 正常。削除したタスクを返します content: application/json: schema: - $ref: "#/components/schemas/Task" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/assign-tasks: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/assign-tasks": post: tags: - af-task @@ -3531,46 +3592,48 @@ paths: description: プロジェクトID required: true schema: - $ref: "#/components/schemas/ProjectId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/TaskAssignRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskAssignRequest responses: - 200: + "200": description: 正常。割当したタスクを返します。 content: application/json: schema: type: array items: - $ref: "#/components/schemas/Task" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: プロジェクトが停止中のため、タスクの割当ができない。 content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/tasks/{task_id}/operate: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/tasks/{task_id}/operate": post: tags: - - af-task + - af-task summary: タスク状態変更 - description: | + description: > タスクの状態、もしくはタスクの担当者を変更することができます。 + #### ユースケースごとの使い方 + * タスクを作業中(working)にしたい場合 * 制約 * 現在タスクを担当しているユーザーのみ、この操作を行うことができます。 @@ -3638,219 +3701,197 @@ paths: * リクエストボディのJSONサンプル * ```{ status: "not_started", last_updated_datetime: "2018-08-14T19:01:51.775+09:00"}``` security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: operateTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: "#/components/schemas/TaskId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/TaskOperation" + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskOperation responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Task" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: 指定された現在の状態が実際の現在の状態と食い違っている content: application/json: schema: - $ref: "#/components/schemas/ErrorStateMismatch" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/tasks/{task_id}/validation: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/tasks/{task_id}/validation": get: deprecated: true tags: - - af-task + - af-task summary: タスク自動検査 description: | 指定したタスクの自動検査で見つかった警告やエラーを一括で取得します。 [タスクの状態遷移](#operation/operateTask)の際に検査を行うようになったので、本APIは非推奨となります。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTaskValidation parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: "#/components/schemas/TaskId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/TaskValidation" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/tasks/{task_id}/histories: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskValidation + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/tasks/{task_id}/histories": get: tags: - - af-task + - af-task summary: タスク履歴一括取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTaskHistories parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: "#/components/schemas/TaskId" - responses: - 200: - description: 正常 - content: - application/json: - schema: - type: array - items: - $ref: "#/components/schemas/TaskHistory" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/annotations: + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + responses: + "200": + description: 正常 + content: + application/json: + schema: + type: array + items: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskHistory + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/annotations": get: tags: - - af-annotation + - af-annotation summary: アノテーション一括取得 - description: - 指定したタスク-入力データにつけられたアノテーションを一括で取得します。 + description: 指定したタスク-入力データにつけられたアノテーションを一括で取得します。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAnnotationList parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: page - in: query - description: 検索結果のうち、取得したいページの番号(1始まり) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 1 - maximum: 200 - default: 30 - - name: aggregate_by_task_and_input - in: query - description: trueを指定した場合に「タスクIDと入力IDの組」ごとに検索結果を集計するようにする。 - required: false - schema: - type: boolean - default: false - - name: query - in: query - description: | - 絞り込み条件をJSON形式で表したもの。 - required: false - example: {"label_id":"b048c6b3-b36f-4c8d-97ea-96828a50a44c"} - schema: - $ref: "#/components/schemas/AnnotationQuery" - - name: sort - in: query - description: | - ソート順の指定。 - 使用可能キーはtask_id, input_data_id, detail.annotation_id, detail.account_id, detail.label_id, detail.data_holding_type, detail.created_datetime, detail.updated_datetimeのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 - 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 - required: false - example: task_id,input_data_id,detail.annotation_id,-detail.updated_datetime - schema: - type: string + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: page + in: query + description: 検索結果のうち、取得したいページの番号(1始まり) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 1 + maximum: 200 + default: 30 + - name: aggregate_by_task_and_input + in: query + description: trueを指定した場合に「タスクIDと入力IDの組」ごとに検索結果を集計するようにする。 + required: false + schema: + type: boolean + default: false + - name: query + in: query + description: | + 絞り込み条件([AnnotationQuery](#section/AnnotationQuery))をJSON形式で表した文字列。 + required: false + example: '{"label_id":"b048c6b3-b36f-4c8d-97ea-96828a50a44c"}' + schema: + type: string + - name: sort + in: query + description: > + ソート順の指定。 + + 使用可能キーはtask_id, input_data_id, detail.annotation_id, detail.account_id, detail.label_id, detail.data_holding_type, detail.created_datetime, detail.updated_datetimeのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 + + 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 + required: false + example: task_id,input_data_id,detail.annotation_id,-detail.updated_datetime + schema: + type: string responses: - 200: + "200": description: 指定された条件にあてはまるアノテーションを返します。条件にあてはまるアノテーションが多数に及ぶことがあるので、すべての結果を得るにはページングしてください。 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/SingleAnnotation" - description: 現在のページ番号に含まれる0件以上のアノテーションです。 - page_no: - type: number - description: 現在のページ番号です。 - total_page_no: - type: number - description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるアノテーションが0件であっても、総ページ数は1となります。 - total_count: - type: number - description: 検索結果の総件数。 - over_limit: - type: boolean - description: 検索結果が1万件を超えた場合にtrueとなる。 - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - description: Aggregationによる集約結果。 - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationList + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance post: tags: - - af-annotation + - af-annotation summary: アノテーション一括更新 description: | 複数のアノテーションを一括更新します。 @@ -3877,15 +3918,15 @@ paths: 受入が完了しているタスクのアノテーション更新を含む場合、オーナー以上の権限が必要になります。 security: - - ProjectAccepter: [] + - ProjectAccepter: [] operationId: batchUpdateAnnotations parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId requestBody: required: true content: @@ -3893,46 +3934,47 @@ paths: schema: type: array items: - oneOf: - - $ref: "#/components/schemas/BatchAnnotationRequestItemPut" - - $ref: "#/components/schemas/BatchAnnotationRequestItemDelete" + $ref: swagger-api-components.redoc.yaml#/components/schemas/BatchAnnotationRequestItem responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/SingleAnnotation" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: - # TODO Error定義構造化(KRSANNOFAC-1502) + $ref: swagger-api-components.redoc.yaml#/components/schemas/SingleAnnotation + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: 停止中プロジェクトに対する操作、または、先に更新されているため失敗 content: application/json: schema: - $ref: "#/components/schemas/Errors" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/annotation: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/annotation": get: tags: - af-annotation summary: タスク/入力データのアノテーション一括取得 - description: | + description: > [putAnnotation](#operation/putAnnotation)が要求する構造のアノテーションを取得します。 + このAPIは、[putAnnotation](#operation/putAnnotation)をより利用しやすくする目的で提供しています。 + 機械学習などで利用する成果物としてのアノテーションを取得するには、以下をご利用いただけます。 + * [getAnnotation](#operation/getAnnotation): 特定のタスク - 入力データのアノテーション取得 + * [getAnnotationArchive](#operation/getAnnotationArchive): プロジェクト全体のアノテーション(ZIP) security: - AllProjectMember: [] @@ -3943,173 +3985,187 @@ paths: description: プロジェクトID required: true schema: - $ref: "#/components/schemas/ProjectId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - name: task_id in: path description: タスクID required: true schema: - $ref: "#/components/schemas/TaskId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId - name: input_data_id in: path description: 入力データID required: true schema: - $ref: "#/components/schemas/InputDataId" + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Annotation" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Annotation + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-annotation + - af-annotation summary: タスク-入力データのアノテーション更新 - description: | + description: > 「過去に誰にも割り当てられていないタスクに含まれる入力データ」に限り、プロジェクトオーナーであればアノテーションを更新できます。 + この挙動は、[AnnoFab外部で作成されたアノテーションをインポート](/docs/tutorial/tutorial-ex-importing-annotation.html) する目的にも利用できます。 + 1度でも誰かに割り当てられたタスクは、タスクの現在の担当者であればアノテーションを更新できます。 + タスクの現在の担当者でない場合、エラーになります。 + この制限は、アノテーション作業中の予期せぬ同時編集を防ぐためです。 + `is_protected`(保護) を `true` にすることで、アノテーションをアノテーションエディタ上での削除から保護できます。 + 属性の変更もさせたくない場合は、アノテーション仕様で特定の属性を読取専用にすることで保護できます。保護は、 + * 外部からインポートしたアノテーション + * 別プロジェクトからコピーしたアノテーション + などを誤って削除したくないときに便利です。 + `is_protected`は、プロジェクトオーナーのみ変更可能です。 + なお、本APIでは `is_protected` によらず、更新や削除が可能です。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: putAnnotation parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: "#/components/schemas/TaskId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/Annotation" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Annotation responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Annotation" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: - # TODO Error定義構造化(KRSANNOFAC-1502) + $ref: swagger-api-components.redoc.yaml#/components/schemas/Annotation + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: 停止中プロジェクトに対する操作、または、先に更新されているため失敗 content: application/json: schema: - $ref: "#/components/schemas/Errors" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/annotation/simple: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/annotation/simple": get: tags: - - af-annotation + - af-annotation summary: タスク-入力データのSimpleアノテーション一括取得 - description: | + description: > 指定したタスク - 入力データにつけられたアノテーションを一括で取得します。 + Simple版のアノテーションJSONは、機械学習の一般的な利用で扱いやすい構造になっています。 + なお、プロジェクト全体のアノテーションを一括で取得したい場合には、 [getAnnotationArchive](#operation/getAnnotationArchive) APIを使用することもできます。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAnnotation parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: "#/components/schemas/TaskId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/SimpleAnnotation" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/archive/full: + $ref: swagger-api-components.redoc.yaml#/components/schemas/SimpleAnnotation + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/archive/full": get: tags: - - af-annotation + - af-annotation summary: FullアノテーションZIP取得 - description: | + description: > プロジェクト内のアノテーション(Full版)がまとめられたZIPを取得するための、認証済み一時URLを取得します。 + 取得したURLは1時間で失効し、アクセスできなくなります。 + FullアノテーションZIPのデータ構造については、 [Full Annotation ZIP](#section/Full-Annotation-ZIP) を参照ください。 security: - - ProjectDataUser: [] - operationId: getArchiveFullWithProId #getFullAnnotationArchiveByProjectId + - ProjectDataUser: [] + operationId: getArchiveFullWithProId parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 headers: Location: @@ -4119,51 +4175,53 @@ paths: content: application/json: schema: - type: object - properties: - url: - type: string - description: 認証済み一時URL - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/archive/simple: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/archive/simple": get: tags: - - af-annotation + - af-annotation summary: SimpleアノテーションZIP取得 - description: | + description: > プロジェクト内のアノテーション(Simple版)がまとめられたZIPを取得するための、認証済み一時URLを取得します。 + 取得したURLは1時間で失効し、アクセスできなくなります。 + SimpleアノテーションZIPのデータ構造については、 [Simple Annotation ZIP](#section/Simple-Annotation-ZIP) を参照ください。 + なお、特定のタスクのSimpleアノテーションを取得したい場合には、 [getAnnotation](#operation/getAnnotation) APIを使用することもできます。 security: - - ProjectDataUser: [] + - ProjectDataUser: [] operationId: getAnnotationArchive parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: v2 - in: query - description: | - このクエリパラメータのキーだけを指定(`?v2`)、または値 `true` も指定(`?v2=true`)すると、アノテーションJSONのファイル名は `{入力データID}.json` になります。 - この v2 形式は、入力データ名がファイル名の長さ上限を上回ってもよいように再設計されたものです。 - 以前の v1 形式(アノテーションJSONのファイル名は `{入力データ名}.json` )はいずれ廃止され、クエリパラメータ `v2` があってもなくても v2 形式に置き換わる予定です。 - required: false - schema: - type: string - example: "true" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: v2 + in: query + description: > + このクエリパラメータのキーだけを指定(`?v2`)、または値 `true` + も指定(`?v2=true`)すると、アノテーションJSONのファイル名は `{入力データID}.json` になります。 + + この v2 形式は、入力データ名がファイル名の長さ上限を上回ってもよいように再設計されたものです。 + + 以前の v1 形式(アノテーションJSONのファイル名は `{入力データ名}.json` )はいずれ廃止され、クエリパラメータ `v2` があってもなくても v2 形式に置き換わる予定です。 + required: false + schema: + type: string + example: "true" responses: - 200: + "200": description: 正常 headers: Location: @@ -4173,110 +4231,106 @@ paths: content: application/json: schema: - type: object - properties: - url: - type: string - description: 認証済み一時URL - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/archive/update: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/archive/update": post: tags: - - af-annotation + - af-annotation summary: アノテーションZIP更新開始 - description: | + description: > プロジェクト内のアノテーションZIP(Simple版とFull版の両方)の更新を開始します。 + ZIPの更新は、データ量に応じて数分〜数十分かかります。 + アノテーションZIPは毎日AM 03:00 JSTごろに自動更新されますが、本APIを用いると、自動更新を待たずに更新を要求できます。 - 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-annotation`)。 + 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-annotation`)。 security: - - ProjectDataUser: [] + - ProjectDataUser: [] operationId: postAnnotationArchiveUpdate parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: v - in: query - description: | - APIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":Message - - "2":PostAnnotationArchiveUpdateResponse - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Message + - "2":PostAnnotationArchiveUpdateResponse + required: false + schema: + type: string + default: "1" + example: "2" responses: - 202: + "202": description: 正常 content: application/json: schema: - oneOf: - - $ref: "#/components/schemas/Message" - - $ref: "#/components/schemas/PostAnnotationArchiveUpdateResponse" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/inspections: + $ref: swagger-api-components.redoc.yaml#/components/schemas/PostAnnotationArchiveUpdateResponseWrapper + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/inspections": get: tags: - - af-inspection + - af-inspection summary: 検査コメント一括取得 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInspections parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: "#/components/schemas/TaskId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/Inspection" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Inspection + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance post: tags: - - af-inspection + - af-inspection summary: 検査コメント一括更新 description: | 検査コメントを一括更新します。 @@ -4290,27 +4344,27 @@ paths: 複数の操作のうち、1つでも失敗するとAPIのレスポンス全体としては失敗になります。 成功した部分までは反映されます。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: batchUpdateInspections parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: "#/components/schemas/TaskId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId requestBody: required: true content: @@ -4318,145 +4372,119 @@ paths: schema: type: array items: - oneOf: - - $ref: "#/components/schemas/BatchInspectionRequestItemPut" - - $ref: "#/components/schemas/BatchInspectionRequestItemDelete" + $ref: swagger-api-components.redoc.yaml#/components/schemas/BatchInspectionRequestItem responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/Inspection" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: - # TODO Error定義構造化(KRSANNOFAC-1502) + $ref: swagger-api-components.redoc.yaml#/components/schemas/Inspection + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: 停止中プロジェクトに対する操作、または、先に更新されているため失敗 content: application/json: schema: - $ref: "#/components/schemas/Errors" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/inputs: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/inputs": get: tags: - - af-input + - af-input summary: 入力データ一括取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInputDataList parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: input_data_id - in: query - description: 入力データIDでの部分一致検索で使用。1文字以上あれば使用します。 - required: false - schema: - $ref: "#/components/schemas/InputDataId" - - name: input_data_name - in: query - description: 入力データ名での部分一致検索で使用。1文字以上あれば使用します。 - required: false - schema: - type: string - - name: input_data_path - in: query - description: 入力データパスでの部分一致検索で使用。1文字以上あれば使用します。 - required: false - schema: - type: string - - name: task_id - in: query - description: 入力データが紐づくタスクIDの部分一致検索で使用。1文字以上あれば使用します。条件に合致した先頭100件のタスクに使われている入力データを検索します。 - required: false - schema: - type: string - - name: from - in: query - description: 更新日時での範囲検索で使用(ISO 8601 拡張形式) - required: false - schema: - type: string - format: date-time - - name: to - in: query - description: 更新日時での範囲検索で使用(ISO 8601 拡張形式) - required: false - schema: - type: string - format: date-time - - name: page - in: query - description: 検索結果のうち、取得したいページの番号(1始まり) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 1 - maximum: 200 - default: 30 + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: input_data_id + in: query + description: 入力データIDでの部分一致検索で使用。1文字以上あれば使用します。 + required: false + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: input_data_name + in: query + description: 入力データ名での部分一致検索で使用。1文字以上あれば使用します。 + required: false + schema: + type: string + - name: input_data_path + in: query + description: 入力データパスでの部分一致検索で使用。1文字以上あれば使用します。 + required: false + schema: + type: string + - name: task_id + in: query + description: 入力データが紐づくタスクIDの部分一致検索で使用。1文字以上あれば使用します。条件に合致した先頭100件のタスクに使われている入力データを検索します。 + required: false + schema: + type: string + - name: from + in: query + description: 更新日時での範囲検索で使用(ISO 8601 拡張形式) + required: false + schema: + type: string + format: date-time + - name: to + in: query + description: 更新日時での範囲検索で使用(ISO 8601 拡張形式) + required: false + schema: + type: string + format: date-time + - name: page + in: query + description: 検索結果のうち、取得したいページの番号(1始まり) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 1 + maximum: 200 + default: 30 responses: - 200: + "200": description: 指定された条件にあてはまる入力データを返します。条件にあてはまる入力データが多数に及ぶことがあるので、すべての結果を得るにはページングしてください。 content: application/json: schema: - type: object - properties: - list: - type: array - items: - $ref: "#/components/schemas/InputData" - description: 現在のページ番号に含まれる0件以上の入力データです。 - page_no: - type: number - description: 現在のページ番号です。 - total_page_no: - type: number - description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる入力データが0件であっても、総ページ数は1となります。 - total_count: - type: number - description: 検索結果の総件数。 - over_limit: - type: boolean - description: 検索結果が1万件を超えた場合にtrueとなる。 - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - description: Aggregationによる集約結果。 - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataList + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance post: tags: - - af-input + - af-input summary: 入力データ一括更新 description: | 入力データを一括更新します。 @@ -4467,15 +4495,15 @@ paths: 複数の操作のうち、1つでも失敗するとAPIのレスポンス全体としては失敗になります。 成功した部分までは反映されます。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: batchUpdateInputs parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId requestBody: required: true content: @@ -4483,89 +4511,97 @@ paths: schema: type: array items: - oneOf: - - $ref: "#/components/schemas/BatchInputDataRequestItemDelete" + $ref: swagger-api-components.redoc.yaml#/components/schemas/BatchInputDataRequestItem responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/InputData" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: - # TODO Error定義構造化(KRSANNOFAC-1502) + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: "#/components/schemas/Errors" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/inputs/{input_data_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/inputs/{input_data_id}": get: tags: - - af-input + - af-input summary: 入力データ取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInputData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/InputData" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-input + - af-input summary: | 入力データ更新 - description: | + description: > 入力データ(画像プロジェクトなら画像、動画プロジェクトなら動画や時系列データ)を登録します。 + 画像プロジェクトの場合、複数の画像ファイルをZIPでまとめてアップロードできます。ZIPは最大5GB、UTF-8エンコーディングのみ対応しています。
+ アノテーション作業生産性を高めるため、画像は「長辺4096px以内」かつ「4MB以内」になるよう圧縮されます。
+ 作成されるアノテーションは、元の解像度でつけた場合相当に自動で復元されます。 + 動画プロジェクトの場合、複数の動画ファイルをZIPでまとめてアップロードできます。ZIPは最大5GB、UTF-8エンコーディングのみ対応しています。
+ また、複数のストリーミング形式の動画をアップロードすることもできます。
+ この場合はZIP形式必須で、同一のZIPファイル内にm3u8ファイルとtsファイルを両方含めてください。
+ なお、このm3u8ファイルに記述された相対パスでtsファイルが参照可能である必要があります。 + ZIPファイルを登録するとバックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-inputs`)。 + ### ディレクトリ例 + ``` hoge.zip/ hoge.ts @@ -4579,137 +4615,136 @@ paths: bar.m3u8(hoge.ts, piyo1/piyo2/bar.tsを参照) ``` + ファイルの登録には、[アップロード用一時データ保存先作成API](#operation/createTempPath) を組み合わせて使用します。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putInputData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: input_data_id - in: path - description: | - 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) - required: true - schema: - $ref: "#/components/schemas/InputDataId" - - name: v - in: query - description: | - zipファイルを受領時のAPIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":登録処理を開始した旨の固定メッセージ - - "2":JobInfo - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: input_data_id + in: path + description: | + 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: v + in: query + description: | + zipファイルを受領時のAPIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":登録処理を開始した旨の固定メッセージ + - "2":JobInfo + required: false + schema: + type: string + default: "1" + example: "2" requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/InputDataRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/InputData" - 202: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData + "202": description: zipファイルを受領、バッチにて登録開始。 content: application/json: schema: - oneOf: - - $ref: "#/components/schemas/Message" - - $ref: "#/components/schemas/JobInfo" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 409: + $ref: swagger-api-components.redoc.yaml#/components/schemas/MessageOrJobInfo + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "409": description: 先に更新されているため失敗 content: application/json: schema: - $ref: "#/components/schemas/ErrorAlreadyUpdated" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorAlreadyUpdated + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance delete: tags: - - af-input + - af-input summary: 入力データ削除 - description: | + description: "" security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteInputData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId responses: - 200: + "200": description: 正常。削除した入力データを返します content: application/json: schema: - $ref: "#/components/schemas/InputData" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 403: - $ref: "#/components/responses/ErrorForbiddenResource" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/inputs/{input_data_id}/data: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "403": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/inputs/{input_data_id}/data": get: deprecated: true tags: - - af-input + - af-input summary: 実体参照用認証済みURL取得 description: | 入力データの実体(画像や動画などのファイルそのもの)にアクセスするための、認証済み一時URLを取得します。 取得したURLは、1時間で失効し、アクセスできなくなります。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getSignedUrlOfInputData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId responses: - 200: + "200": description: 正常 headers: Location: @@ -4721,143 +4756,145 @@ paths: schema: type: string description: 認証済み一時URL - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/inputs/{input_data_id}/supplementary-data: + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/inputs/{input_data_id}/supplementary-data": get: tags: - - af-supplementary + - af-supplementary summary: 補助情報一括取得 - description: | + description: "" security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getSupplementaryDataList parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/SupplementaryData" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/inputs/{input_data_id}/supplementary-data/{supplementary_data_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryData + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/inputs/{input_data_id}/supplementary-data/{supplementary_data_id}": put: tags: - - af-supplementary + - af-supplementary summary: 補助情報作成/更新 - description: | + description: "" security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putSupplementaryData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" - - name: supplementary_data_id - in: path - description: 補助情報ID(プロジェクトIDとの2つ組で一意となる値) - required: true - schema: - $ref: "#/components/schemas/SupplementaryDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: supplementary_data_id + in: path + description: 補助情報ID(プロジェクトIDとの2つ組で一意となる値) + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryDataId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/SupplementaryDataRequest" + $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryDataRequest responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/SupplementaryData" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryData + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance delete: tags: - - af-supplementary + - af-supplementary summary: 補助情報削除 - description: | + description: "" security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteSupplementaryData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: "#/components/schemas/InputDataId" - - name: supplementary_data_id - in: path - description: 補助情報ID(プロジェクトIDとの2つ組で一意となる値) - required: true - schema: - $ref: "#/components/schemas/SupplementaryDataId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: supplementary_data_id + in: path + description: 補助情報ID(プロジェクトIDとの2つ組で一意となる値) + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryDataId responses: - 200: + "200": description: 正常 - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/create-temp-path: + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/create-temp-path": post: tags: - - af-input + - af-input summary: 一時データ保存先取得 - description: | + description: > 「複数の入力データを圧縮したZIPファイル」や「4MBを超える画像」などをAnnoFabに一時的に保存するための、URLと登録用データパスを発行します。 + このAPIと他のAPIを以下に示すように使うことで、ZIPファイルなどをAFにアップロードできます。 + 1. 本APIを実行して、URLを取得する。 * `curl -X POST -H 'Content-Type: {CONTENT_TYPE_HERE}' 'https://annofab.com/api/v1/projects/{project_id}/create-temp-path'` 2. 1で取得したURLに、一時保存したいファイルをPUTする。 @@ -4866,4407 +4903,277 @@ paths: * `curl -X PUT -H 'Content-Type: text/json' -d '{"input_data_name":"{表示名}", "input_data_path":"{登録用データパス}" }' 'https://annofab.com/api/v1/projects/{project_id}/inputs/{input_data_id}'` ここで、1と2で `CONTENT_TYPE_HERE` は必ず一致しなければいけません。 + ZIPファイルの場合は `application/zip` 、画像ファイルの場合は `image/png` など、適切な Content-Type を指定します。 + 登録するファイルはどのような内容であれ、アップロードから24時間経過すると削除されます。 + したがって、ZIP圧縮した入力データを登録する場合は、URL発行から24時間以内に完了してください。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: createTempPath parameters: - - in: header - name: Content-Type - schema: - type: string - example: "application/zip" - description: | - アップロードしたいファイルの Content-Type を指定します。 - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - in: header + name: Content-Type + schema: + type: string + example: application/zip + description: | + アップロードしたいファイルの Content-Type を指定します。 + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: | 何らかのファイルをAnnoFabに一時的に保存するためのアップロード先URL content: application/json: schema: - $ref: "#/components/schemas/DataPath" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/instruction: + $ref: swagger-api-components.redoc.yaml#/components/schemas/DataPath + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/instruction": get: tags: - - af-instruction + - af-instruction summary: 作業ガイドの取得 description: | 指定された版の作業ガイドのHTMLを取得します。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInstruction parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: history_id - in: query - description: 取得する版の履歴ID - required: true - schema: - type: string - example: "ed55914c-9f04-470e-8af2-373c8def3e8b" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: history_id + in: query + description: 取得する版の履歴ID + required: true + schema: + type: string + example: ed55914c-9f04-470e-8af2-373c8def3e8b responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/Instruction" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Instruction + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance put: tags: - - af-instruction + - af-instruction summary: 作業ガイドの更新 description: | 作業ガイドのHTMLを更新します。 security: - - ProjectOwner: [] - - ProjectAccepter: [] + - ProjectOwner: [] + - ProjectAccepter: [] operationId: putInstruction parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/Instruction" + $ref: swagger-api-components.redoc.yaml#/components/schemas/Instruction responses: - 200: + "200": description: 作業ガイドの更新が成功した。 content: application/json: schema: - $ref: "#/components/schemas/InstructionHistory" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/instruction-history: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InstructionHistory + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/instruction-history": get: tags: - - af-instruction + - af-instruction summary: 作業ガイドの編集履歴の取得 description: | プロジェクトの作業ガイドの編集履歴を取得します。 取得される編集履歴は日付の新しい順にソートされます。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInstructionHistory parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: limit - in: query - description: 取得する編集履歴の件数 - required: false - schema: - type: integer - minimum: 30 + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: limit + in: query + description: 取得する編集履歴の件数 + required: false + schema: + type: integer + minimum: 30 responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/InstructionHistory" - 400: - $ref: "#/components/responses/ErrorInvalidRequest" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/instruction-images: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InstructionHistory + "400": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/instruction-images": get: tags: - - af-instruction + - af-instruction summary: 作業ガイドの画像一覧の取得 description: | プロジェクトの作業ガイドの画像一覧を取得します。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInstructionImages parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId responses: - 200: + "200": description: 正常 content: application/json: schema: type: array items: - $ref: "#/components/schemas/InstructionImage" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/instruction-images/{image_id}: + $ref: swagger-api-components.redoc.yaml#/components/schemas/InstructionImage + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/instruction-images/{image_id}": delete: tags: - - af-instruction + - af-instruction summary: 作業ガイドの画像削除 description: | プロジェクトの作業ガイドの画像を削除します。 security: - - ProjectOwner: [] - - ProjectAccepter: [] + - ProjectOwner: [] + - ProjectAccepter: [] operationId: deleteInstructionImage parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: image_id - in: path - description: 作業ガイド画像ID - required: true - schema: - type: string - example: "ed55914c-9f04-470e-8af2-373c8def3e8b" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: image_id + in: path + description: 作業ガイド画像ID + required: true + schema: + type: string + example: ed55914c-9f04-470e-8af2-373c8def3e8b responses: - 200: + "200": description: 正常 - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" - /projects/{project_id}/instruction-images/{image_id}/put-url: + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + "/projects/{project_id}/instruction-images/{image_id}/put-url": get: tags: - - af-instruction + - af-instruction summary: 作業ガイドの画像登録・更新用URL取得 - description: | + description: > プロジェクトの作業ガイドの画像を登録するためのput先URLを取得します。 + リクエストヘッダには、登録する画像に応じた適切な Content-Type を指定してください。 + 作業ガイド画像の登録/更新方法は以下の通りです。 + 1. `getInstructionImageUrlForPut` APIを実行して、ファイルアップロード用のURLを取得する。 * `curl -X GET -H 'Content-Type: {CONTENT_TYPE_HERE}' 'https://annofab.com/api/v1/projects/{project_id}/instruction-images/{image_id}/put-url'` 2. 手順1で取得したファイルアップロード用のURLに対して、登録/更新する作業ガイド画像ファイル(`hoge.jpg`)をPUTする。 * `curl -X PUT -H 'Content-Type: {CONTENT_TYPE_HERE}' --data-binary @/hoge.jpg '{ファイルアップロード用のURL}'` 手順1と2で `CONTENT_TYPE_HERE` は必ず一致しなければいけません。 - security: - - ProjectOwner: [] - - ProjectAccepter: [] + - ProjectOwner: [] + - ProjectAccepter: [] operationId: getInstructionImageUrlForPut parameters: - - in: header - name: Content-Type - schema: - type: string - example: "image/png" - description: | - 登録する画像ファイルの Content-Type を指定します。 - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: "#/components/schemas/ProjectId" - - name: image_id - in: path - description: 作業ガイド画像ID - required: true - schema: - type: string - example: "ed55914c-9f04-470e-8af2-373c8def3e8b" + - in: header + name: Content-Type + schema: + type: string + example: image/png + description: | + 登録する画像ファイルの Content-Type を指定します。 + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: image_id + in: path + description: 作業ガイド画像ID + required: true + schema: + type: string + example: ed55914c-9f04-470e-8af2-373c8def3e8b responses: - 200: + "200": description: 正常 content: application/json: schema: - $ref: "#/components/schemas/InstructionImagePath" - 401: - $ref: "#/components/responses/ErrorUnauthorizedApi" - 404: - $ref: "#/components/responses/ErrorMissingResource" - 503: - $ref: "#/components/responses/ErrorUnderMaintenance" -components: - securitySchemes: - SignedCookieKeyPairId: - description: | - 認証/認可には、[sign-url](#operation/getSignedAccessV2) APIで取得した署名付きCookieを使います。 - type: "apiKey" - in: "cookie" - name: "CloudFront-Key-Pair-Id" - SignedCookiePolicy: - description: | - 認証/認可には、[sign-url](#operation/getSignedAccessV2) APIで取得した署名付きCookieを使います。 - type: "apiKey" - in: "cookie" - name: "CloudFront-Policy" - SignedCookieSignature: - description: | - 認証/認可には、[sign-url](#operation/getSignedAccessV2) APIで取得した署名付きCookieを使います。 - type: "apiKey" - in: "cookie" - name: "CloudFront-Signature" - EveryoneRequestBody: - description: | - AnnoFabのユーザーなら誰でも利用できます。 - - 認証/認可には、リクエストボディに含まれるパスワード、トークン、または何らかの検証コードを用います。 - 詳しくは個別のAPIの説明を確認してください。 - type: "http" - scheme: "requestBody" - EveryoneQueryParameter: - description: | - AnnoFabのユーザーなら誰でも利用できます。 - - 認証/認可には、クエリパラメータに含まれるトークンまたは何らかの検証コードを用います。 - 詳しくは個別のAPIの説明を確認してください。 - type: "http" - scheme: "requestBody" - Everyone: - description: | - AnnoFabのユーザーなら誰でも利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - AnnoFabAdminOnly: - description: | - AnnoFabのシステム管理者のみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - AllProjectMember: - description: | - プロジェクトに所属するユーザーなら誰でも利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - ProjectAccepter: - description: | - プロジェクトのオーナーまたはプロジェクトのチェッカーのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - ProjectDataUser: - description: | - プロジェクトのオーナーまたはプロジェクトのアノテーションユーザーのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - ProjectAccepterOrDataUser: - description: | - プロジェクトのオーナー/チェッカー/アノテーションユーザーのいずれかのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - ProjectOwner: - description: | - プロジェクトのオーナーのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - AllOrganizationMember: - description: | - 組織に所属するユーザーなら誰でも利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - OrganizationAdministrator: - description: | - 組織のオーナーまたは組織の管理者のみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - OrganizationOwner: - description: | - 組織のオーナーのみ利用できます。 - - 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 - IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 - type: "apiKey" - name: "Authorization" - in: "header" - responses: - SuccessMessage: - description: 成功時のメッセージ - content: - application/json: - schema: - $ref: "#/components/schemas/Message" - ErrorForbiddenResource: - description: 権限エラー - content: - application/json: - schema: - $ref: "#/components/schemas/ErrorForbiddenResource" - ErrorMissingResource: - description: 存在しないリソースを指定された - content: - application/json: - schema: - $ref: "#/components/schemas/ErrorMissingResource" - ErrorUnauthorizedApi: - description: 認証エラー - content: - application/json: - schema: - $ref: "#/components/schemas/ErrorUnauthorizedApi" - ErrorInvalidRequest: - description: リクエスト形式が正しくない。必要な属性が足りなかったり、属性が特定の値 - content: - application/json: - schema: - # TODO このエラー定義には複数のschemaのエラーが該当しうる。それを記述する(KRSANNOFAC-1502) - $ref: "#/components/schemas/Errors" - ErrorUnderMaintenance: - description: システムメンテナンス中 - content: - application/json: - schema: - $ref: "#/components/schemas/ErrorUnderMaintenance" - ErrorRefreshTokenExpired: - description: リフレッシュトークン有効期限切れのため、明示的にログインする必要があります - content: - application/json: - schema: - $ref: "#/components/schemas/ErrorRefreshTokenExpired" - schemas: - ProjectCacheRecord: - type: object - properties: - input: - type: string - members: - type: string - project: - type: string - instruction: - type: string - specs: - type: string - statistics: - type: string - organization: - type: string - supplementary: - type: string - Errors: - type: object - properties: - errors: - type: array - items: - $ref: "#/components/schemas/Error" - context: - type: object - description: 内部補足情報 - Error: - type: object - properties: - error_code: - type: string - message: - type: string - description: エラーの概要 - ext: - type: object - description: 補足情報 - ErrorInvalidBody: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INVALID_BODY - context: - type: object - description: 内部補足情報 - ErrorInvalidQueryParam: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INVALID_QUERYPARAM - context: - type: object - description: 内部補足情報 - ErrorMissingNecessaryQueryParam: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: MISSING_NECESSARY_QUERYPARAM - context: - type: object - description: 内部補足情報 - ErrorInvalidPath: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INVALID_PATH - context: - type: object - description: 内部補足情報 - ErrorUnauthorizedApi: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: UNAUTHORIZED_API - context: - type: object - description: 内部補足情報 - ErrorLoginFailed: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: LOGIN_FAILED - context: - type: object - description: 内部補足情報 - ErrorPasswordResetRequired: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: PASSWORD_RESET_REQUIRED - context: - type: object - description: 内部補足情報 - ErrorExpiredToken: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: EXPIRED_TOKEN - context: - type: object - description: 内部補足情報 - ErrorRefreshTokenExpired: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: EXPIRED_REFRESH_TOKEN - context: - type: object - description: 内部補足情報 - ErrorForbiddenResource: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: FORBIDDEN_RESOURCE - context: - type: object - description: 内部補足情報 - ErrorMissingResource: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: MISSING_RESOURCE - context: - type: object - description: 内部補足情報 - ErrorTimeout: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: TIMEOUT - context: - type: object - description: 内部補足情報 - ErrorAlreadyUpdated: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: ALREADY_UPDATED - context: - type: object - description: 内部補足情報 - ErrorStateMismatch: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: STATE_MISMATCH - context: - type: object - description: 内部補足情報 - ErrorInternalServerError: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INTERNAL_SERVER_ERROR - context: - type: object - description: 内部補足情報 - ErrorUnderMaintenance: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: UNDER_MAINTENANCE - context: - type: object - description: 内部補足情報 - Message: - type: object - properties: - message: - type: string - description: 多言語対応 - InternationalizationMessage: - type: object - properties: - messages: - type: array - items: - type: object - properties: - lang: - type: string - message: - type: string - default_lang: - type: string - SignUpRequest: - type: object - required: - - email - properties: - email: - type: string - format: email - ConfirmSignUpRequest: - type: object - required: - - account_id - - user_id - - password - - username - - lang - - keylayout - - confirmation_code - properties: - account_id: - $ref: "#/components/schemas/AccountId" - user_id: - $ref: "#/components/schemas/UserId" - password: - type: string - username: - type: string - lang: - type: string - keylayout: - type: string - confirmation_code: - type: string - LoginRequest: - type: object - required: - - user_id - - password - properties: - user_id: - $ref: "#/components/schemas/UserId" - password: - type: string - LoginResponse: - type: object - properties: - token: - $ref: "#/components/schemas/Token" - Token: - type: object - properties: - id_token: - type: string - description: 形式は[JWT](https://jwt.io/)。 - access_token: - type: string - description: 形式は[JWT](https://jwt.io/)。 - refresh_token: - type: string - description: 形式は[JWT](https://jwt.io/)。 - RefreshTokenRequest: - type: object - required: - - refresh_token - properties: - refresh_token: - type: string - ChangePasswordRequest: - type: object - required: - - user_id - - old_password - - new_password - properties: - user_id: - $ref: "#/components/schemas/UserId" - old_password: - type: string - new_password: - type: string - PasswordResetRequest: - type: object - required: - - email - properties: - email: - type: string - format: email - ConfirmResetPasswordRequest: - type: object - required: - - user_id - - confirmation_code - - new_password - properties: - user_id: - $ref: "#/components/schemas/UserId" - confirmation_code: - type: string - new_password: - type: string - ResetEmailRequest: - type: object - required: - - email - properties: - email: - type: string - format: email - ConfirmResetEmailRequest: - type: object - required: - - token - properties: - token: - type: string - VerifyEmailRequest: - type: object - required: - - token - properties: - token: - $ref: "#/components/schemas/Token" - ConfirmVerifyEmailRequest: - type: object - required: - - token - - confirmation_code - properties: - token: - $ref: "#/components/schemas/Token" - confirmation_code: - type: string - ConfirmAccountDeleteRequest: - type: object - required: - - token - properties: - token: - type: string - Account: - type: object - required: - - account_id - - user_id - - username - - email - - lang - - keylayout - - authority - properties: - account_id: - $ref: "#/components/schemas/AccountId" - user_id: - $ref: "#/components/schemas/UserId" - username: - type: string - email: - type: string - format: email - lang: - type: string - biography: - $ref: "#/components/schemas/UserBiography" - keylayout: - type: string - authority: - $ref: "#/components/schemas/AccountAuthority" - updated_datetime: - type: string - format: date-time - AccountAuthority: - type: string - enum: - - user - - admin - MyAccount: - allOf: - - $ref: "#/components/schemas/Account" - - type: object - required: - - errors - properties: - reset_requested_email: - type: string - format: email - errors: - type: array - items: - type: string - PutMyAccountRequest: - type: object - required: - - user_id - - username - - lang - - keylayout - properties: - user_id: - $ref: "#/components/schemas/UserId" - username: - type: string - lang: - type: string - keylayout: - type: string - biography: - $ref: "#/components/schemas/UserBiography" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - LastUpdatedDatetime: - type: string - format: date-time - description: | - 新規作成時は未指定、更新時は必須(更新前の日時) - AcceptOrganizationInvitationRequest: - type: object - properties: - token: - type: string - OrganizationActivity: - type: object - required: - - organization_id - - created_datetime - - storage_usage_bytes - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - created_datetime: - type: string - format: date-time - storage_usage_bytes: - type: number - Organization: - type: object - required: - - organization_id - - organization_name - - email - - price_plan - - summary - - created_datetime - - updated_datetime - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - organization_name: - type: string - email: - type: string - format: email - price_plan: - $ref: "#/components/schemas/PricePlan" - summary: - $ref: "#/components/schemas/OrganizationSummary" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - OrganizationCacheRecord: - type: object - properties: - input: - type: string - members: - type: string - statistics: - type: string - organization: - type: string - OrganizationSummary: - type: object - properties: {} - PricePlan: - type: string - enum: - - free - - business - OrganizationMember: - type: object - required: - - organization_id - - account_id - - user_id - - username - - role - - status - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - account_id: - $ref: "#/components/schemas/AccountId" - user_id: - $ref: "#/components/schemas/UserId" - username: - type: string - role: - $ref: "#/components/schemas/OrganizationMemberRole" - status: - $ref: "#/components/schemas/OrganizationMemberStatus" - biography: - $ref: "#/components/schemas/UserBiography" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - OrganizationMemberRole: - type: string - enum: - - owner - - administrator - - contributor - OrganizationMemberStatus: - type: string - enum: - - active - - waiting_response - - inactive - description: | - * `active` - 組織メンバーとして有効で、組織を閲覧したり、権限があれば編集できます。 - * `waiting_response` - 組織に招待され、まだ加入/脱退を返答していません。組織の一部を閲覧のみできます。 - * `inactive` - 脱退したメンバーを表します。組織を閲覧できません。 - OrganizationPlugin: - type: object - required: - - organization_id - - plugin_id - - created_datetime - - updated_datetime - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - plugin_id: - $ref: "#/components/schemas/PluginId" - plugin_name: - $ref: "#/components/schemas/PluginName" - description: - $ref: "#/components/schemas/PluginDescription" - annotation_editor_url: - $ref: "#/components/schemas/AnnotationEditorUrl" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - PutOrganizationPluginRequest: - type: object - properties: - plugin_name: - $ref: "#/components/schemas/PluginName" - description: - $ref: "#/components/schemas/PluginDescription" - annotation_editor_url: - $ref: "#/components/schemas/AnnotationEditorUrl" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - PluginId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - プラグインID。[値の制約についてはこちら。](#section/API-Convention/APIID) - PluginName: - type: string - example: "foo-bar" - description: | - プラグインの名前です。 - プラグイン一覧や、プロジェクトで使うプラグインを選ぶときなどに表示されます。 - PluginDescription: - type: string - example: "desc" - description: | - プラグインの説明です。 - プラグイン一覧や、プロジェクトで使うプラグインを選ぶときなどに表示されます。 - AnnotationEditorUrl: - type: string - example: "https://example.com/my/editors?p={projectId}&t={taskId}" - description: | - カスタムアノテーションエディタでタスクを開くための URL です。 - プラグインを使用するプロジェクトのタスク一覧などで使用されます。 - - この URL には、タスクを特定するための以下のパラメータを必ず埋め込んでください。 - - * `{projectId}` - * `{taskId}` - - 以下のパラメーターは任意で指定します。 - - * `{inputDataId}`: アノテーション一覧などから、特定の入力データにフォーカスした状態でタスクを開くときなどに指定します。 - * `{annotationId}`: アノテーション一覧などから、特定のアノテーションにフォーカスした状態でタスクを開くときなどに指定します。 - - MyOrganization: - type: object - properties: - organization_id: - $ref: "#/components/schemas/OrganizationId" - name: - type: string - email: - type: string - format: email - price_plan: - $ref: "#/components/schemas/PricePlan" - summary: - $ref: "#/components/schemas/OrganizationSummary" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - my_role: - $ref: "#/components/schemas/OrganizationMemberRole" - my_status: - $ref: "#/components/schemas/OrganizationMemberStatus" - OrganizationRegistrationRequest: - type: object - required: - - organization_name - - organization_email - - price_plan - properties: - organization_name: - $ref: "#/components/schemas/OrganizationName" - organization_email: - type: string - format: email - price_plan: - $ref: "#/components/schemas/PricePlan" - PutOrganizationNameRequest: - type: object - required: - - organization_id - - organization_name - - last_updated_datetime - properties: - organization_id: - type: string - organization_name: - $ref: "#/components/schemas/OrganizationName" - last_updated_datetime: - type: string - format: date-time - PutOrganizationMemberRoleRequest: - type: object - required: - - role - properties: - role: - $ref: "#/components/schemas/OrganizationMemberRole" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - InviteOrganizationMemberRequest: - type: object - properties: - role: - $ref: "#/components/schemas/OrganizationMemberRole" - AccountId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - UserId: - type: string - example: "john_doe" - OrganizationId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - 組織ID。[値の制約についてはこちら。](#section/API-Convention/APIID) - OrganizationName: - type: string - example: "sample-organization" - description: | - 組織名。[値の制約についてはこちら。](#section/API-Convention/APIID) - ProjectId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) - LabelId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - AdditionalDataDefinitionId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - ChoiceId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - PhraseId: - type: string - example: "my_phrase_id" - TaskId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) - InputDataId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) - InputDataSetId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - 入力データセットID。[値の制約についてはこちら。](#section/API-Convention/APIID) - SupplementaryDataId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - TaskHistoryId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - AnnotationId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
- annotation_type が classification の場合は label_id と同じ値が格納されます。 - InspectionId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - 検査ID。[値の制約についてはこちら。](#section/API-Convention/APIID) - MarkerId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - マーカーID。[値の制約についてはこちら。](#section/API-Convention/APIID) - JobId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - WebhookId: - type: string - example: "12345678-abcd-1234-abcd-1234abcd5678" - description: | - WebhookID。[値の制約についてはこちら。](#section/API-Convention/APIID) - Duration: - type: string - example: "PT34H17M36.789S" - UserBiography: - type: string - description: | - 人物紹介、略歴。 - - この属性は、AnnoFab外の所属先や肩書などを表すために用います。 - AnnoFab上の「複数の組織」で活動する場合、本籍を示すのに便利です。 - minLength: 0 - maxLength: 100 - example: "Annotation Manager, ABC Company" - AnnotationFormatVersion: - type: string - example: "1.0.0" - description: | - アノテーションフォーマットのバージョンです。 - アノテーションフォーマットとは、プロジェクト個別のアノテーション仕様ではなく、AnnoFabのアノテーション構造のことです。 - したがって、アノテーション仕様を更新しても、このバージョンは変化しません。 - - バージョンの読み方と更新ルールは、業界慣習の[Semantic Versioning](https://semver.org/)にもとづきます。 - - JSONに出力されるアノテーションフォーマットのバージョンは、アノテーションZIPが作成される時点のものが使われます。 - すなわち、`1.0.0`の時点のタスクで作成したアノテーションであっても、フォーマットが `1.0.1` に上がった次のZIP作成時では `1.0.1` となります。 - バージョンを固定してZIPを残しておきたい場合は、プロジェクトが完了した時点でZIPをダウンロードして保管しておくか、またはプロジェクトを「停止中」にします。 - Project: - type: object - required: - - project_id - - organization_id - - title - - project_status - - input_data_type - - created_datetime - - updated_datetime - - configuration - - summary - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - organization_id: - $ref: "#/components/schemas/OrganizationId" - title: - type: string - description: プロジェクトのタイトル - overview: - type: string - description: プロジェクトの概要 - project_status: - $ref: "#/components/schemas/ProjectStatus" - input_data_type: - $ref: "#/components/schemas/InputDataType" - configuration: - $ref: "#/components/schemas/ProjectConfiguration" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - summary: - $ref: "#/components/schemas/ProjectSummary" - ProjectStatus: - type: string - enum: - - active - - suspended - description: | - プロジェクトの状態 - * `active` - プロジェクトが進行中 - * `suspended` - プロジェクトが停止中 - AssigneeRuleOfResubmittedTask: - type: string - enum: - - no_assignee - - fixed - description: | - 再提出されたタスクの検査/受入担当者の割当方法 - * `no_assignee` - 以前の担当者で固定せず、未割当てにします。 - * `fixed` - 以前の担当者が再度担当します。以前の担当者がいない(1回目の検査/受入)場合は未割当てになります。 - InputDataType: - type: string - description: | - アノテーションする入力データの種類。プロジェクトの作成時のみ指定可能(未指定の場合は `image`)です。更新時は無視されます。 - * `image` - 画像 - * `movie` - 動画 - enum: - - image - - movie - ProjectConfiguration: - type: object - properties: - number_of_inspections: - description: | - 検査回数。 - * 0回:教師付け -> 受入 - * 1回:教師付け -> 検査 -> 受入 - * n回(n >= 2):教師付け -> 検査1 -> ... -> 検査n -> 受入 - type: integer - default: 0 - minimum: 0 - assignee_rule_of_resubmitted_task: - description: 再提出されたタスクの検査/受入担当者ルール。 - $ref: "#/components/schemas/AssigneeRuleOfResubmittedTask" - default: no_assignee - task_assignment_type: - $ref: "#/components/schemas/TaskAssignmentType" - max_tasks_per_member: - description: 保留中のタスクを除き、1人(オーナー以外)に割り当てられるタスク数上限。未指定の場合は10件として扱う。 - type: integer - default: 10 - minimum: 1 - maximum: 100 - max_tasks_per_member_including_hold: - description: 保留中のタスクを含めて、1人(オーナー以外)に割り当てられるタスク数上限。未指定の場合は20件として扱う。 - type: integer - default: 20 - minimum: 1 - maximum: 100 - input_data_set_id_list: - description: このフィールドは内部用でまだ何も意味を成しません。今は空配列を指定してください。 - type: array - items: - $ref: "#/components/schemas/InputDataSetId" - example: "[]" - input_data_max_long_side_length: - description: | - 入力データ画像の長辺の最大値(未指定時は4096px)。 - - 画像をアップロードすると、長辺がこの値になるように画像が自動で圧縮されます。 - アノテーションの座標は、もとの解像度の画像でつけたものに復元されます。 - - 大きな数値を設定すると入力データ画像のサイズが大きくなり、生産性低下やブラウザで画像を表示できない懸念があります。注意して設定してください。 - type: integer - default: 4096 - minimum: 0 - sampling_inspection_rate: - description: 抜取検査率。0-100のパーセント値で指定し、未指定の場合は100%として扱う。 - type: integer - sampling_acceptance_rate: - description: 抜取受入率。0-100のパーセント値で指定し、未指定の場合は100%として扱う。 - type: integer - private_storage_aws_iam_role_arn: - type: string - description: | - AWS IAMロール。ビジネスプランでのS3プライベートストレージの認可で使います。 - [S3プライベートストレージの認可の設定についてはこちら](/docs/faq/#m0b240)をご覧ください。 - example: "arn:aws:iam::123456789012:role/AnnoFabPrivateStorageAccessor" - ProjectSummary: - type: object - properties: - last_tasks_updated_datetime: - type: string - format: date-time - description: タスクの最終更新日時 - TaskAssignmentType: - type: string - default: random - enum: - - random - - selection - - random_and_selection - description: | - プロジェクトで使用するタスクの割当方式。 - - * `random` - タスクフェーズのみを指定してランダムにタスクを自身に割当する方式です。 - * `selection` - 担当者とタスクを明示的に指定してタスクを割当する方式です。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。 - * `random_and_selection` - ランダム割当と選択割当の両機能を使用する方式です。 - JobInfo: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - job_type: - $ref: "#/components/schemas/JobType" - job_id: - $ref: "#/components/schemas/JobId" - job_status: - $ref: "#/components/schemas/JobStatus" - job_execution: - type: object - description: ジョブの内部情報 - job_detail: - type: object - description: ジョブ結果の内部情報 - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - JobType: - type: string - enum: - - copy-project - - gen-inputs - - gen-tasks - - gen-annotation - - gen-tasks-list - - gen-inputs-list - - delete-project - - invoke-hook - description: | - * `copy-project` - プロジェクトのコピー。[initiateProjectCopy](#operation/initiateProjectCopy) APIを実行したときに登録されるジョブ。 - * `gen-inputs` - zipファイルから入力データの作成。[putInputData](#operation/putInputData) APIを実行して、zipファイルから入力データを作成したときに登録されるジョブ。 - * `gen-tasks` - タスクの一括作成。[initiateTasksGeneration](#operation/initiateTasksGeneration) APIを実行したときに登録されるジョブ。 - * `gen-annotation` - アノテーションZIPの更新。[postAnnotationArchiveUpdate](#operation/postAnnotationArchiveUpdate) APIを実行したときに登録されるジョブ。 - * `gen-tasks-list` - タスク全件ファイルの更新。[postProjectTasksUpdate](#operation/postProjectTasksUpdate) APIを実行したときに登録されるジョブ。 - * `gen-inputs-list` - 入力データ情報全件ファイルの更新。[postProjectInputsUpdate](#operation/postProjectInputsUpdate) APIを実行したときに登録されるジョブ。 - * `delete-project` - プロジェクトの削除。[deleteProject](#operation/deleteProject) APIを実行したときに登録されるジョブ。 - * `invoke-hook` - Webhookの起動。 - JobStatus: - type: string - enum: - - progress - - succeeded - - failed - PostAnnotationArchiveUpdateResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - PostProjectTasksUpdateResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - ProjectCopyResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - dest_project: - $ref: "#/components/schemas/Project" - DeleteProjectResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - project: - $ref: "#/components/schemas/Project" - TaskGenerateResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - project: - $ref: "#/components/schemas/Project" - ProjectInputsUpdateResponse: - type: object - properties: - job: - $ref: "#/components/schemas/JobInfo" - Webhook: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - event_type: - $ref: "#/components/schemas/WebhookEventType" - webhook_id: - $ref: "#/components/schemas/WebhookId" - webhook_status: - $ref: "#/components/schemas/WebhookStatus" - method: - $ref: "#/components/schemas/WebhookHttpMethod" - headers: - type: array - items: - $ref: "#/components/schemas/WebhookHeader" - body: - type: string - example: '{\"message\": \"{{PROJECT_ID}} is updated at {{COMPLETE_DATETIME}}\"}' - url: - type: string - format: uri - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - WebhookHeader: - type: object - properties: - name: - type: string - value: - type: string - WebhookStatus: - type: string - enum: - - active - - inactive - WebhookHttpMethod: - type: string - enum: - - POST - - PUT - - DELETE - - PATCH - - GET - - HEAD - WebhookEventType: - type: string - enum: - - task-completed - - annotation-archive-updated - - input-data-zip-registered - - project-copy-completed - description: | - * `task-completed` - タスク受入完了 - * `annotation-archive-updated` - アノテーションZIP作成完了 - * `input-data-zip-registered` - 入力データZIP登録完了 - * `project-copy-completed` - プロジェクトコピー完了 - PutProjectRequest: - type: object - required: - - title - - status - - organization_name - - configuration - properties: - title: - type: string - description: プロジェクトのタイトル - overview: - type: string - description: プロジェクトの概要 - status: - $ref: "#/components/schemas/ProjectStatus" - input_data_type: - $ref: "#/components/schemas/InputDataType" - organization_name: - type: string - description: | - プロジェクトの所属組織を変更する場合は、ここに変更先の組織名を指定します。 - - * 所属組織を変更する前にプロジェクトを停止する必要があります。 - * APIを呼び出すアカウントは、変更先組織の管理者またはオーナーである必要があります。 - * 変更後の組織に所属していないプロジェクトメンバーも残りますが、作業はできません。あらためて組織に招待してください。 - configuration: - $ref: "#/components/schemas/ProjectConfiguration" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - force_suspend: - type: boolean - description: 作業中タスクがあるプロジェクトを停止する時trueにして下さい - default: false - ProjectCopyRequest: - type: object - required: - - dest_project_id - - dest_title - properties: - dest_project_id: - $ref: "#/components/schemas/ProjectId" - dest_title: - type: string - description: コピー先プロジェクトのタイトル - dest_overview: - type: string - description: コピー先プロジェクトの概要 - copy_inputs: - type: boolean - description: | - 「入力データ」をコピーするかどうかを指定します。 - default: false - copy_tasks: - type: boolean - description: | - 「タスク」をコピーするかどうかを指定します。 - - この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 - - * copy_inputs の値を true とする - default: false - copy_annotations: - type: boolean - description: | - 「アノテーション」をコピーするかどうかを指定します。 - - この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 - - * copy_inputs の値を true とする - * copy_tasks の値を true とする - default: false - copy_webhooks: - type: boolean - description: | - 「Webhook」をコピーするかどうかを指定します。 - default: false - copy_supplementaly_data: - type: boolean - description: | - 「補助情報」をコピーするかどうかを指定します。 - - この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 - - * copy_inputs の値を true とする - default: false - copy_instructions: - type: boolean - description: | - 「作業ガイド」をコピーするかどうかを指定します。 - default: false - ProjectMember: - type: object - required: - - project_id - - account_id - - user_id - - username - - member_status - - member_role - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - account_id: - $ref: "#/components/schemas/AccountId" - user_id: - $ref: "#/components/schemas/UserId" - username: - type: string - member_status: - $ref: "#/components/schemas/ProjectMemberStatus" - member_role: - $ref: "#/components/schemas/ProjectMemberRole" - biography: - $ref: "#/components/schemas/UserBiography" - updated_datetime: - type: string - format: date-time - created_datetime: - type: string - format: date-time - sampling_inspection_rate: - description: メンバー固有の抜取検査率(0-100のパーセント値)。 - type: integer - sampling_acceptance_rate: - description: メンバー固有の抜取受入率(0-100のパーセント値)。 - type: integer - ProjectMemberStatus: - type: string - enum: - - active - - inactive - description: | - * `active` - プロジェクトメンバーとして有効で、プロジェクトを閲覧したり、権限があれば編集できます。 - * `inactive` - 脱退したプロジェクトメンバーを表します。プロジェクトを閲覧できません。 - ProjectMemberRole: - type: string - enum: - - owner - - worker - - accepter - - training_data_user - ProjectMemberRequest: - type: object - properties: - member_status: - $ref: "#/components/schemas/ProjectMemberStatus" - member_role: - $ref: "#/components/schemas/ProjectMemberRole" - sampling_inspection_rate: - description: メンバー固有の抜取検査率。0-100のパーセント値で指定する。値が指定された場合、プロジェクトの抜取検査率を指定の値で上書きする。 - type: integer - sampling_acceptance_rate: - description: メンバー固有の抜取受入率。0-100のパーセント値で指定する。値が指定された場合、プロジェクトの抜取受入率を指定の値で上書きする。 - type: integer - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - ProjectTaskStatisticsHistory: - type: object - properties: - date: - type: string - format: date - tasks: - type: array - items: - $ref: "#/components/schemas/ProjectTaskStatistics" - ProjectTaskStatistics: - type: object - required: - - phase - - status - - count - - work_timespan - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - status: - $ref: "#/components/schemas/TaskStatus" - count: - type: integer - minimum: 0 - description: タスク数 - work_timespan: - type: integer - description: 累計実作業時間(ミリ秒) - ProjectAccountStatistics: - type: object - required: - - account_id - - histories - properties: - account_id: - $ref: "#/components/schemas/AccountId" - histories: - type: array - items: - $ref: "#/components/schemas/ProjectAccountStatisticsHistory" - ProjectAccountStatisticsHistory: - type: object - required: - - date - - tasks_completed - - tasks_rejected - - worktime - properties: - date: - type: string - format: date - tasks_completed: - type: integer - description: 教師付を担当したタスクが完了状態になった回数 - tasks_rejected: - type: integer - description: 教師付を担当したタスクが差し戻された回数 - worktime: - type: string - example: "PT34H17M36.789S" - description: 作業時間(ISO 8601 duration) - InspectionStatistics: - type: object - required: - - project_id - - date - - breakdown - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - date: - description: 集計日 - type: string - format: date - breakdown: - $ref: "#/components/schemas/InspectionStatisticsBreakdown" - InspectionStatisticsBreakdown: - type: object - description: 検査コメント数の集計結果 - required: - - labels - - no_label - properties: - labels: - description: ラベルごとの指摘集計結果。キーは`label_id` - type: object - additionalProperties: { - $ref: "#/components/schemas/InspectionStatisticsPhrases" - } - no_label: - $ref: "#/components/schemas/InspectionStatisticsPhrases" - InspectionStatisticsPhrases: - type: object - description: ラベル外指摘の集計結果 - required: - - phrases - - no_phrase - properties: - phrases: - description: 定型指摘ごとの合計数。キーは定型指摘ID、値は指摘数 - type: object - additionalProperties: { - type: integer - } - no_phrase: - description: 非定型指摘の合計数 - type: integer - TaskPhaseStatistics: - type: object - required: - - project_id - - date - - phases - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - date: - type: string - format: date - phases: - description: タスクのフェーズごとの集計結果 - type: array - items: - $ref: "#/components/schemas/PhaseStatistics" - PhaseStatistics: - type: object - required: - - phase - - worktime - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - worktime: - description: 累積作業時間(ISO 8601 duration) - type: string - example: "PT34H17M36.789S" - LabelStatistics: - type: object - required: - - label_id - - completed - - wip - properties: - label_id: - $ref: "#/components/schemas/LabelId" - completed: - type: integer - minimum: 0 - description: ラベルごとの受入が完了したアノテーション数 - wip: - type: integer - minimum: 0 - description: ラベルごとの受入が完了していないアノテーション数 - WorktimeStatistics: - type: object - required: - - project_id - - date - - by_tasks - - by_inputs - - by_minutes - - accounts - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - date: - type: string - format: date - by_tasks: - type: array - description: タスク1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - by_inputs: - type: array - description: 画像1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - by_minutes: - type: array - description: 動画1分当たりの作業時間情報(画像プロジェクトの場合は空リスト) - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - accounts: - type: array - description: ユーザごとの作業時間情報 - items: - $ref: "#/components/schemas/AccountWorktimeStatistics" - WorktimeStatisticsItem: - type: object - required: - - phase - - histogram - - average - - standard_deviation - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - histogram: - type: array - items: - $ref: "#/components/schemas/HistogramItem" - average: - description: 作業時間の平均(ISO 8601 duration) - type: string - example: "PT34H17M36.789S" - standard_deviation: - description: 作業時間の標準偏差(ISO 8601 duration) - type: string - example: "PT34H17M36.789S" - HistogramItem: - type: object - required: - - begin - - end - - count - properties: - begin: - type: number - end: - type: number - count: - type: integer - AccountWorktimeStatistics: - type: object - required: - - account_id - - by_tasks - - by_inputs - - by_minutes - properties: - account_id: - $ref: "#/components/schemas/AccountId" - by_tasks: - description: ユーザごとのタスク1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) - type: array - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - by_inputs: - description: ユーザごとの画像1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) - type: array - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - by_minutes: - description: ユーザごとの動画1分当たりの作業時間情報(画像プロジェクトの場合は空リスト) - type: array - items: - $ref: "#/components/schemas/WorktimeStatisticsItem" - Marker: - type: object - properties: - marker_id: - $ref: "#/components/schemas/MarkerId" - title: - type: string - graph_type: - description: マーカーの配置先グラフ - $ref: "#/components/schemas/GraphType" - marked_at: - description: グラフ上のマーカー位置(x軸) - type: string - format: date - Markers: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - markers: - type: array - items: - $ref: "#/components/schemas/Marker" - updated_datetime: - type: string - format: date - GraphType: - type: string - enum: - - task_progress - - cumulative_labor_time_By_task_phase - - number_of_inspections_per_inspection_phrase - - number_of_task_rejections_by_member - - labor_time_per_member - - mean_labor_time_per_image - - mean_labor_time_per_minute_of_movie - - mean_labor_time_per_image_by_member - - mean_labor_time_per_minute_of_movie_by_member - description: | - * `task_progress` - タスク進捗状況 - * `cumulative_labor_time_by_task_phase` - タスクフェーズ別累積作業時間 - * `number_of_inspections_per_inspection_phrase` - 検査コメント内容別指摘回数 - * `number_of_task_rejections_by_member` - メンバー別タスクが差戻された回数 - * `labor_time_per_member` - メンバー別作業時間 - * `mean_labor_time_per_image` - 画像一枚当たりの作業時間平均 - * `mean_labor_time_per_minute_of_movie` - 動画一分当たりの作業時間平均 - * `mean_labor_time_per_image_by_member` - メンバー別画像一枚当たりの作業時間平均 - * `mean_labor_time_per_minute_of_movie_by_member` - メンバー別動画一分当たりの作業時間平均 - PutMarkersRequest: - type: object - properties: - markers: - type: array - items: - $ref: "#/components/schemas/Marker" - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - AnnotationSpecsV1: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - labels: - type: array - items: - $ref: "#/components/schemas/LabelV1" - inspection_phrases: - type: array - items: - $ref: "#/components/schemas/InspectionPhrase" - updated_datetime: - type: string - format: date-time - description: | - アノテーション仕様の最終更新時刻 - AnnotationSpecsV2: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - labels: - type: array - items: - $ref: "#/components/schemas/LabelV2" - additionals: - type: array - items: - $ref: "#/components/schemas/AdditionalDataDefinitionV2" - restrictions: - type: array - items: - $ref: "#/components/schemas/AdditionalDataRestriction" - inspection_phrases: - type: array - items: - $ref: "#/components/schemas/InspectionPhrase" - format_version: - type: string - default: "2.1.0" - updated_datetime: - type: string - format: date-time - description: | - アノテーション仕様の最終更新時刻 - AnnotationSpecsRequestV1: - type: object - required: - - labels - - inspection_phrases - - comment - - auto_marking - properties: - labels: - type: array - items: - $ref: "#/components/schemas/LabelV1" - inspection_phrases: - type: array - items: - $ref: "#/components/schemas/InspectionPhrase" - comment: - type: string - auto_marking: - type: boolean - default: false - description: | - trueが指定された場合、各統計グラフにマーカーを自動追加します。 - マーカーのタイトルには `comment` に指定された文字列が設定されます。 - `comment` が指定されていなかった場合は "アノテーション仕様の変更" という文字列が設定されます。 - last_updated_datetime: - allOf: - - $ref: "#/components/schemas/LastUpdatedDatetime" - description: | - 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 - 新規作成時は未指定。 - AnnotationSpecsRequestV2: - type: object - required: - - labels - - additionals - - restrictions - - inspection_phrases - - comment - - auto_marking - - format_version - properties: - labels: - type: array - items: - $ref: "#/components/schemas/LabelV2" - additionals: - type: array - items: - $ref: "#/components/schemas/AdditionalDataDefinitionV2" - restrictions: - type: array - items: - $ref: "#/components/schemas/AdditionalDataRestriction" - inspection_phrases: - type: array - items: - $ref: "#/components/schemas/InspectionPhrase" - comment: - type: string - auto_marking: - type: boolean - default: false - description: | - trueが指定された場合、各統計グラフにマーカーを自動追加します。 - マーカーのタイトルには `comment` に指定された文字列が設定されます。 - `comment` が指定されていなかった場合は "アノテーション仕様の変更" という文字列が設定されます。 - format_version: - type: string - default: "2.1.0" - last_updated_datetime: - allOf: - - $ref: "#/components/schemas/LastUpdatedDatetime" - description: | - 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 - 新規作成時は未指定。 - AnnotationSpecsHistory: - type: object - properties: - history_id: - type: string - project_id: - $ref: "#/components/schemas/ProjectId" - updated_datetime: - type: string - format: date-time - url: - type: string - account_id: - $ref: "#/components/schemas/AccountId" - comment: - type: string - InspectionPhrase: - type: object - properties: - id: - type: string - text: - $ref: "#/components/schemas/InternationalizationMessage" - AnnotationType: - type: string - enum: - - bounding_box - - segmentation - - segmentation_v2 - - polygon - - polyline - - point - - classification - - range - description: | - * `bounding_box` - 矩形を表します。 - * `segmentation` - ピクセルレベルでの塗りつぶし(ラスター)を表します。 - * `segmentation_v2` - 塗りつぶしv2を表します。v2はSemantic Segmentationに特化しています。 - * `polygon` - ポリゴン(閉じた頂点集合)を表します。 - * `polyline` - ポリライン(開いた頂点集合)を表します。 - * `point` - 点を表します。 - * `classification` - 入力データ全体に対するアノテーションを表します。 - * `range` - 動画の区間を表します。 - AdditionalDataDefinitionType: - type: string - enum: - - flag - - integer - - text - - comment - - choice - - select - - tracking - - link - description: | - * `flag` - 真偽値 - * `integer` - 整数値 - * `text` - 自由記述(1行) - * `comment` - 自由記述(複数行) - * `choice` - 選択肢(ラジオボタン式) - * `select` - 選択肢(ドロップダウン式) - * `tracking` - 自由記述 (トラッキングID自動挿入) - * `link` - アノテーションリンク - PositionForMinimumBoundingBoxInsertion: - type: object - description: | - `annotation_type` が `bounding_box` かつ `min_warn_rule` が `and` または `or` の場合のみ、挿入する最小矩形アノテーションの原点を指定できます。 - 画像左上の座標が「x=0, y=0」です。 - 未指定、もしくは「画像外に飛び出たアノテーション」を許可していないにも関わらず飛び出してしまう場合は、表示範囲の中央に挿入されます。 - 「スキャンした帳票の記入欄」や「定点カメラで撮影した製品ラベル」など、アノテーションしたい位置やサイズが多くの画像で共通している場合に便利です。 - - `annotation_type` が `bounding_box` 以外の場合は必ず未指定となります。 - required: - - x - - y - properties: - x: - type: integer - y: - type: integer - LabelV1: - type: object - properties: - label_id: - $ref: "#/components/schemas/LabelId" - label_name: - $ref: "#/components/schemas/InternationalizationMessage" - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - annotation_type: - $ref: "#/components/schemas/AnnotationType" - bounding_box_metadata: - type: object - properties: - min_width: - type: integer - min_height: - type: integer - min_warn_rule: - type: string - default: or - min_area: - type: integer - minimum: 1 - maximum: 1000000 - max_vertices: - type: integer - min_vertices: - type: integer - position_for_minimum_bounding_box_insertion: - $ref: "#/components/schemas/PositionForMinimumBoundingBoxInsertion" - tolerance: - type: integer - segmentation_metadata: - type: object - properties: - min_width: - type: integer - min_height: - type: integer - min_warn_rule: - type: string - default: or - tolerance: - type: integer - additional_data_definitions: - type: array - items: - $ref: "#/components/schemas/AdditionalDataDefinitionV1" - color: - $ref: "#/components/schemas/Color" - annotation_editor_feature: - $ref: "#/components/schemas/AnnotationEditorFeature" - allow_out_of_image_bounds: - type: boolean - default: false - LabelV2: - type: object - properties: - label_id: - $ref: "#/components/schemas/LabelId" - label_name: - $ref: "#/components/schemas/InternationalizationMessage" - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - annotation_type: - $ref: "#/components/schemas/AnnotationType" - bounding_box_metadata: - type: object - properties: - min_width: - type: integer - min_height: - type: integer - min_warn_rule: - type: string - default: or - min_area: - type: integer - minimum: 1 - maximum: 1000000 - max_vertices: - type: integer - min_vertices: - type: integer - position_for_minimum_bounding_box_insertion: - $ref: "#/components/schemas/PositionForMinimumBoundingBoxInsertion" - tolerance: - type: integer - segmentation_metadata: - type: object - properties: - min_width: - type: integer - min_height: - type: integer - min_warn_rule: - type: string - default: or - tolerance: - type: integer - additional_data_definitions: - type: array - items: - $ref: "#/components/schemas/AdditionalDataDefinitionId" - color: - $ref: "#/components/schemas/Color" - annotation_editor_feature: - $ref: "#/components/schemas/AnnotationEditorFeature" - allow_out_of_image_bounds: - type: boolean - default: false - Color: - type: object - properties: - red: - type: integer - minimum: 0 - maximum: 255 - green: - type: integer - minimum: 0 - maximum: 255 - blue: - type: integer - minimum: 0 - maximum: 255 - AnnotationEditorFeature: - type: object - properties: - append: - type: boolean - erase: - type: boolean - freehand: - type: boolean - rectangle_fill: - type: boolean - polygon_fill: - type: boolean - fill_near: - type: boolean - AdditionalDataDefinitionV1: - type: object - properties: - additional_data_definition_id: - $ref: "#/components/schemas/AdditionalDataDefinitionId" - read_only: - type: boolean - default: false - name: - $ref: "#/components/schemas/InternationalizationMessage" - default: - oneOf: - - type: boolean - - type: integer - - type: string - description: | - 属性の初期値です。 - - 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 - - * type が flag の場合: 真偽値(`true` or `false`) - * type が integer の場合: 整数値 - * type が text の場合: 文字列 - * type が comment の場合: 文字列 - * type が choice の場合: 選択肢(`choices`)の `choice_id` - * type が select の場合: 選択肢(`choices`)の `choice_id` - - 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 - - なお、トラッキングとリンクには初期値を設定できません。 - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - type: - $ref: "#/components/schemas/AdditionalDataDefinitionType" - choices: - type: array - items: - type: object - properties: - choice_id: - $ref: "#/components/schemas/ChoiceId" - name: - $ref: "#/components/schemas/InternationalizationMessage" - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - regex: - type: string - label_ids: - type: array - description: リンク属性において、リンク先として指定可能なラベルID(空の場合制限なし) - items: - type: string - required: - type: boolean - description: リンク属性において、入力を必須とするかどうか - AdditionalDataDefinitionV2: - type: object - properties: - additional_data_definition_id: - $ref: "#/components/schemas/AdditionalDataDefinitionId" - read_only: - type: boolean - default: false - name: - $ref: "#/components/schemas/InternationalizationMessage" - default: - oneOf: - - type: boolean - - type: integer - - type: string - description: | - 属性の初期値です。 - - 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 - - * type が flag の場合: 真偽値(`true` or `false`) - * type が integer の場合: 整数値 - * type が text の場合: 文字列 - * type が comment の場合: 文字列 - * type が choice の場合: 選択肢(`choices`)の `choice_id` - * type が select の場合: 選択肢(`choices`)の `choice_id` - - 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 - - なお、トラッキングとリンクには初期値を設定できません。 - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - type: - $ref: "#/components/schemas/AdditionalDataDefinitionType" - choices: - type: array - items: - type: object - properties: - choice_id: - $ref: "#/components/schemas/ChoiceId" - name: - $ref: "#/components/schemas/InternationalizationMessage" - keybind: - type: array - items: - $ref: "#/components/schemas/Keybind" - AdditionalDataRestriction: - type: object - properties: - additional_data_definition_id: - $ref: "#/components/schemas/AdditionalDataDefinitionId" - condition: - $ref: "#/components/schemas/AdditionalDataRestrictionCondition" - AdditionalDataRestrictionCondition: - oneOf: - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionCanInput" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionEquals" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionNotEquals" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionMatches" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionNotMatches" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionHasLabel" - - $ref: "#/components/schemas/AdditionalDataRestrictionConditionImply" - AdditionalDataRestrictionConditionCanInput: - type: object - description: | - enable=false とすることで、入力を許可しないようにできます。 - Imply との組み合わせで、特定条件下のみ入力を許すといった制限ができます。 - properties: - _type: - type: string - example: "CanInput" - enable: - type: boolean - AdditionalDataRestrictionConditionEquals: - type: object - description: 指定された値と等しいことを要求します。 - properties: - _type: - type: string - example: "Equals" - value: - type: string - AdditionalDataRestrictionConditionNotEquals: - type: object - description: | - 指定された値と異なることを要求します。 - value に "" を指定することで、入力を必須とすることができます。 - properties: - _type: - type: string - example: "NotEquals" - value: - type: string - AdditionalDataRestrictionConditionMatches: - type: object - description: 指定された正規表現に合致することを要求します。 - properties: - _type: - type: string - example: "Matches" - value: - type: string - AdditionalDataRestrictionConditionNotMatches: - type: object - description: 指定された正規表現に合致しないことを要求します。 - properties: - _type: - type: string - example: "NotMatches" - value: - type: string - AdditionalDataRestrictionConditionHasLabel: - type: object - description: リンク属性において、リンク先として指定可能なラベルIDを制限します。 - properties: - _type: - type: string - example: "HasLabel" - values: - type: string - AdditionalDataRestrictionConditionImply: - type: object - description: | - premise で指定された条件を満たすとき、condition で指定された条件を満たすことを要求します。 - properties: - premise: - $ref: "#/components/schemas/AdditionalDataRestriction" - condition: - $ref: "#/components/schemas/AdditionalDataRestrictionCondition" - Keybind: - type: object - properties: - code: - type: string - shift: - type: boolean - ctrl: - type: boolean - alt: - type: boolean - Task: - type: object - required: - - project_id - - task_id - - phase - - phase_stage - - status - - input_data_id_list - - work_time_span - - updated_datetime - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - phase: - $ref: "#/components/schemas/TaskPhase" - phase_stage: - $ref: "#/components/schemas/TaskPhaseStage" - status: - $ref: "#/components/schemas/TaskStatus" - input_data_id_list: - type: array - description: タスクに含まれる入力データのID - items: - $ref: "#/components/schemas/InputDataId" - account_id: - $ref: "#/components/schemas/AccountId" - histories_by_phase: - type: array - description: 簡易的なタスク履歴(あるフェーズを誰が担当したか) - items: - $ref: "#/components/schemas/TaskHistoryShort" - work_time_span: - type: integer - description: 累計実作業時間(ミリ秒) - number_of_rejections: - type: integer - deprecated: true - description: | - このタスクが差戻しされた回数(すべてのフェーズでの差戻し回数の合計 - - このフィールドは、どのフェーズで何回差戻されたかを区別できないため、廃止予定です。 - `histories_by_phase` で各フェーズの回数を計算することで、差戻し回数が分かります。 - - 例)`acceptance`フェーズが3回ある場合、`acceptance`フェーズで2回差し戻しされたことになります。 - started_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - sampling: - type: string - enum: - - inspection_skipped - - inspection_stages_skipped - - acceptance_skipped - - inspection_and_acceptance_skipped - description: | - * `inspection_skipped` - このタスクが抜取検査の対象外となり、検査フェーズをスキップしたことを表す。 - * `inspection_stages_skipped` - このタスクが抜取検査の対象外となり、検査フェーズのステージを一部スキップしたことを表す。 - * `acceptance_skipped` - このタスクが抜取検査の対象外となり、受入フェーズをスキップしたことを表す。 - * `inspection_and_acceptance_skipped` - このタスクが抜取検査の対象外となり、検査・受入フェーズをスキップしたことを表す - - 未指定時はこのタスクが抜取検査の対象となったことを表す。(通常のワークフローを通過する) - TaskPhase: - type: string - enum: - - annotation - - inspection - - acceptance - description: | - * `annotation` - 教師付け。 - * `inspection` - 中間検査。ワークフローが3フェーズのときのみ。 - * `acceptance` - 受入。 - TaskPhaseStage: - type: integer - minimum: 1 - TaskStatus: - type: string - enum: - - not_started - - working - - on_hold - - break - - complete - - rejected - - cancelled - description: | - * `not_started` - 未着手。 - * `working` - 作業中。誰かが実際にエディタ上で作業している状態。 - * `on_hold` - 保留。作業ルールの確認などで作業できない状態。 - * `break` - 休憩中。 - * `complete` - 完了。次のフェーズへ進む - * `rejected` - 差戻し。修正のため、`annotation`フェーズへ戻る。[operateTask](#operation/operateTask) APIのリクエストボディに渡すときのみ利用する。その他のAPIのリクエストやレスポンスには使われない。 - * `cancelled` - 提出取消し。修正のため、前フェーズへ戻る。[operateTask](#operation/operateTask) APIのリクエストボディに渡すときのみ利用する。その他のAPIのリクエストやレスポンスには使われない。 - TaskRequest: - type: object - required: - - input_data_id_list - properties: - input_data_id_list: - type: array - items: - $ref: "#/components/schemas/InputDataId" - TaskGenerateRequest: - type: object - required: - - task_generate_rule - - project_last_updated_datetime - properties: - task_generate_rule: - description: | - * `TaskGenerateRuleByCount`: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 - * `TaskGenerateRuleByDirectory`: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。 - * `TaskGenerateRuleByInputDataCsv`: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 - oneOf: - - $ref: "#/components/schemas/TaskGenerateRuleByCount" - - $ref: "#/components/schemas/TaskGenerateRuleByDirectory" - - $ref: "#/components/schemas/TaskGenerateRuleByInputDataCsv" - project_last_updated_datetime: - type: string - format: date-time - description: プロジェクトの最終更新日時([getProject](#operation/getProject) APIのレスポンス `updated_datetime`)。タスク生成の排他制御に使用。 - TaskGenerateRuleByCount: - description: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 - type: object - required: - - task_id_prefix - - allow_duplicate_input_data - - input_data_count - - input_data_order - properties: - task_id_prefix: - type: string - description: | - 生成するタスクIDのプレフィックス。[値の制約についてはこちら。](#section/API-Convention/APIID) - allow_duplicate_input_data: - type: boolean - description: falseのときは、既にタスクに使われている入力データを除外し、まだタスクに使われていない入力データだけを新しいタスクに割り当てます。trueのときは、既にタスクに使われている入力データを除外しません。 - input_data_count: - type: integer - description: 1つのタスクに割り当てる入力データの個数 - example: 10 - input_data_order: - $ref: "#/components/schemas/InputDataOrder" - _type: - type: string - description: | - `ByCount` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "ByCount" - TaskGenerateRuleByDirectory: - description: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。
- type: object - required: - - task_id_prefix - properties: - task_id_prefix: - type: string - description: | - 生成するタスクIDのプレフィックス。[値の制約についてはこちら。](#section/API-Convention/APIID) - input_data_name_prefix: - type: string - description: タスク生成対象の入力データ名プレフィックス - _type: - type: string - description: | - `ByDirectory` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "ByDirectory" - TaskGenerateRuleByInputDataCsv: - description: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 - type: object - required: - - csv_data_path - properties: - csv_data_path: - type: string - description: 各タスクへの入力データへの割当を記入したCSVへのS3上のパス - example: "s3://ANNOFAB-BUCKET/PATH/TO/CSV" - _type: - type: string - description: | - `ByInputDataCsv` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "ByInputDataCsv" - InputDataOrder: - type: string - enum: - - name_asc - - name_desc - - random - description: | - タスクに割り当てる入力データの順序 - - * `name_asc` - 入力データ名 昇順(a, b, c, ...)。日付や番号などの連続するデータ名を扱う場合に推奨 - * `name_desc` - 入力データ名 降順(z, y, x, ...) - * `random` - ランダム - TaskOperation: - type: object - required: - - status - - last_updated_datetime - properties: - status: - description: | - 次に遷移させるタスクの状態。[詳細はこちら](#section/TaskStatus)。 - allOf: - - $ref: "#/components/schemas/TaskStatus" - last_updated_datetime: - allOf: - - $ref: "#/components/schemas/LastUpdatedDatetime" - description: | - タスクの最終更新日時 - account_id: - allOf: - - $ref: "#/components/schemas/AccountId" - description: 変更後の担当者のアカウントID。担当者を未割り当てにする場合は未指定。 - force: - type: boolean - default: false - description: | - タスクの強制操作を行う場合に立てるフラグ。現在、強制操作は強制差戻しのみがサポートされています。 - TaskStart: - type: object - properties: - phase: - allOf: - - $ref: "#/components/schemas/TaskPhase" - - description: 開始するタスクのフェーズ - TaskAssignRequest: - type: object - required: - - request_type - properties: - request_type: - description: | - * `TaskAssignRequestTypeRandom`: タスクフェーズのみを指定してランダムにタスクを自身に割当します。プロジェクト設定でタスクのランダム割当を有効にした場合のみ利用できます。 - * `TaskAssignRequestTypeSelection`: 担当者とタスクを明示的に指定してタスクを割当します。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。プロジェクト設定でタスクの選択割当を有効にした場合のみ利用できます。 - oneOf: - - $ref: "#/components/schemas/TaskAssignRequestTypeRandom" - - $ref: "#/components/schemas/TaskAssignRequestTypeSelection" - TaskAssignRequestTypeRandom: - type: object - required: - - phase - properties: - phase: - description: 割当するタスクフェーズ。[詳細はこちら](#section/TaskPhase) - allOf: - - $ref: "#/components/schemas/TaskPhase" - _type: - type: string - description: Random - example: "Random" - TaskAssignRequestTypeSelection: - type: object - required: - - user_id - - task_ids - properties: - user_id: - description: タスクを誰に割当するか - allOf: - - $ref: "#/components/schemas/UserId" - task_ids: - description: 割当するタスクのID - type: array - items: - $ref: "#/components/schemas/TaskId" - _type: - type: string - description: Selection - example: "Selection" - TaskHistoryShort: - description: タスクのあるフェーズを誰が担当したかを表します。 - type: object - required: - - phase - - phase_stage - - account_id - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - phase_stage: - type: integer - default: 1 - minimum: 1 - account_id: - $ref: "#/components/schemas/AccountId" - worked: - type: boolean - description: そのフェーズでタスクの作業を行ったかどうか(行った場合はtrue) - default: false - TaskHistory: - description: タスクのあるフェーズで、誰がいつどれくらいの作業時間を費やしたかを表すタスク履歴です。 - type: object - required: - - project_id - - task_id - - task_history_id - - accumulated_labor_time_milliseconds - - phase - - phase_stage - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - task_history_id: - $ref: "#/components/schemas/TaskHistoryId" - started_datetime: - type: string - format: date-time - ended_datetime: - type: string - format: date-time - accumulated_labor_time_milliseconds: - type: string - description: 累計実作業時間(ISO 8601 duration) - example: "PT34H17M36.789S" - phase: - $ref: "#/components/schemas/TaskPhase" - phase_stage: - type: integer - minimum: 1 - account_id: - $ref: "#/components/schemas/AccountId" - TaskHistoryEvent: - description: タスク履歴イベントは、タスクの状態が変化した1時点を表します。作業時間は、複数のこれらイベントを集約して計算するものなので、このオブジェクトには含まれません。 - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - task_history_id: - $ref: "#/components/schemas/TaskHistoryId" - created_datetime: - type: string - format: date-time - phase: - $ref: "#/components/schemas/TaskPhase" - phase_stage: - type: integer - default: 1 - minimum: 1 - status: - $ref: "#/components/schemas/TaskStatus" - account_id: - $ref: "#/components/schemas/AccountId" - request: - $ref: "#/components/schemas/TaskOperation" - TaskValidation: - description: タスクの全入力データに対するバリデーション結果です。 - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - inputs: - type: array - items: - $ref: "#/components/schemas/InputDataSummary" - InputDataSummary: - description: ある入力データのバリデーション結果です。入力データIDをキーに引けるようにMap[入力データID, バリデーション結果]となっています - type: object - properties: - input_data_id: - $ref: "#/components/schemas/InputDataId" - inspection_summary: - $ref: "#/components/schemas/InspectionSummary" - annotation_summaries: - type: array - items: - $ref: "#/components/schemas/ValidationError" - InspectionSummary: - type: string - enum: - - no_inspection - - no_comment_inspection - - new_reply_to_unprocessed - - new_unprocessed_inspection - - unprocessed - - complete - description: | - - `no_inspection` - 入力データに検査コメントが付けられていない。 - - `no_comment_inspection` - 入力データに空の検査コメントが付けられている。 - - `new_reply_to_unprocessed` - 現在進行中の検査・受入フェーズで未処理の検査コメントに対して新たに返信が付けられている。 - - `new_unprocessed_inspection` - 現在進行中の検査・受入フェーズでつけられた検査コメントのうち、未処理のものが1つ以上ある。 - - `unprocessed` - 過去の検査・受入フェーズでつけられた検査コメントのうち、未処理のものが1つ以上ある。 - - `complete` - 入力データにつけられた検査コメントで未処理のものがない。 - InputData: - description: 入力データの情報を表すデータ構造です。 - type: object - required: - - input_data_id - - project_id - - input_data_name - - input_data_path - - updated_datetime - properties: - input_data_id: - $ref: "#/components/schemas/InputDataId" - project_id: - $ref: "#/components/schemas/ProjectId" - input_data_name: - type: string - description: 表示用の名前です。 - input_data_path: - type: string - example: "s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA" - description: | - 入力データの実体が保存されたパスです。 - s3スキーマまたはhttpsスキーマのみサポートしています。 - url: - type: string - description: | - 入力データを取得するためのhttpsスキーマのURLです。 - - このURLはセキュリティのために認証認可が必要となっており、URLだけでは入力データを参照できません。 - このURLは内部用であり、常に変更になる可能性があります。そのため、アクセスは保証外となります。 - また、このURLのレスポンスは最低1時間キャッシュされます。 - キャッシュを無効にしたい場合は、クエリパラメータにアクセス毎にランダムなUUIDなどを付与してください。 - - 設定の不備等でデータが取得できない場合、この属性は設定されません。 - etag: - type: string - original_input_data_path: - type: string - example: "s3://YOUR-BUCKET/PATH/TO/INPUT_DATA" - description: | - AF外部のストレージから登録された場合、その外部ストレージ中のパス。 - それ以外の場合は値なし - original_resolution: - allOf: - - $ref: "#/components/schemas/Resolution" - - description: | - 入力データの元画像サイズ。 - 入力データ登録時に画像がリサイズされた場合のみ設定される。 - resized_resolution: - allOf: - - $ref: "#/components/schemas/Resolution" - - description: | - 入力データのリサイズ後サイズ。 - 入力データ登録時に画像がリサイズされた場合のみ設定される。 - input_duration: - type: number - description: | - 入力データが動画の場合、動画の長さ(秒)。小数点以下はミリ秒以下を表します。 - - 動画の長さが取得できなかった場合、あるいは入力データが画像の場合は値なし。 - updated_datetime: - type: string - format: date-time - sign_required: - type: boolean - description: | - データがSigned Cookieによるクロスオリジン配信に対応しているか否かです。 - metadata: - type: object - description: | - ユーザーが自由に登録できるkey-value型のメタデータです。主にカスタムエディタで使われることを想定しています。 - additionalProperties: - type: string - InputDataRequest: - type: object - required: - - input_data_name - - input_data_path - properties: - input_data_name: - type: string - description: 表示用の名前 - input_data_path: - type: string - example: "s3://YOUR-BUCKET/PATH/TO/OBJECT" - description: | - AnnoFabに登録する入力データの実体が保存されたパスです。 - - 対応スキーマ: - * s3 - * https - - 場面別の使い分け: - * [一時データ保存先取得API](#operation/createTempPath)を使ってAFにアップロードした場合: `s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA` - * [プライベートストレージ](/docs/faq/#prst9c)の場合 - * `https://YOUR-DOMAIN/PATH/TO/INPUT_DATA` - * `s3://YOUR-BUCKET-FOR-PRIVATE-STORAGE/PATH/TO/INPUT_DATA` - * S3プライベートストレージのパスを登録する場合、[事前に認可の設定が必要](/docs/faq/#m0b240)です。 - last_updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - sign_required: - type: boolean - description: | - データがSigned Cookieによるクロスオリジン配信に対応しているか否かです。
- このオプションを有効にする場合は、`input_data_path`として、AnnoFabのAWS IDをTrusted Signerとして登録したCloudFrontのURLを指定してください。 - metadata: - type: object - description: | - ユーザーが自由に登録できるkey-value型のメタデータです。主にカスタムエディタで使われることを想定しています。 - additionalProperties: - type: string - SupplementaryData: - type: object - required: - - project_id - - input_data_id - - supplementary_data_id - - supplementary_data_name - - supplementary_data_path - - supplementary_data_type - - supplementary_data_number - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - supplementary_data_id: - $ref: "#/components/schemas/SupplementaryDataId" - supplementary_data_name: - type: string - description: 表示用の名前 - supplementary_data_path: - type: string - example: "s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA" - description: | - 補助情報の実体が保存されたパスです。 - s3スキーマまたはhttpsスキーマのみサポートしています。 - url: - type: string - format: uri - deprecated: true - description: このフィールドはAF内部での利用のみを想定しており、依存しないでください。 - etag: - type: string - supplementary_data_type: - $ref: "#/components/schemas/SupplementaryDataType" - supplementary_data_number: - type: integer - description: 表示順を表す数値(昇順)。同じ入力データに対して複数の補助情報で表示順が重複する場合、順序不定になります。 - updated_datetime: - type: string - format: date-time - SupplementaryDataType: - type: string - enum: - - image - - text - SupplementaryDataRequest: - type: object - required: - - supplementary_data_name - - supplementary_data_path - - supplementary_data_type - - supplementary_data_number - properties: - supplementary_data_name: - type: string - description: 表示用の名前 - supplementary_data_path: - type: string - example: "s3://YOUR-BUCKET/PATH/TO/OBJECT" - description: | - AnnoFabに登録する補助情報の実体が保存されたパスです。 - - 対応スキーマ:s3, https - - * [一時データ保存先取得API](#operation/createTempPath)を使ってAFにアップロードしたファイルパスの場合 - * `s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA` - * 補助情報作成/更新API成功時、アップロードしたファイルが一時データ保存先からコピーされます。 - * APIのレスポンスからアップロードしたファイルのコピー先パス(s3スキーマ)を取得できます。 - * すでにAFに登録されている補助情報のパスの場合 - * `s3://ANNOFAB-SUPPLEMENTARY-BUCKET/PATH/TO/INPUT_DATA` - * ファイルはコピーされません。 - * [プライベートストレージ](/docs/faq/#prst9c)のパスの場合 - * `https://YOUR-DOMAIN/PATH/TO/INPUT_DATA` - * `s3://YOUR-BUCKET-FOR-PRIVATE-STORAGE/PATH/TO/INPUT_DATA` - * S3プライベートストレージのパスを登録する場合、[事前に認可の設定が必要](/docs/faq/#m0b240)です。 - * AFにファイルはコピーされません。 - supplementary_data_type: - $ref: "#/components/schemas/SupplementaryDataType" - - supplementary_data_number: - type: integer - description: 表示順を表す数値(昇順)。同じ入力データに対して複数の補助情報で表示順が重複する場合、順序不定になります。 - last_updated_datetime: - type: string - format: date-time - WebhookTestRequest: - type: object - properties: - placeholders: - description: プレースホルダ名と置換する値 - type: object - example: - SOME_PLACEHOLDER: value - SOME_NAME: value2 - WebhookTestResponse: - type: object - properties: - result: - description: | - * success: 通知先から正常なレスポンス(2xx系)を受け取った - * failure: 通知先からエラーレスポンス(2xx系以外)を受け取った - * error: リクエスト送信に失敗した、もしくはレスポンスを受信できなかった - type: string - enum: [success, failure, error] - example: success - request_body: - description: 実際に送信されたリクエストボディ - type: string - response_status: - description: 通知先から返されたHTTPステータスコード - type: integer - example: 200 - response_body: - description: 通知先から返されたレスポンスボディ - type: string - message: - description: result="error" 時のエラー内容等 - type: string - BatchInputDataRequestItemDelete: - type: object - description: 入力データ削除 - required: - - project_id - - input_data_id - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - _type: - type: string - description: | - `Delete` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Delete" - BatchTaskRequestItemDelete: - type: object - description: タスク削除 - required: - - project_id - - task_id - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - _type: - type: string - description: | - `Delete` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Delete" - DataPath: - type: object - properties: - url: - type: string - format: uri - example: "https://s3..amazonaws.com///?param1=...¶m2=..." - description: ファイルアップロード用の一時URLです。このURLにファイルをアップロードします。 - path: - type: string - example: s3://// - description: アップロードしたファイルをAFの [入力データ](#tag/af-input) や [補助情報](#tag/af-supplementary) に登録するとき、この`path`を指定します。 - InstructionImagePath: - type: object - required: - - url - - path - properties: - url: - type: string - format: uri - example: "https://s3..amazonaws.com///?param1=...¶m2=..." - description: ファイルアップロード用の一時URLです。このURLにファイルをアップロードします。 - path: - type: string - format: url - example: https://annofab.com/projects/{project_id}/instruction-images/{image_id} - description: 作業ガイド画像のURL - AnnotationQuery: - type: object - properties: - task_id: - $ref: "#/components/schemas/TaskId" - exact_match_task_id: - description: | - タスクIDの検索方法を指定します。 - trueの場合は完全一致検索、falseの場合は中間一致検索です。 - type: boolean - default: true - input_data_id: - $ref: "#/components/schemas/InputDataId" - exact_match_input_data_id: - description: | - 入力データIDの検索方法を指定します。 - trueの場合は完全一致検索、falseの場合は中間一致検索です。 - type: boolean - default: true - label_id: - $ref: "#/components/schemas/LabelId" - attributes: - type: array - items: - $ref: "#/components/schemas/AdditionalData" - Annotation: - type: object - required: - - project_id - - task_id - - input_data_id - - details - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - details: - type: array - description: 矩形、ポリゴン、全体アノテーションなど個々のアノテーションの配列。 - items: - $ref: "#/components/schemas/AnnotationDetail" - updated_datetime: - $ref: "#/components/schemas/LastUpdatedDatetime" - AnnotationDataHoldingType: - type: string - enum: - - inner - - outer - description: | - * `inner` - アノテーションのデータ部をJSON内部に保持します。 - * `outer` - アノテーションのデータ部を外部ファイルの形式(画像など)で保持します - AnnotationDetail: - type: object - required: - - annotation_id - - account_id - - label_id - - is_protected - - data_holding_type - - additional_data_list - properties: - annotation_id: - $ref: "#/components/schemas/AnnotationId" - account_id: - description: アノテーションを作成したユーザのアカウントID。 - allOf: - - $ref: "#/components/schemas/AccountId" - label_id: - description: ラベルID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 - allOf: - - $ref: "#/components/schemas/LabelId" - is_protected: - description: | - `true`の場合、アノテーションをアノテーションエディタ上での削除から保護できます。 - 外部から取り込んだアノテーションに属性を追加するときなどに指定すると、データの削除を防げます。 - type: boolean - default: false - data_holding_type: - $ref: "#/components/schemas/AnnotationDataHoldingType" - data: - oneOf: - - type: string - - $ref: "#/components/schemas/FullAnnotationData" - description: | - アノテーションの座標値や区間などのデータ。レスポンスの場合は`string`形式、[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は`string`または`object`形式です。 - `annotation_type`に応じて`string`,`object`の形式が変わります。 - - - - - - - - - - -
annotation_typedata_holding_typestring形式object形式
bounding_box inner左上x,左上y,右下x,右下yFullAnnotationDataBoundingBox
pointinnerx1,y1FullAnnotationDataSinglePoint
polygon / polyline innerx1,y1,x2,y2, ... FullAnnotationDataPoints
range inner開始時間(ミリ秒),終了時間(ミリ秒) FullAnnotationDataRange
classification innernull FullAnnotationDataClassification / null
segmentationouternull FullAnnotationDataSegmentation / null
segmentation_v2 outernull FullAnnotationDataSegmentationV2 / null
- path: - type: string - description: | - 外部ファイルに保存されたアノテーションのパス。`data_holding_type`が`inner`の場合は未指定です。 - レスポンスの場合は`annotation_id`と同じ値が格納されます。 - - [putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は、[createTempPath](#operation/createTempPath) APIで取得できる一時データ保存先S3パスを格納してください。 - 更新しない場合は、[getEditorAnnotation](#operation/getEditorAnnotation) APIで取得した`path`をそのまま渡せます。 - - 外部ファイルのフォーマットは下表の通りです。 - - - - -
annotation_type形式
segmentation / segmentation_v2 PNG画像。塗りつぶした部分はrgba(255, 255, 255, 1) 、塗りつぶしていない部分はrgba(0, 0, 0, 0)
- etag: - type: string - description: 外部ファイルに保存されたアノテーションのETag。`data_holding_type`が`inner`の場合、または[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は未指定です。 - url: - type: string - format: uri - description: 外部ファイルに保存されたアノテーションの認証済み一時URL。`data_holding_type`が`inner`の場合、または[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は未指定です。 - additional_data_list: - type: array - description: | - 各要素は、 [アノテーション仕様](#operation/getAnnotationSpecs)で定義された属性(`additional_data_definitions`内)のいずれかの要素と対応づけます。 - 各要素は、どの属性なのかを表す`additional_data_definition_id`と値が必要です。値は、属性の種類に対応するキーに格納します(下表)。 - - - - - - - - -
アノテーション属性の種類
additional_data_definitiontype
属性の値を格納するキーデータ型
text, comment または trackingcommentstring
flagflagboolean
integerintegerinteger
choice または selectchoicestring(選択肢ID)
linkcommentstring(アノテーションID)
- items: - $ref: "#/components/schemas/AdditionalData" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - AdditionalData: - type: object - required: - - additional_data_definition_id - properties: - additional_data_definition_id: - description: 属性ID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 - allOf: - - $ref: "#/components/schemas/AdditionalDataDefinitionId" - flag: - type: boolean - description: | - `additional_data_definition`の`type`が`flag`のときの属性値。 - integer: - type: integer - description: | - `additional_data_definition`の`type`が`integer`のときの属性値。 - comment: - type: string - description: | - `additional_data_definition`の`type`が`text`,`comment`,`link` または `tracking`のときの属性値。 - choice: - description: | - `additional_data_definition`の`type`が`choice` または `select `のときの属性値(選択肢ID)。 - allOf: - - $ref: "#/components/schemas/ChoiceId" - AdditionalDataValue: - oneOf: - - type: object - - $ref: "#/components/schemas/AdditionalDataValueFlag" - - $ref: "#/components/schemas/AdditionalDataValueInteger" - - $ref: "#/components/schemas/AdditionalDataValueComment" - - $ref: "#/components/schemas/AdditionalDataValueChoice" - - $ref: "#/components/schemas/AdditionalDataValueTracking" - - $ref: "#/components/schemas/AdditionalDataValueLink" - AdditionalDataValueFlag: - type: object - required: - - _type - - value - properties: - _type: - type: string - description: Flag - example: "Flag" - value: - type: boolean - description: フラグのON(true)またはOFF(false) - AdditionalDataValueInteger: - type: object - required: - - _type - properties: - _type: - type: string - description: Integer - example: "Integer" - value: - type: integer - description: 整数値 - AdditionalDataValueComment: - type: object - required: - - _type - properties: - _type: - type: string - description: Comment - example: "Comment" - value: - type: string - description: 自由記述 - AdditionalDataValueChoice: - type: object - required: - - _type - properties: - _type: - type: string - description: Choice - example: "Choice" - value: - $ref: "#/components/schemas/AdditionalDataChoiceValue" - AdditionalDataChoiceValue: - type: object - required: - - id - - name - properties: - id: - allOf: - - $ref: "#/components/schemas/ChoiceId" - - description: 選択された選択肢のID - name: - allOf: - - $ref: "#/components/schemas/InternationalizationMessage" - - description: 選択された選択肢の表示名 - AdditionalDataValueTracking: - type: object - required: - - _type - properties: - _type: - type: string - description: Tracking - example: "Tracking" - value: - type: string - description: トラッキングID - AdditionalDataValueLink: - type: object - required: - - _type - properties: - _type: - type: string - description: Link - example: "Link" - value: - type: string - description: リンク先アノテーションID - SingleAnnotation: - type: object - required: - - project_id - - task_id - - input_data_id - - detail - - updated_datetime - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - detail: - $ref: "#/components/schemas/SingleAnnotationDetail" - updated_datetime: - type: string - format: date-time - SimpleAnnotation: - type: object - required: - - annotation_format_version - - project_id - - task_id - - task_phase - - task_phase_stage - - task_status - - input_data_id - - input_data_name - - details - properties: - annotation_format_version: - $ref: "#/components/schemas/AnnotationFormatVersion" - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - task_phase: - $ref: "#/components/schemas/TaskPhase" - task_phase_stage: - type: integer - default: 1 - minimum: 1 - task_status: - $ref: "#/components/schemas/TaskStatus" - input_data_id: - $ref: "#/components/schemas/InputDataId" - input_data_name: - type: string - description: 入力データ名 - details: - type: array - description: 矩形、ポリゴン、全体アノテーションなど個々のアノテーションの配列。 - items: - $ref: "#/components/schemas/SimpleAnnotationDetail" - updated_datetime: - type: string - format: date-time - description: 更新日時。アノテーションが一つもない場合(教師付作業が未着手のときなど)は、未指定。 - BatchAnnotation: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - annotation_id: - $ref: "#/components/schemas/AnnotationId" - label_id: - $ref: "#/components/schemas/LabelId" - additional_data_list: - type: array - items: - $ref: "#/components/schemas/AdditionalData" - updated_datetime: - type: string - format: date-time - BatchAnnotationRequestItemPut: - type: object - description: アノテーション更新 - required: - - data - properties: - data: - $ref: "#/components/schemas/BatchAnnotation" - _type: - type: string - description: | - `Put` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Put" - BatchAnnotationRequestItemDelete: - type: object - description: アノテーション削除 - required: - - project_id - - task_id - - input_data_id - - annotation_id - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - annotation_id: - $ref: "#/components/schemas/AnnotationId" - updated_datetime: - type: string - format: date-time - _type: - type: string - description: | - `Delete` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Delete" - SingleAnnotationDetail: - type: object - required: - - annotation_id - - account_id - - label_id - - data_holding_type - - additional_data_list - - created_datetime - - updated_datetime - properties: - annotation_id: - $ref: "#/components/schemas/AnnotationId" - account_id: - $ref: "#/components/schemas/AccountId" - label_id: - $ref: "#/components/schemas/LabelId" - data_holding_type: - $ref: "#/components/schemas/AnnotationDataHoldingType" - data: - $ref: "#/components/schemas/FullAnnotationData" - etag: - type: string - description: data_holding_typeがouterの場合のみ存在し、データのETagが格納される - url: - type: string - format: uri - description: data_holding_typeがouterの場合のみ存在し、データへの一時URLが格納される - additional_data_list: - type: array - items: - $ref: "#/components/schemas/AdditionalData" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - SimpleAnnotationDetail: - type: object - required: - - label - - annotation_id - - data - - attributes - properties: - label: - type: string - example: "pedestrian" - description: | - アノテーション仕様のラベル名です。 - annotation_id: - type: string - example: "acb5359e-be2e-402b-b59a-b5fdbb378ad9" - description: | - 個々のアノテーションにつけられたIDです。 - data: - $ref: "#/components/schemas/FullAnnotationData" - attributes: - type: object - description: | - キーに属性の名前、値に各属性の値が入った辞書構造です。 - example: - maker: "AAA Motors" - size: 12345 - is_foo_bar_buz: true - FullAnnotation: - type: object - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - task_phase: - $ref: "#/components/schemas/TaskPhase" - task_phase_stage: - type: integer - default: 1 - minimum: 1 - task_status: - $ref: "#/components/schemas/TaskStatus" - input_data_id: - $ref: "#/components/schemas/InputDataId" - input_data_name: - type: string - details: - type: array - items: - $ref: "#/components/schemas/FullAnnotationDetail" - updated_datetime: - type: string - format: date-time - annotation_format_version: - $ref: "#/components/schemas/AnnotationFormatVersion" - FullAnnotationDetail: - type: object - properties: - annotation_id: - $ref: "#/components/schemas/AnnotationId" - user_id: - $ref: "#/components/schemas/UserId" - label_id: - $ref: "#/components/schemas/LabelId" - label_name: - $ref: "#/components/schemas/InternationalizationMessage" - annotation_type: - $ref: "#/components/schemas/AnnotationType" - data_holding_type: - $ref: "#/components/schemas/AnnotationDataHoldingType" - data: - $ref: "#/components/schemas/FullAnnotationData" - additional_data_list: - type: array - items: - $ref: "#/components/schemas/FullAnnotationAdditionalData" - FullAnnotationData: - oneOf: - - type: object - - $ref: "#/components/schemas/FullAnnotationDataClassification" - - $ref: "#/components/schemas/FullAnnotationDataSegmentation" - - $ref: "#/components/schemas/FullAnnotationDataSegmentationV2" - - $ref: "#/components/schemas/FullAnnotationDataBoundingBox" - - $ref: "#/components/schemas/FullAnnotationDataPoints" - - $ref: "#/components/schemas/FullAnnotationDataSinglePoint" - - $ref: "#/components/schemas/FullAnnotationDataRange" - - $ref: "#/components/schemas/FullAnnotationDataUnknown" - description: | - アノテーションのデータが格納されます。 - * `FullAnnotationDataClassification`: 入力データ全体に対するアノテーションデータです。 - * `FullAnnotationDataSegmentation`: ピクセルレベルでの塗りつぶし(ラスター)のアノテーションデータです。 - * `FullAnnotationDataSegmentationV2`: 塗りつぶしv2ののアノテーションデータです。塗りつぶしv2はSemantic Segmentationに特化しています。 - * `FullAnnotationDataBoundingBox`: 矩形のアノテーションデータです。 - * `FullAnnotationDataPoints`: ポリゴン(閉じた頂点集合)のアノテーションデータです。 - * `FullAnnotationDataSegmentation`: 点のアノテーションデータです。 - * `FullAnnotationDataRange`: 動画区間のアノテーションデータです。 - FullAnnotationDataClassification: - type: object - required: - - _type - properties: - _type: - type: string - description: Classification - example: "Classification" - FullAnnotationDataSegmentation: - description: 塗っていないところは rgba(0,0,0,0)、塗ったところは rgba(255,255,255,1) の PNGデータをBase64エンコードしたもの。 - type: object - required: - - data_uri - - _type - properties: - data_uri: - type: string - _type: - type: string - description: Segmentation - example: "Segmentation" - FullAnnotationDataSegmentationV2: - type: object - required: - - data_uri - - _type - properties: - data_uri: - type: string - _type: - type: string - description: SegmentationV2 - example: "SegmentationV2" - FullAnnotationDataBoundingBox: - description: annotation_type が bounding_boxの場合に、[左上頂点座標, 右下頂点座標]を {"x":int, "y":int} の形式で記述したもの。 - type: object - required: - - left_top - - right_bottom - - _type - properties: - left_top: - $ref: "#/components/schemas/Point" - right_bottom: - $ref: "#/components/schemas/Point" - _type: - type: string - description: BoundingBox - example: "BoundingBox" - FullAnnotationDataPoints: - description: | - 頂点座標 {"x":int, "y":int} の配列。 - - * annotation_type が polygon/polyline の場合: ポリゴン/ポリラインを構成する頂点の配列。 - type: object - required: - - points - - _type - properties: - points: - type: array - items: - $ref: "#/components/schemas/Point" - _type: - type: string - description: Points - example: "Points" - FullAnnotationDataSinglePoint: - description: annotation_type が pointの場合。 - type: object - required: - - point - - _type - properties: - point: - $ref: "#/components/schemas/Point" - _type: - type: string - description: SinglePoint。 - example: "SinglePoint" - FullAnnotationDataRange: - description: annotation_type が rangeの場合に、[開始時間, 終了時間]を {"begin":number, "end":number} の形式で記述したもの。開始時間・終了時間の単位は秒で、精度はミリ秒まで。 - type: object - required: - - begin - - end - - _type - properties: - begin: - type: number - description: 開始時間(ミリ秒)。小数点以下はミリ秒以下を表します。 - end: - type: number - description: 終了時間(ミリ秒)。小数点以下はミリ秒以下を表します。 - _type: - type: string - description: Range - example: "Range" - FullAnnotationDataUnknown: - description: annotation_typeにデータ構造が一致していない場合に、元のdata文字列をそのまま記述したもの。 - type: object - required: - - data - - _type - properties: - data: - type: string - _type: - type: string - description: Unknown - example: "Unknown" - Point: - description: 座標 - type: object - required: - - x - - y - properties: - x: - type: integer - y: - type: integer - FullAnnotationAdditionalData: - type: object - properties: - additional_data_definition_id: - allOf: - - $ref: "#/components/schemas/AdditionalDataDefinitionId" - - description: 属性ID - additional_data_definition_name: - allOf: - - $ref: "#/components/schemas/InternationalizationMessage" - - description: 属性表示名 - type: - $ref: "#/components/schemas/AdditionalDataDefinitionType" - value: - $ref: "#/components/schemas/AdditionalDataValue" - BatchInspectionRequestItemPut: - type: object - description: 検査コメント更新 - required: - - data - properties: - data: - $ref: "#/components/schemas/Inspection" - _type: - type: string - description: | - `Put` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Put" - BatchInspectionRequestItemDelete: - type: object - description: 検査コメント削除 - required: - - project_id - - task_id - - input_data_id - - inspection_id - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - inspection_id: - $ref: "#/components/schemas/InspectionId" - _type: - type: string - description: | - `Delete` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Delete" - Inspection: - type: object - description: 検査コメント - required: - - project_id - - task_id - - input_data_id - - inspection_id - - phase - - phase_stage - - commenter_account_id - - data - - status - - comment - - created_datetime - properties: - project_id: - $ref: "#/components/schemas/ProjectId" - task_id: - $ref: "#/components/schemas/TaskId" - input_data_id: - $ref: "#/components/schemas/InputDataId" - inspection_id: - $ref: "#/components/schemas/InspectionId" - phase: - description: 検査コメントを付与したときのタスクフェーズ。[詳細はこちら](#section/TaskPhase) - allOf: - - $ref: "#/components/schemas/TaskPhase" - phase_stage: - type: integer - description: 検査コメントを付与したときのフェーズのステージ - default: 1 - minimum: 1 - commenter_account_id: - allOf: - - $ref: "#/components/schemas/AccountId" - description: 検査コメントを付与したユーザのアカウントID - annotation_id: - description: | - 検査コメントに紐づくアノテーションのID。アノテーションに紐付けられていない場合(アノテーションの付け忘れに対する指定など)は未指定。 - [詳細はこちら](#section/AnnotationId)。 - allOf: - - $ref: "#/components/schemas/AnnotationId" - data: - description: | - 検査コメントの座標値や区間。 - - * `InspectionDataPoint`:点で検査コメントを付与したときの座標値 - * `InspectionDataPolyline`:ポリラインで検査コメントを付与したときの座標値 - * `InspectionDataTime`:検査コメントを付与した区間(動画プロジェクトの場合) - oneOf: - - $ref: "#/components/schemas/InspectionDataPoint" - - $ref: "#/components/schemas/InspectionDataPolyline" - - $ref: "#/components/schemas/InspectionDataTime" - parent_inspection_id: - description: | - 返信先の検査コメントの検査ID。返信先の検査コメントは「スレッド内の直前のコメント」ではなく「スレッドの先頭のコメント」を指します。 - allOf: - - $ref: "#/components/schemas/InspectionId" - phrases: - type: array - description: 参照している定型指摘のID。 - items: - $ref: "#/components/schemas/PhraseId" - comment: - description: | - 検査コメントの中身 - type: string - example: 枠がズレています - status: - $ref: "#/components/schemas/InspectionStatus" - created_datetime: - type: string - format: date-time - updated_datetime: - type: string - format: date-time - InspectionDataPoint: - type: object - description: | - 問題のある部分を示す座標 - required: - - x - - y - properties: - x: - type: integer - y: - type: integer - _type: - type: string - description: | - `Point` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Point" - InspectionDataPolyline: - type: object - description: | - 問題のある部分を示すポリライン - required: - - coordinates - properties: - coordinates: - type: array - description: | - ポリラインを構成する頂点の配列 - items: - type: object - properties: - x: - type: integer - y: - type: integer - _type: - type: string - description: | - `Polyline` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Polyline" - InspectionDataTime: - type: object - description: | - 問題のある時間帯を表す区間 - required: - - start - - end - properties: - start: - type: number - description: 開始時間(ミリ秒)。小数点以下はミリ秒以下を表します。 - end: - type: number - description: 終了時間(ミリ秒)。小数点以下はミリ秒以下を表します。 - _type: - type: string - description: | - `Time` - [詳しくはこちら](#section/API-Convention/API-_type) - example: "Time" - Resolution: - type: object - required: - - width - - height - properties: - width: - type: number - height: - type: number - InspectionStatus: - type: string - enum: - - annotator_action_required - - no_correction_required - - error_corrected - - no_comment_inspection - description: | - * `annotator_action_required` - 未処置。`annotation`フェーズ担当者が何らかの回答をする必要あり - * `no_correction_required` - 処置不要。`annotation`フェーズ担当者が、検査コメントによる修正は不要、と回答した - * `error_corrected` - 修正済み。`annotation`フェーズ担当者が、検査コメントの指示どおり修正した - * `no_comment_inspection` - 作成途中。検査コメントの中身が未入力 - AggregationResult: - oneOf: - - type: object - - $ref: "#/components/schemas/CountResult" - CountResult: - type: object - properties: - _type: - type: string - example: "CountResult" - description: | - 他と区別するために `CountResult` を指定します - name: - type: string - field: - type: string - items: - type: array - items: - $ref: "#/components/schemas/Count" - Count: - type: object - properties: - key: - type: string - count: - type: integer - aggregations: - type: array - items: - $ref: "#/components/schemas/AggregationResult" - Instruction: - type: object - properties: - html: - type: string - description: 作業ガイドのHTML - example: "

test

" - last_updated_datetime: - type: string - format: date-time - description: | - * [getInstruction](#operation/getInstruction) APIのレスポンスの場合: 最後に作業ガイドを更新した日時。 - * [putInstruction](#operation/putInstruction) APIのリクエストボディの場合: 最後に作業ガイドを更新した日時を指定する。まだ一度も保存した事がない場合は指定しない。 - InstructionHistory: - type: object - required: - - history_id - - account_id - - updated_datetime - properties: - history_id: - type: string - description: 作業ガイドの履歴ID - account_id: - type: string - description: 作業ガイドを更新したユーザのアカウントID - updated_datetime: - type: string - format: date-time - description: 作業ガイドの最終更新日時 - InstructionImage: - type: object - required: - - image_id - - path - - url - - etag - properties: - image_id: - type: string - description: 作業ガイド画像ID - path: - type: string - example: "s3://ANNOFAB-BUCKET/PATH/TO/INSTRUCTION_IMAGE" - description: | - 作業ガイド画像の実体が保存されたパスです。 - url: - type: string - format: uri - example: https://annofab.com/projects/{project_id}/instruction-images/{image_id} - description: - 作業ガイド画像を取得するための内部用URLです。 - etag: - type: string - ValidationError: - oneOf: - - type: object - - $ref: "#/components/schemas/InvalidAnnotationData" - - $ref: "#/components/schemas/DuplicatedSegmentationV2" - - $ref: "#/components/schemas/InvalidCommentFormat" - - $ref: "#/components/schemas/UnknownLinkTarget" - - $ref: "#/components/schemas/InvalidLinkTarget" - - $ref: "#/components/schemas/EmptyAttribute" - - $ref: "#/components/schemas/Duplicated" - - $ref: "#/components/schemas/UnknownAdditionalData" - - $ref: "#/components/schemas/OutOfImageBounds" - - $ref: "#/components/schemas/UnknownLabel" - InvalidAnnotationData: - type: object - description: アノテーションデータ不正エラー - properties: - labelId: - type: string - annotationId: - type: string - message: - type: string - _type: - type: string - description: InvalidAnnotationData - example: "InvalidAnnotationData" - DuplicatedSegmentationV2: - type: object - description: 塗りつぶしv2のラベルに対する1ラベルにつき1アノテーションまでの制約違反エラー - properties: - labelId: - type: string - annotationIds: - type: array - items: - type: string - _type: - type: string - description: DuplicatedSegmentationV2 - example: "DuplicatedSegmentationV2" - InvalidCommentFormat: - type: object - description: コメントが正規表現に合致しないエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: InvalidCommentFormat - example: "InvalidCommentFormat" - UnknownLinkTarget: - type: object - description: 指定されたIDに該当するアノテーションが存在しないエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: UnknownLinkTarget - example: "UnknownLinkTarget" - InvalidLinkTarget: - type: object - description: リンク先アノテーションが許可されているラベルでないエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: InvalidLinkTarget - example: "InvalidLinkTarget" - EmptyAttribute: - type: object - description: 属性が未入力であるエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: EmptyAttribute - example: "EmptyAttribute" - Duplicated: - type: object - description: 値の重複が許可されていない属性の重複エラー - properties: - labelId: - type: string - annotationId: - type: string - additionalData: - $ref: "#/components/schemas/AdditionalData" - _type: - type: string - description: Duplicated - example: "Duplicated" - UnknownAdditionalData: - type: object - description: 何らかの原因で、アノテーション仕様にない属性がついているエラー - properties: - labelId: - type: string - annotationId: - type: string - additionalDataDefinitionId: - type: string - _type: - type: string - description: UnknownAdditionalData - example: "UnknownAdditionalData" - OutOfImageBounds: - type: object - description: 画像範囲外にアノテーションがはみ出しているエラー - properties: - labelId: - type: string - annotationId: - type: string - _type: - type: string - description: OutOfImageBounds - example: "OutOfImageBounds" - UnknownLabel: - type: object - description: 何らかの原因で、アノテーション仕様にないラベルがついているエラー - properties: - labelId: - type: string - annotationId: - type: string - _type: - type: string - description: UnknownLabel - example: "UnknownLabel" - ProjectTaskCounts: - type: object - properties: - task_counts: - type: array - items: - type: object - properties: - phase: - $ref: "#/components/schemas/TaskPhase" - status: - $ref: "#/components/schemas/TaskStatus" - count: - description: 該当するタスクの数 - type: number + $ref: swagger-api-components.redoc.yaml#/components/schemas/InstructionImagePath + "401": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + "404": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + "503": + $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance From c2d30ded39c781a5abde1bc4c94a76e7ac78dffe Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Tue, 23 Jun 2020 19:05:41 +0900 Subject: [PATCH 03/15] update swagger --- generate/swagger/swagger-api-components.yaml | 1102 +++-- generate/swagger/swagger.v2.yaml | 839 ++-- generate/swagger/swagger.yaml | 4637 +++++++++--------- 3 files changed, 3350 insertions(+), 3228 deletions(-) diff --git a/generate/swagger/swagger-api-components.yaml b/generate/swagger/swagger-api-components.yaml index d162f50b..9c54b830 100644 --- a/generate/swagger/swagger-api-components.yaml +++ b/generate/swagger/swagger-api-components.yaml @@ -1,3 +1,4 @@ +components: securitySchemes: SignedCookieKeyPairId: description: | @@ -20,7 +21,7 @@ EveryoneRequestBody: description: | AnnoFabのユーザーなら誰でも利用できます。 - + 認証/認可には、リクエストボディに含まれるパスワード、トークン、または何らかの検証コードを用います。 詳しくは個別のAPIの説明を確認してください。 type: "http" @@ -28,7 +29,7 @@ EveryoneQueryParameter: description: | AnnoFabのユーザーなら誰でも利用できます。 - + 認証/認可には、クエリパラメータに含まれるトークンまたは何らかの検証コードを用います。 詳しくは個別のAPIの説明を確認してください。 type: "http" @@ -36,7 +37,7 @@ Everyone: description: | AnnoFabのユーザーなら誰でも利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -45,7 +46,7 @@ AnnoFabAdminOnly: description: | AnnoFabのシステム管理者のみ利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -54,7 +55,7 @@ AllProjectMember: description: | プロジェクトに所属するユーザーなら誰でも利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -63,7 +64,7 @@ ProjectAccepter: description: | プロジェクトのオーナーまたはプロジェクトのチェッカーのみ利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -72,7 +73,7 @@ ProjectDataUser: description: | プロジェクトのオーナーまたはプロジェクトのアノテーションユーザーのみ利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -81,7 +82,7 @@ ProjectAccepterOrDataUser: description: | プロジェクトのオーナー/チェッカー/アノテーションユーザーのいずれかのみ利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -90,7 +91,7 @@ ProjectOwner: description: | プロジェクトのオーナーのみ利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -99,7 +100,7 @@ AllOrganizationMember: description: | 組織に所属するユーザーなら誰でも利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -108,7 +109,7 @@ OrganizationAdministrator: description: | 組織のオーナーまたは組織の管理者のみ利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -117,7 +118,7 @@ OrganizationOwner: description: | 組織のオーナーのみ利用できます。 - + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 type: "apiKey" @@ -193,11 +194,11 @@ errors: type: array items: - $ref: "#/components/schemas/Error" + $ref: "#/components/schemas/ErrorItem" context: type: object description: 内部補足情報 - Error: + ErrorItem: type: object properties: error_code: @@ -209,245 +210,37 @@ type: object description: 補足情報 ErrorInvalidBody: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INVALID_BODY - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorInvalidQueryParam: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INVALID_QUERYPARAM - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorMissingNecessaryQueryParam: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: MISSING_NECESSARY_QUERYPARAM - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorInvalidPath: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INVALID_PATH - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorUnauthorizedApi: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: UNAUTHORIZED_API - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorLoginFailed: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: LOGIN_FAILED - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorPasswordResetRequired: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: PASSWORD_RESET_REQUIRED - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorExpiredToken: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: EXPIRED_TOKEN - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorRefreshTokenExpired: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: EXPIRED_REFRESH_TOKEN - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorForbiddenResource: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: FORBIDDEN_RESOURCE - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorMissingResource: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: MISSING_RESOURCE - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorTimeout: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: TIMEOUT - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorAlreadyUpdated: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: ALREADY_UPDATED - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorStateMismatch: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: STATE_MISMATCH - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorInternalServerError: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: INTERNAL_SERVER_ERROR - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' ErrorUnderMaintenance: - type: object - properties: - errors: - type: array - items: - allOf: - - $ref: '#/components/schemas/Error' - - properties: - error_code: - type: string - example: UNDER_MAINTENANCE - context: - type: object - description: 内部補足情報 + $ref: '#/components/schemas/Errors' Message: type: object properties: @@ -800,6 +593,7 @@ required: - organization_id - plugin_id + - compatible_input_data_types - created_datetime - updated_datetime properties: @@ -813,6 +607,8 @@ $ref: "#/components/schemas/PluginDescription" annotation_editor_url: $ref: "#/components/schemas/AnnotationEditorUrl" + compatible_input_data_types: + $ref: "#/components/schemas/PluginCompatibleInputDataTypes" created_datetime: type: string format: date-time @@ -821,6 +617,8 @@ format: date-time PutOrganizationPluginRequest: type: object + required: + - compatible_input_data_types properties: plugin_name: $ref: "#/components/schemas/PluginName" @@ -828,6 +626,8 @@ $ref: "#/components/schemas/PluginDescription" annotation_editor_url: $ref: "#/components/schemas/AnnotationEditorUrl" + compatible_input_data_types: + $ref: "#/components/schemas/PluginCompatibleInputDataTypes" last_updated_datetime: $ref: "#/components/schemas/LastUpdatedDatetime" PluginId: @@ -847,23 +647,30 @@ description: | プラグインの説明です。 プラグイン一覧や、プロジェクトで使うプラグインを選ぶときなどに表示されます。 + PluginCompatibleInputDataTypes: + type: array + items: + $ref: "#/components/schemas/InputDataType" + example: ["custom"] + description: | + プラグインが対応している入力データです。 AnnotationEditorUrl: type: string example: "https://example.com/my/editors?p={projectId}&t={taskId}" description: | カスタムアノテーションエディタでタスクを開くための URL です。 プラグインを使用するプロジェクトのタスク一覧などで使用されます。 - + この URL には、タスクを特定するための以下のパラメータを必ず埋め込んでください。 - + * `{projectId}` * `{taskId}` - + 以下のパラメーターは任意で指定します。 - + * `{inputDataId}`: アノテーション一覧などから、特定の入力データにフォーカスした状態でタスクを開くときなどに指定します。 * `{annotationId}`: アノテーション一覧などから、特定のアノテーションにフォーカスした状態でタスクを開くときなどに指定します。 - + MyOrganization: type: object properties: @@ -936,6 +743,17 @@ UserId: type: string example: "john_doe" + UserCacheRecord: + type: object + properties: + account: + type: string + members: + type: string + projects: + type: string + organizations: + type: string OrganizationId: type: string example: "12345678-abcd-1234-abcd-1234abcd5678" @@ -1015,7 +833,7 @@ type: string description: | 人物紹介、略歴。 - + この属性は、AnnoFab外の所属先や肩書などを表すために用います。 AnnoFab上の「複数の組織」で活動する場合、本籍を示すのに便利です。 minLength: 0 @@ -1028,9 +846,9 @@ アノテーションフォーマットのバージョンです。 アノテーションフォーマットとは、プロジェクト個別のアノテーション仕様ではなく、AnnoFabのアノテーション構造のことです。 したがって、アノテーション仕様を更新しても、このバージョンは変化しません。 - + バージョンの読み方と更新ルールは、業界慣習の[Semantic Versioning](https://semver.org/)にもとづきます。 - + JSONに出力されるアノテーションフォーマットのバージョンは、アノテーションZIPが作成される時点のものが使われます。 すなわち、`1.0.0`の時点のタスクで作成したアノテーションであっても、フォーマットが `1.0.1` に上がった次のZIP作成時では `1.0.1` となります。 バージョンを固定してZIPを残しておきたい場合は、プロジェクトが完了した時点でZIPをダウンロードして保管しておくか、またはプロジェクトを「停止中」にします。 @@ -1095,9 +913,11 @@ アノテーションする入力データの種類。プロジェクトの作成時のみ指定可能(未指定の場合は `image`)です。更新時は無視されます。 * `image` - 画像 * `movie` - 動画 + * `custom` - カスタム enum: - image - movie + - custom ProjectConfiguration: type: object properties: @@ -1133,14 +953,14 @@ type: array items: $ref: "#/components/schemas/InputDataSetId" - example: "[]" + example: [] input_data_max_long_side_length: description: | 入力データ画像の長辺の最大値(未指定時は4096px)。 - + 画像をアップロードすると、長辺がこの値になるように画像が自動で圧縮されます。 アノテーションの座標は、もとの解像度の画像でつけたものに復元されます。 - + 大きな数値を設定すると入力データ画像のサイズが大きくなり、生産性低下やブラウザで画像を表示できない懸念があります。注意して設定してください。 type: integer default: 4096 @@ -1173,7 +993,7 @@ - random_and_selection description: | プロジェクトで使用するタスクの割当方式。 - + * `random` - タスクフェーズのみを指定してランダムにタスクを自身に割当する方式です。 * `selection` - 担当者とタスクを明示的に指定してタスクを割当する方式です。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。 * `random_and_selection` - ランダム割当と選択割当の両機能を使用する方式です。 @@ -1211,6 +1031,7 @@ - gen-inputs-list - delete-project - invoke-hook + - move-project description: | * `copy-project` - プロジェクトのコピー。[initiateProjectCopy](#operation/initiateProjectCopy) APIを実行したときに登録されるジョブ。 * `gen-inputs` - zipファイルから入力データの作成。[putInputData](#operation/putInputData) APIを実行して、zipファイルから入力データを作成したときに登録されるジョブ。 @@ -1220,6 +1041,7 @@ * `gen-inputs-list` - 入力データ情報全件ファイルの更新。[postProjectInputsUpdate](#operation/postProjectInputsUpdate) APIを実行したときに登録されるジョブ。 * `delete-project` - プロジェクトの削除。[deleteProject](#operation/deleteProject) APIを実行したときに登録されるジョブ。 * `invoke-hook` - Webhookの起動。 + * `move-project` - プロジェクトの組織移動。[putProject](#operation/putProject) API で組織を変更したときに登録されるジョブ。 JobStatus: type: string enum: @@ -1250,6 +1072,13 @@ $ref: "#/components/schemas/JobInfo" project: $ref: "#/components/schemas/Project" + PutProjectResponse: + type: object + properties: + job: + $ref: "#/components/schemas/JobInfo" + project: + $ref: "#/components/schemas/Project" TaskGenerateResponse: type: object properties: @@ -1346,7 +1175,7 @@ type: string description: | プロジェクトの所属組織を変更する場合は、ここに変更先の組織名を指定します。 - + * 所属組織を変更する前にプロジェクトを停止する必要があります。 * APIを呼び出すアカウントは、変更先組織の管理者またはオーナーである必要があります。 * 変更後の組織に所属していないプロジェクトメンバーも残りますが、作業はできません。あらためて組織に招待してください。 @@ -1381,18 +1210,18 @@ type: boolean description: | 「タスク」をコピーするかどうかを指定します。 - + この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 - + * copy_inputs の値を true とする default: false copy_annotations: type: boolean description: | 「アノテーション」をコピーするかどうかを指定します。 - + この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 - + * copy_inputs の値を true とする * copy_tasks の値を true とする default: false @@ -1405,9 +1234,9 @@ type: boolean description: | 「補助情報」をコピーするかどうかを指定します。 - + この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 - + * copy_inputs の値を true とする default: false copy_instructions: @@ -1860,8 +1689,7 @@ マーカーのタイトルには `comment` に指定された文字列が設定されます。 `comment` が指定されていなかった場合は "アノテーション仕様の変更" という文字列が設定されます。 last_updated_datetime: - allOf: - - $ref: "#/components/schemas/LastUpdatedDatetime" + $ref: "#/components/schemas/LastUpdatedDatetime" description: | 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 新規作成時は未指定。 @@ -1905,8 +1733,7 @@ type: string default: "2.1.0" last_updated_datetime: - allOf: - - $ref: "#/components/schemas/LastUpdatedDatetime" + $ref: "#/components/schemas/LastUpdatedDatetime" description: | 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 新規作成時は未指定。 @@ -1944,6 +1771,7 @@ - point - classification - range + - custom description: | * `bounding_box` - 矩形を表します。 * `segmentation` - ピクセルレベルでの塗りつぶし(ラスター)を表します。 @@ -1953,6 +1781,7 @@ * `point` - 点を表します。 * `classification` - 入力データ全体に対するアノテーションを表します。 * `range` - 動画の区間を表します。 + * `custom` - カスタム AdditionalDataDefinitionType: type: string enum: @@ -1980,7 +1809,7 @@ 画像左上の座標が「x=0, y=0」です。 未指定、もしくは「画像外に飛び出たアノテーション」を許可していないにも関わらず飛び出してしまう場合は、表示範囲の中央に挿入されます。 「スキャンした帳票の記入欄」や「定点カメラで撮影した製品ラベル」など、アノテーションしたい位置やサイズが多くの画像で共通している場合に便利です。 - + `annotation_type` が `bounding_box` 以外の場合は必ず未指定となります。 required: - x @@ -2147,25 +1976,7 @@ name: $ref: "#/components/schemas/InternationalizationMessage" default: - oneOf: - - type: boolean - - type: integer - - type: string - description: | - 属性の初期値です。 - - 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 - - * type が flag の場合: 真偽値(`true` or `false`) - * type が integer の場合: 整数値 - * type が text の場合: 文字列 - * type が comment の場合: 文字列 - * type が choice の場合: 選択肢(`choices`)の `choice_id` - * type が select の場合: 選択肢(`choices`)の `choice_id` - - 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 - - なお、トラッキングとリンクには初期値を設定できません。 + $ref: "#/components/schemas/AdditionalDataDefaultType" keybind: type: array items: @@ -2206,25 +2017,7 @@ name: $ref: "#/components/schemas/InternationalizationMessage" default: - oneOf: - - type: boolean - - type: integer - - type: string - description: | - 属性の初期値です。 - - 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 - - * type が flag の場合: 真偽値(`true` or `false`) - * type が integer の場合: 整数値 - * type が text の場合: 文字列 - * type が comment の場合: 文字列 - * type が choice の場合: 選択肢(`choices`)の `choice_id` - * type が select の場合: 選択肢(`choices`)の `choice_id` - - 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 - - なお、トラッキングとリンクには初期値を設定できません。 + $ref: "#/components/schemas/AdditionalDataDefaultType" keybind: type: array items: @@ -2260,6 +2053,16 @@ - $ref: "#/components/schemas/AdditionalDataRestrictionConditionNotMatches" - $ref: "#/components/schemas/AdditionalDataRestrictionConditionHasLabel" - $ref: "#/components/schemas/AdditionalDataRestrictionConditionImply" + discriminator: + propertyName: "_type" + mapping: + CanInput: "#/components/schemas/AdditionalDataRestrictionConditionCanInput" + Equals: "#/components/schemas/AdditionalDataRestrictionConditionEquals" + NotEquals: "#/components/schemas/AdditionalDataRestrictionConditionNotEquals" + Matches: "#/components/schemas/AdditionalDataRestrictionConditionMatches" + NotMatches: "#/components/schemas/AdditionalDataRestrictionConditionNotMatches" + HasLabel: "#/components/schemas/AdditionalDataRestrictionConditionHasLabel" + Imply: "#/components/schemas/AdditionalDataRestrictionConditionImply" AdditionalDataRestrictionConditionCanInput: type: object description: | @@ -2323,6 +2126,9 @@ description: | premise で指定された条件を満たすとき、condition で指定された条件を満たすことを要求します。 properties: + _type: + type: string + example: "Imply" premise: $ref: "#/components/schemas/AdditionalDataRestriction" condition: @@ -2380,10 +2186,10 @@ deprecated: true description: | このタスクが差戻しされた回数(すべてのフェーズでの差戻し回数の合計 - + このフィールドは、どのフェーズで何回差戻されたかを区別できないため、廃止予定です。 `histories_by_phase` で各フェーズの回数を計算することで、差戻し回数が分かります。 - + 例)`acceptance`フェーズが3回ある場合、`acceptance`フェーズで2回差し戻しされたことになります。 started_datetime: type: string @@ -2403,7 +2209,7 @@ * `inspection_stages_skipped` - このタスクが抜取検査の対象外となり、検査フェーズのステージを一部スキップしたことを表す。 * `acceptance_skipped` - このタスクが抜取検査の対象外となり、受入フェーズをスキップしたことを表す。 * `inspection_and_acceptance_skipped` - このタスクが抜取検査の対象外となり、検査・受入フェーズをスキップしたことを表す - + 未指定時はこのタスクが抜取検査の対象となったことを表す。(通常のワークフローを通過する) TaskPhase: type: string @@ -2452,18 +2258,26 @@ - project_last_updated_datetime properties: task_generate_rule: - description: | - * `TaskGenerateRuleByCount`: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 - * `TaskGenerateRuleByDirectory`: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。 - * `TaskGenerateRuleByInputDataCsv`: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 - oneOf: - - $ref: "#/components/schemas/TaskGenerateRuleByCount" - - $ref: "#/components/schemas/TaskGenerateRuleByDirectory" - - $ref: "#/components/schemas/TaskGenerateRuleByInputDataCsv" + $ref: "#/components/schemas/TaskGenerateRule" project_last_updated_datetime: type: string format: date-time description: プロジェクトの最終更新日時([getProject](#operation/getProject) APIのレスポンス `updated_datetime`)。タスク生成の排他制御に使用。 + TaskGenerateRule: + description: | + * `TaskGenerateRuleByCount`: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 + * `TaskGenerateRuleByDirectory`: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。 + * `TaskGenerateRuleByInputDataCsv`: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 + oneOf: + - $ref: "#/components/schemas/TaskGenerateRuleByCount" + - $ref: "#/components/schemas/TaskGenerateRuleByDirectory" + - $ref: "#/components/schemas/TaskGenerateRuleByInputDataCsv" + discriminator: + propertyName: "_type" + mapping: + ByCount: "#/components/schemas/TaskGenerateRuleByCount" + ByDirectory: "#/components/schemas/TaskGenerateRuleByDirectory" + ByInputDataCsv: "#/components/schemas/TaskGenerateRuleByInputDataCsv" TaskGenerateRuleByCount: description: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 type: object @@ -2535,7 +2349,7 @@ - random description: | タスクに割り当てる入力データの順序 - + * `name_asc` - 入力データ名 昇順(a, b, c, ...)。日付や番号などの連続するデータ名を扱う場合に推奨 * `name_desc` - 入力データ名 降順(z, y, x, ...) * `random` - ランダム @@ -2546,18 +2360,15 @@ - last_updated_datetime properties: status: + $ref: "#/components/schemas/TaskStatus" description: | 次に遷移させるタスクの状態。[詳細はこちら](#section/TaskStatus)。 - allOf: - - $ref: "#/components/schemas/TaskStatus" last_updated_datetime: - allOf: - - $ref: "#/components/schemas/LastUpdatedDatetime" + $ref: "#/components/schemas/LastUpdatedDatetime" description: | タスクの最終更新日時 account_id: - allOf: - - $ref: "#/components/schemas/AccountId" + $ref: "#/components/schemas/AccountId" description: 変更後の担当者のアカウントID。担当者を未割り当てにする場合は未指定。 force: type: boolean @@ -2568,30 +2379,35 @@ type: object properties: phase: - allOf: - - $ref: "#/components/schemas/TaskPhase" - - description: 開始するタスクのフェーズ + $ref: "#/components/schemas/TaskPhase" + description: 開始するタスクのフェーズ TaskAssignRequest: type: object required: - request_type properties: request_type: - description: | - * `TaskAssignRequestTypeRandom`: タスクフェーズのみを指定してランダムにタスクを自身に割当します。プロジェクト設定でタスクのランダム割当を有効にした場合のみ利用できます。 - * `TaskAssignRequestTypeSelection`: 担当者とタスクを明示的に指定してタスクを割当します。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。プロジェクト設定でタスクの選択割当を有効にした場合のみ利用できます。 - oneOf: - - $ref: "#/components/schemas/TaskAssignRequestTypeRandom" - - $ref: "#/components/schemas/TaskAssignRequestTypeSelection" + $ref: "#/components/schemas/TaskAssignRequestType" + TaskAssignRequestType: + description: | + * `TaskAssignRequestTypeRandom`: タスクフェーズのみを指定してランダムにタスクを自身に割当します。プロジェクト設定でタスクのランダム割当を有効にした場合のみ利用できます。 + * `TaskAssignRequestTypeSelection`: 担当者とタスクを明示的に指定してタスクを割当します。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。プロジェクト設定でタスクの選択割当を有効にした場合のみ利用できます。 + oneOf: + - $ref: "#/components/schemas/TaskAssignRequestTypeRandom" + - $ref: "#/components/schemas/TaskAssignRequestTypeSelection" + discriminator: + propertyName: "_type" + mapping: + Random: "#/components/schemas/TaskAssignRequestTypeRandom" + Selection: "#/components/schemas/TaskAssignRequestTypeSelection" TaskAssignRequestTypeRandom: type: object required: - phase properties: phase: + $ref: "#/components/schemas/TaskPhase" description: 割当するタスクフェーズ。[詳細はこちら](#section/TaskPhase) - allOf: - - $ref: "#/components/schemas/TaskPhase" _type: type: string description: Random @@ -2603,9 +2419,8 @@ - task_ids properties: user_id: + $ref: "#/components/schemas/UserId" description: タスクを誰に割当するか - allOf: - - $ref: "#/components/schemas/UserId" task_ids: description: 割当するタスクのID type: array @@ -2761,12 +2576,12 @@ type: string description: | 入力データを取得するためのhttpsスキーマのURLです。 - + このURLはセキュリティのために認証認可が必要となっており、URLだけでは入力データを参照できません。 このURLは内部用であり、常に変更になる可能性があります。そのため、アクセスは保証外となります。 また、このURLのレスポンスは最低1時間キャッシュされます。 キャッシュを無効にしたい場合は、クエリパラメータにアクセス毎にランダムなUUIDなどを付与してください。 - + 設定の不備等でデータが取得できない場合、この属性は設定されません。 etag: type: string @@ -2777,22 +2592,23 @@ AF外部のストレージから登録された場合、その外部ストレージ中のパス。 それ以外の場合は値なし original_resolution: - allOf: - - $ref: "#/components/schemas/Resolution" - - description: | - 入力データの元画像サイズ。 - 入力データ登録時に画像がリサイズされた場合のみ設定される。 + deprecated: true + $ref: "#/components/schemas/Resolution" + description: | + 入力データの元画像サイズ。 + 入力データ登録時に画像がリサイズされた場合のみ設定される。 resized_resolution: - allOf: - - $ref: "#/components/schemas/Resolution" - - description: | - 入力データのリサイズ後サイズ。 - 入力データ登録時に画像がリサイズされた場合のみ設定される。 + deprecated: true + $ref: "#/components/schemas/Resolution" + description: | + 入力データのリサイズ後サイズ。 + 入力データ登録時に画像がリサイズされた場合のみ設定される。 input_duration: + deprecated: true type: number description: | 入力データが動画の場合、動画の長さ(秒)。小数点以下はミリ秒以下を表します。 - + 動画の長さが取得できなかった場合、あるいは入力データが画像の場合は値なし。 updated_datetime: type: string @@ -2807,6 +2623,74 @@ ユーザーが自由に登録できるkey-value型のメタデータです。主にカスタムエディタで使われることを想定しています。 additionalProperties: type: string + system_metadata: + $ref: "#/components/schemas/SystemMetadata" + SystemMetadata: + oneOf: + - $ref: "#/components/schemas/SystemMetadataImage" + - $ref: "#/components/schemas/SystemMetadataMovie" + - $ref: "#/components/schemas/SystemMetadataCustom" + discriminator: + propertyName: "_type" + mapping: + Image: "#/components/schemas/SystemMetadataImage" + Movie: "#/components/schemas/SystemMetadataMovie" + Custom: "#/components/schemas/SystemMetadataCustom" + description: | + * `SystemMetadataImage`: 画像プロジェクトの場合。画像データ固有のメタデータが保存されます。 + * `SystemMetadataMovie`: 動画プロジェクトの場合。動画データ固有のメタデータが保存されます。 + * `SystemMetadataCustom`: カスタムプロジェクトの場合。カスタムデータ固有のメタデータが保存されます。 + + `metadata` プロパティとは違い、ユーザー側では値を編集できない読取専用のプロパティです。 + SystemMetadataImage: + type: object + required: + - _type + description: | + 画像データ用システムメタデータ。 + properties: + original_resolution: + $ref: "#/components/schemas/Resolution" + description: | + 入力データの元画像サイズ。 + 入力データ登録時に画像がリサイズされた場合のみ設定される。 + resized_resolution: + $ref: "#/components/schemas/Resolution" + description: | + 入力データのリサイズ後サイズ。 + 入力データ登録時に画像がリサイズされた場合のみ設定される。 + _type: + type: string + description: "`Image`" + example: Image + SystemMetadataMovie: + type: object + required: + - _type + description: | + 動画データ用システムメタデータ。 + properties: + input_duration: + type: number + description: | + 入力データが動画の場合、動画の長さ(秒)。小数点以下はミリ秒以下を表します。 + 動画の長さが取得できなかった場合は値なし。 + _type: + type: string + description: "`Movie`" + example: Movie + SystemMetadataCustom: + type: object + required: + - _type + description: | + カスタムデータ用システムメタデータ。 + 現行はプロパティがない形式的なオブジェクトです。 + properties: + _type: + type: string + description: "`Custom`" + example: Custom InputDataRequest: type: object required: @@ -2821,11 +2705,11 @@ example: "s3://YOUR-BUCKET/PATH/TO/OBJECT" description: | AnnoFabに登録する入力データの実体が保存されたパスです。 - + 対応スキーマ: * s3 * https - + 場面別の使い分け: * [一時データ保存先取得API](#operation/createTempPath)を使ってAFにアップロードした場合: `s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA` * [プライベートストレージ](/docs/faq/#prst9c)の場合 @@ -2891,6 +2775,7 @@ enum: - image - text + - custom SupplementaryDataRequest: type: object required: @@ -2907,9 +2792,9 @@ example: "s3://YOUR-BUCKET/PATH/TO/OBJECT" description: | AnnoFabに登録する補助情報の実体が保存されたパスです。 - + 対応スキーマ:s3, https - + * [一時データ保存先取得API](#operation/createTempPath)を使ってAFにアップロードしたファイルパスの場合 * `s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA` * 補助情報作成/更新API成功時、アップロードしたファイルが一時データ保存先からコピーされます。 @@ -2924,7 +2809,7 @@ * AFにファイルはコピーされません。 supplementary_data_type: $ref: "#/components/schemas/SupplementaryDataType" - + supplementary_data_number: type: integer description: 表示順を表す数値(昇順)。同じ入力データに対して複数の補助情報で表示順が重複する場合、順序不定になります。 @@ -3051,6 +2936,16 @@ type: array items: $ref: "#/components/schemas/AdditionalData" + updated_from: + description: | + 開始日・終了日を含む区間[updated_from, updated_to]でアノテーションの更新日を絞り込むときに使用する、開始日。updated_toより後ろに指定された場合、期間指定は開始日・終了日を含む区間[updated_to, updated_from]となる。未指定の場合、本日であるとして扱われる。 + type: string + example: "20191010" + updated_to: + description: | + 開始日・終了日を含む区間[updated_from, updated_to]でアノテーションの更新日を絞り込むときに使用する、終了日。未指定の場合、本日であるとして扱われる。 + type: string + example: "20191010" Annotation: type: object required: @@ -3093,13 +2988,11 @@ annotation_id: $ref: "#/components/schemas/AnnotationId" account_id: + $ref: "#/components/schemas/AccountId" description: アノテーションを作成したユーザのアカウントID。 - allOf: - - $ref: "#/components/schemas/AccountId" label_id: + $ref: "#/components/schemas/LabelId" description: ラベルID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 - allOf: - - $ref: "#/components/schemas/LabelId" is_protected: description: | `true`の場合、アノテーションをアノテーションエディタ上での削除から保護できます。 @@ -3109,34 +3002,18 @@ data_holding_type: $ref: "#/components/schemas/AnnotationDataHoldingType" data: - oneOf: - - type: string - - $ref: "#/components/schemas/FullAnnotationData" - description: | - アノテーションの座標値や区間などのデータ。レスポンスの場合は`string`形式、[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は`string`または`object`形式です。 - `annotation_type`に応じて`string`,`object`の形式が変わります。 - - - - - - - - - - -
annotation_typedata_holding_typestring形式object形式
bounding_box inner左上x,左上y,右下x,右下yFullAnnotationDataBoundingBox
pointinnerx1,y1FullAnnotationDataSinglePoint
polygon / polyline innerx1,y1,x2,y2, ... FullAnnotationDataPoints
range inner開始時間(ミリ秒),終了時間(ミリ秒) FullAnnotationDataRange
classification innernull FullAnnotationDataClassification / null
segmentationouternull FullAnnotationDataSegmentation / null
segmentation_v2 outernull FullAnnotationDataSegmentationV2 / null
+ $ref: "#/components/schemas/AnnotationData" path: type: string description: | 外部ファイルに保存されたアノテーションのパス。`data_holding_type`が`inner`の場合は未指定です。 レスポンスの場合は`annotation_id`と同じ値が格納されます。 - + [putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は、[createTempPath](#operation/createTempPath) APIで取得できる一時データ保存先S3パスを格納してください。 更新しない場合は、[getEditorAnnotation](#operation/getEditorAnnotation) APIで取得した`path`をそのまま渡せます。 - + 外部ファイルのフォーマットは下表の通りです。 - + @@ -3153,7 +3030,7 @@ description: | 各要素は、 [アノテーション仕様](#operation/getAnnotationSpecs)で定義された属性(`additional_data_definitions`内)のいずれかの要素と対応づけます。 各要素は、どの属性なのかを表す`additional_data_definition_id`と値が必要です。値は、属性の種類に対応するキーに格納します(下表)。 - +
annotation_type形式
segmentation / segmentation_v2 PNG画像。塗りつぶした部分はrgba(255, 255, 255, 1) 、塗りつぶしていない部分はrgba(0, 0, 0, 0)
@@ -3176,9 +3053,8 @@ - additional_data_definition_id properties: additional_data_definition_id: + $ref: "#/components/schemas/AdditionalDataDefinitionId" description: 属性ID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 - allOf: - - $ref: "#/components/schemas/AdditionalDataDefinitionId" flag: type: boolean description: | @@ -3192,19 +3068,26 @@ description: | `additional_data_definition`の`type`が`text`,`comment`,`link` または `tracking`のときの属性値。 choice: + $ref: "#/components/schemas/ChoiceId" description: | `additional_data_definition`の`type`が`choice` または `select `のときの属性値(選択肢ID)。 - allOf: - - $ref: "#/components/schemas/ChoiceId" AdditionalDataValue: oneOf: - - type: object - $ref: "#/components/schemas/AdditionalDataValueFlag" - $ref: "#/components/schemas/AdditionalDataValueInteger" - $ref: "#/components/schemas/AdditionalDataValueComment" - $ref: "#/components/schemas/AdditionalDataValueChoice" - $ref: "#/components/schemas/AdditionalDataValueTracking" - $ref: "#/components/schemas/AdditionalDataValueLink" + discriminator: + propertyName: "_type" + mapping: + Flag: "#/components/schemas/AdditionalDataValueFlag" + Integer: "#/components/schemas/AdditionalDataValueInteger" + Comment: "#/components/schemas/AdditionalDataValueComment" + Choice: "#/components/schemas/AdditionalDataValueChoice" + Tracking: "#/components/schemas/AdditionalDataValueTracking" + Link: "#/components/schemas/AdditionalDataValueLink" AdditionalDataValueFlag: type: object required: @@ -3260,13 +3143,11 @@ - name properties: id: - allOf: - - $ref: "#/components/schemas/ChoiceId" - - description: 選択された選択肢のID + $ref: "#/components/schemas/ChoiceId" + description: 選択された選択肢のID name: - allOf: - - $ref: "#/components/schemas/InternationalizationMessage" - - description: 選択された選択肢の表示名 + $ref: "#/components/schemas/InternationalizationMessage" + description: 選択された選択肢の表示名 AdditionalDataValueTracking: type: object required: @@ -3527,9 +3408,35 @@ type: array items: $ref: "#/components/schemas/FullAnnotationAdditionalData" + AnnotationData: + description: | + アノテーションの座標値や区間などのデータ。 + `annotation_type` に応じて `string` や `object` の構造が変わります。 + + API レスポンスに使われる場合は常に `string` 形式です。 + [putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は `string` に加え、`object` 形式も使用できます。 + oneOf: + - $ref: "#/components/schemas/FullAnnotationDataString" + - $ref: "#/components/schemas/FullAnnotationData" + FullAnnotationDataString: + type: string + example: "1,1,5,5" + description: | + アノテーション座標値や区間などの文字列表現です。 + アノテーション種類(`annotation_type`)とデータ格納形式(`data_holding_type`)に応じて、以下のとおり表現が変わります。 + +
アノテーション属性の種類
additional_data_definitiontype
属性の値を格納するキーデータ型
text, comment または trackingcommentstring
+ + + + + + + + +
annotation_typedata_holding_type文字列表現
bounding_boxinner"左上x,左上y,右下x,右下y"
pointinner"x1,y1"
polygon / polylineinner"x1,y1,x2,y2, ... "
range inner"開始時間(ミリ秒),終了時間(ミリ秒) "
classificationinnernull
segmentationouternull
segmentation_v2outernull
FullAnnotationData: oneOf: - - type: object - $ref: "#/components/schemas/FullAnnotationDataClassification" - $ref: "#/components/schemas/FullAnnotationDataSegmentation" - $ref: "#/components/schemas/FullAnnotationDataSegmentationV2" @@ -3538,6 +3445,17 @@ - $ref: "#/components/schemas/FullAnnotationDataSinglePoint" - $ref: "#/components/schemas/FullAnnotationDataRange" - $ref: "#/components/schemas/FullAnnotationDataUnknown" + discriminator: + propertyName: "_type" + mapping: + Classification: "#/components/schemas/FullAnnotationDataClassification" + Segmentation: "#/components/schemas/FullAnnotationDataSegmentation" + SegmentationV2: "#/components/schemas/FullAnnotationDataSegmentationV2" + BoundingBox: "#/components/schemas/FullAnnotationDataBoundingBox" + Points: "#/components/schemas/FullAnnotationDataPoints" + SinglePoint: "#/components/schemas/FullAnnotationDataSinglePoint" + Range: "#/components/schemas/FullAnnotationDataRange" + Unknown: "#/components/schemas/FullAnnotationDataUnknown" description: | アノテーションのデータが格納されます。 * `FullAnnotationDataClassification`: 入力データ全体に対するアノテーションデータです。 @@ -3549,6 +3467,7 @@ * `FullAnnotationDataRange`: 動画区間のアノテーションデータです。 FullAnnotationDataClassification: type: object + nullable: true required: - _type properties: @@ -3559,6 +3478,7 @@ FullAnnotationDataSegmentation: description: 塗っていないところは rgba(0,0,0,0)、塗ったところは rgba(255,255,255,1) の PNGデータをBase64エンコードしたもの。 type: object + nullable: true required: - data_uri - _type @@ -3571,6 +3491,7 @@ example: "Segmentation" FullAnnotationDataSegmentationV2: type: object + nullable: true required: - data_uri - _type @@ -3600,7 +3521,7 @@ FullAnnotationDataPoints: description: | 頂点座標 {"x":int, "y":int} の配列。 - + * annotation_type が polygon/polyline の場合: ポリゴン/ポリラインを構成する頂点の配列。 type: object required: @@ -3674,13 +3595,11 @@ type: object properties: additional_data_definition_id: - allOf: - - $ref: "#/components/schemas/AdditionalDataDefinitionId" - - description: 属性ID + $ref: "#/components/schemas/AdditionalDataDefinitionId" + description: 属性ID additional_data_definition_name: - allOf: - - $ref: "#/components/schemas/InternationalizationMessage" - - description: 属性表示名 + $ref: "#/components/schemas/InternationalizationMessage" + description: 属性表示名 type: $ref: "#/components/schemas/AdditionalDataDefinitionType" value: @@ -3747,40 +3666,27 @@ inspection_id: $ref: "#/components/schemas/InspectionId" phase: + $ref: "#/components/schemas/TaskPhase" description: 検査コメントを付与したときのタスクフェーズ。[詳細はこちら](#section/TaskPhase) - allOf: - - $ref: "#/components/schemas/TaskPhase" phase_stage: type: integer description: 検査コメントを付与したときのフェーズのステージ default: 1 minimum: 1 commenter_account_id: - allOf: - - $ref: "#/components/schemas/AccountId" + $ref: "#/components/schemas/AccountId" description: 検査コメントを付与したユーザのアカウントID annotation_id: + $ref: "#/components/schemas/AnnotationId" description: | 検査コメントに紐づくアノテーションのID。アノテーションに紐付けられていない場合(アノテーションの付け忘れに対する指定など)は未指定。 [詳細はこちら](#section/AnnotationId)。 - allOf: - - $ref: "#/components/schemas/AnnotationId" data: - description: | - 検査コメントの座標値や区間。 - - * `InspectionDataPoint`:点で検査コメントを付与したときの座標値 - * `InspectionDataPolyline`:ポリラインで検査コメントを付与したときの座標値 - * `InspectionDataTime`:検査コメントを付与した区間(動画プロジェクトの場合) - oneOf: - - $ref: "#/components/schemas/InspectionDataPoint" - - $ref: "#/components/schemas/InspectionDataPolyline" - - $ref: "#/components/schemas/InspectionDataTime" + $ref: "#/components/schemas/InspectionData" parent_inspection_id: + $ref: "#/components/schemas/InspectionId" description: | 返信先の検査コメントの検査ID。返信先の検査コメントは「スレッド内の直前のコメント」ではなく「スレッドの先頭のコメント」を指します。 - allOf: - - $ref: "#/components/schemas/InspectionId" phrases: type: array description: 参照している定型指摘のID。 @@ -3799,6 +3705,26 @@ updated_datetime: type: string format: date-time + InspectionData: + description: | + 検査コメントの座標値や区間。 + + * `InspectionDataPoint`:点で検査コメントを付与したときの座標値 + * `InspectionDataPolyline`:ポリラインで検査コメントを付与したときの座標値 + * `InspectionDataTime`:検査コメントを付与した区間(動画プロジェクトの場合) + * `InspectionDataCustom`:カスタム + oneOf: + - $ref: "#/components/schemas/InspectionDataPoint" + - $ref: "#/components/schemas/InspectionDataPolyline" + - $ref: "#/components/schemas/InspectionDataTime" + - $ref: "#/components/schemas/InspectionDataCustom" + discriminator: + propertyName: "_type" + mapping: + Point: "#/components/schemas/InspectionDataPoint" + Polyline: "#/components/schemas/InspectionDataPolyline" + Time: "#/components/schemas/InspectionDataTime" + Custom: "#/components/schemas/InspectionDataCustom" InspectionDataPoint: type: object description: | @@ -3861,6 +3787,17 @@ `Time` [詳しくはこちら](#section/API-Convention/API-_type) example: "Time" + InspectionDataCustom: + type: object + properties: + data: + type: string + _type: + type: string + description: | + `Custom` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Custom" Resolution: type: object required: @@ -3885,7 +3822,6 @@ * `no_comment_inspection` - 作成途中。検査コメントの中身が未入力 AggregationResult: oneOf: - - type: object - $ref: "#/components/schemas/CountResult" CountResult: type: object @@ -3894,26 +3830,43 @@ type: string example: "CountResult" description: | - 他と区別するために `CountResult` を指定します + `CountResult` + [詳しくはこちら](#section/API-Convention/API-_type) name: type: string + description: | + 複数の集約を区別するための名前です。 + + `(フィールド名)_(集約内容)` のように命名されます。例えば `account_id` フィールドを `count` する場合、`account_id_count` となります。 field: type: string + description: | + 集約に使われたリソースのフィールド名です。 + + リソースの属性のさらに属性を参照するときは、`foo.bar.buz` のようにドット区切りになります。 items: type: array items: $ref: "#/components/schemas/Count" + description: | + 集約結果の値です。 Count: type: object properties: key: type: string + description: | + 集約対象の `field` の値です。 count: type: integer + description: | + 集約対象 `field` の値が `key` の値と等しかったリソースの件数です。 aggregations: type: array items: $ref: "#/components/schemas/AggregationResult" + description: | + この集約のサブ集約です。サブ集約がないときは空の配列になります。 Instruction: type: object properties: @@ -3970,7 +3923,6 @@ type: string ValidationError: oneOf: - - type: object - $ref: "#/components/schemas/InvalidAnnotationData" - $ref: "#/components/schemas/DuplicatedSegmentationV2" - $ref: "#/components/schemas/InvalidCommentFormat" @@ -3981,6 +3933,19 @@ - $ref: "#/components/schemas/UnknownAdditionalData" - $ref: "#/components/schemas/OutOfImageBounds" - $ref: "#/components/schemas/UnknownLabel" + discriminator: + propertyName: "_type" + mapping: + InvalidAnnotationData: "#/components/schemas/InvalidAnnotationData" + DuplicatedSegmentationV2: "#/components/schemas/DuplicatedSegmentationV2" + InvalidCommentFormat: "#/components/schemas/InvalidCommentFormat" + UnknownLinkTarget: "#/components/schemas/UnknownLinkTarget" + InvalidLinkTarget: "#/components/schemas/InvalidLinkTarget" + EmptyAttribute: "#/components/schemas/EmptyAttribute" + Duplicated: "#/components/schemas/Duplicated" + UnknownAdditionalData: "#/components/schemas/UnknownAdditionalData" + OutOfImageBounds: "#/components/schemas/OutOfImageBounds" + UnknownLabel: "#/components/schemas/UnknownLabel" InvalidAnnotationData: type: object description: アノテーションデータ不正エラー @@ -4132,3 +4097,312 @@ count: description: 該当するタスクの数 type: number + TemporaryUrl: + type: object + description: 認証済み一時URL + properties: + url: + type: string + description: 認証済み一時URL + AnnotationList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/SingleAnnotation" + description: 現在のページ番号に含まれる0件以上のアノテーションです。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるアノテーションが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + InputDataList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/InputData" + description: 現在のページ番号に含まれる0件以上の入力データです。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる入力データが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + JobInfoContainer: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/JobInfo" + has_next: + type: boolean + MyOrganizationList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/MyOrganization" + description: 現在のページ番号に含まれる0件以上の所属組織です。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる所属組織が0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + ProjectList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/Project" + description: 現在のページ番号に含まれる0件以上のプロジェクトです。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + OrganizationMemberList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/OrganizationMember" + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる組織メンバーが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + OrganizationPluginList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/OrganizationPlugin" + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + ProjectMemberList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/ProjectMember" + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトメンバーが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + ProjectContainer: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/Project" + has_next: + type: boolean + TaskList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/Task" + description: 現在のページ番号に含まれる0件以上のタスクです。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるタスク0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + BatchAnnotationRequestItem: + oneOf: + - $ref: "#/components/schemas/BatchAnnotationRequestItemPut" + - $ref: "#/components/schemas/BatchAnnotationRequestItemDelete" + discriminator: + propertyName: "_type" + mapping: + Put: "#/components/schemas/BatchAnnotationRequestItemPut" + Delete: "#/components/schemas/BatchAnnotationRequestItemDelete" + BatchInspectionRequestItem: + oneOf: + - $ref: "#/components/schemas/BatchInspectionRequestItemPut" + - $ref: "#/components/schemas/BatchInspectionRequestItemDelete" + discriminator: + propertyName: "_type" + mapping: + Put: "#/components/schemas/BatchInspectionRequestItemPut" + Delete: "#/components/schemas/BatchInspectionRequestItemDelete" + BatchInputDataRequestItem: + oneOf: + - $ref: "#/components/schemas/BatchInputDataRequestItemDelete" + discriminator: + propertyName: "_type" + mapping: + Delete: "#/components/schemas/BatchInputDataRequestItemDelete" + BatchTaskRequestItem: + oneOf: + - $ref: "#/components/schemas/BatchTaskRequestItemDelete" + discriminator: + propertyName: "_type" + mapping: + Delete: "#/components/schemas/BatchTaskRequestItemDelete" + AdditionalDataDefaultType: + oneOf: + - type: boolean + - type: integer + - type: string + description: | + 属性の初期値です。 + + 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 + + * type が flag の場合: 真偽値(`true` or `false`) + * type が integer の場合: 整数値 + * type が text の場合: 文字列 + * type が comment の場合: 文字列 + * type が choice の場合: 選択肢(`choices`)の `choice_id` + * type が select の場合: 選択肢(`choices`)の `choice_id` + + 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 + + なお、トラッキングとリンクには初期値を設定できません。 + DeleteProjectResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Project" + - $ref: "#/components/schemas/DeleteProjectResponse" + ProjectCopyResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Project" + - $ref: "#/components/schemas/ProjectCopyResponse" + PostProjectTasksUpdateResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Message" + - $ref: "#/components/schemas/PostProjectTasksUpdateResponse" + PutProjectResponseWrapper: + oneOf: + - $ref: "swagger-api-components.yaml#/components/schemas/Project" + - $ref: "swagger-api-components.yaml#/components/schemas/PutProjectResponse" + AnnotationSpecs: + oneOf: + - $ref: "#/components/schemas/AnnotationSpecsV1" + - $ref: "#/components/schemas/AnnotationSpecsV2" + AnnotationSpecsRequest: + oneOf: + - $ref: "#/components/schemas/AnnotationSpecsRequestV1" + - $ref: "#/components/schemas/AnnotationSpecsRequestV2" + TaskGenerateResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Project" + - $ref: "#/components/schemas/TaskGenerateResponse" + PostAnnotationArchiveUpdateResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Message" + - $ref: "#/components/schemas/PostAnnotationArchiveUpdateResponse" + MessageOrJobInfo: + oneOf: + - $ref: "#/components/schemas/Message" + - $ref: "#/components/schemas/JobInfo" diff --git a/generate/swagger/swagger.v2.yaml b/generate/swagger/swagger.v2.yaml index 7ad27fed..ccad78e9 100644 --- a/generate/swagger/swagger.v2.yaml +++ b/generate/swagger/swagger.v2.yaml @@ -1,60 +1,39 @@ -openapi: 3.0.0 +openapi: "3.0.0" info: - description: > + description: | [AnnoFab](https://annofab.com) のWeb API v2です。 - v2 はいくつかの主要なAPIでキャッシュが有効になり、日本を含む多くの国からのアクセスが大幅に高速化されます。 - [API v1はこちら](/docs/api/)です。 - APIベースURL: https://annofab.com/api/v2
- 例) /projects というAPIを使う場合、 https://annofab.com/api/v2/projects をリクエストします。 - ■APIの変更ポリシー
- **現在、APIは開発途上版です。予告なく互換性のない変更がある可能性をご了承ください。** - ご要望の実現、あるいは、セキュリティやパフォーマンスの改善などを実現するにあたり、互換性のない変更が必要になる場合があります。 - その場合、開発途上版では開発リソースを改善に集中するため、古いバージョンを共存させずに互換性のない変更を行う場合があります。 - ■機能の要望や不具合報告
- 「こんな機能が欲しい」というご要望や、「APIが予期せぬ動作をする」といった不具合報告などは、[こちらのお問い合わせフォーム](https://docs.google.com/forms/d/e/1FAIpQLSePryikS_wo_H11pxL2ewUe2d0ud0jxZlBQwH2rVVfcifKyQw/viewform)からご連絡ください。 - # API Client - APIクライアントも提供しています。 - * https://github.com/kurusugawa-computer/annofab-cli - * https://github.com/kurusugawa-computer/annofab-api-python-client - # API Convention - ## 用語 - * **属性○○○を必須**とは、「JSONに属性キー○○○を含め、かつ、その値が`null`以外」であること - * **属性○○○を未指定**とは、「JSONに属性キー○○○を含めない」または「属性○○○のキーはあるが値は`null`」のどちらかであること - ## 更新系APIのリクエストボディに必須の属性 - * 更新系APIとは、HTTPメソッドが **PUT** または **POST** のAPIです。 - * 更新系APIでは、更新対象の「リソースの最終更新日」を必須とする場合があります。 * これは、複数ユーザーからのAPIリクエストのデータ競合を避けるための、一般的なAPI設計慣習によるものです。 * ここで「リソースの最終更新日」とは、`last_updated_datetime` または `updated_datetime` という名前の属性です。 @@ -66,23 +45,17 @@ info: * 更新しようとしたリソースが存在しないとき、またはすでに更新されているときは、更新リクエストは失敗します。 * 「リソースの最終更新日」以外の属性については、新規作成/更新それぞれで必須が異なる場合、API個別に特筆されています。 - ## APIのリクエストボディに指定する _type 属性について - * 一部のAPIではリクエストボディに `_type` 属性を任意で指定することができます。 - * `_type` 属性を指定する場合は、`_type` 属性で指定された型にデコードします。 例えば、`_type` 属性に `ByDirectory` を指定すると `TaskGenerateRuleByDirectory` にデコードされ、`Poliline` を指定すると `InspectionDataPolyline` にデコードされます。 リクエストボディが誤っている場合はエラーになります。 * `_type` 属性を指定しない場合は、リクエストボディで指定された `_type` 以外の属性からデコードすべき型を推論します。適切な型が見つからない場合はエラーになります。 - * `_type` 属性は「推論が失敗して別の型にデコードされる」ことを防ぐために指定することを推奨します。しかし利便性のため指定は必須ではありません。 - ## APIに指定するID/名前の制約 - * APIで使用する各データのIDに使用できる文字種は次の通りです。 * 半角英数字 * `_` (アンダースコア) @@ -92,82 +65,96 @@ info: * 例) `b048c6b3-b36f-4c8d-97ea-96828a50a44c` * 各データのIDは、以下のように特定のデータに対して一意な値である必要があります。 - ID/名前 | 一意制約 - ---|--- - 組織名 | AnnoFab内で一意 - 組織ID | AnnoFab内で一意 - ユーザID | AnnoFab内で一意 - アカウントID | AnnoFab内で一意 - プロジェクトID | AnnoFab内で一意 - タスクID(プレフィックス含む) | プロジェクト内で一意 - 入力データID | プロジェクト内で一意 - アノテーションID | フレーム内(タスクID、入力データIDの組み合わせ)で一意 - 検査ID | プロジェクト内で一意 - 補助情報ID | プロジェクト内で一意 - WebhookID | プロジェクト内で一意 - 作業ガイド画像ID | プロジェクト内で一意 - ラベルID | プロジェクト内で一意 - 属性ID | プロジェクト内で一意 - 選択肢ID | 属性内で一意 - ジョブID | プロジェクト内で一意 - 入力データセットID | 組織内で一意 - プラグインID | 組織内で一意 - version: 0.88.0 + + + ## 検索結果の集約を表す AggregationResult + + いくつかの検索系 API の検索結果レスポンスは、`AggregationResult` というデータ構造のフィールドを持っています。 + `AggergationResult` は、検索対象リソースをある観点で集約した結果を表します。 + このような集約は、「検索結果を属性 XXX の件数別に分類」などするために使われます。 + + 例えば、タスクを検索する API には、以下のような「タスクの現在担当者での集約 `account_id_count`」などの `AggregationResult` がいくつか含まれています。 + + ```json + { + "list": [ ... ], + "aggregations": [ + { + "_type": "CountResult", + "name": "account_id_count", + "field": "account_id", + "items": [ + {"key":"c5eee002", "count":9, "aggregations":[], "_type":"..."}, + {"key":"9f110e48", "count":5, "aggregations":[], "_type":"..."}, + {"key":"b25dfeb3", "count":1, "aggregations":[], "_type":"..."} + ] + } + ] + } + ``` + + 上記例 `account_id_count` は、タスクのフィールド `account_id` でタスクを分類したところ「`account_id` が `c5eee002` であるタスクが9件、`9f110e48` であるタスクが5件、`b25dfeb3` であるタスクが1件」だったという結果を表しています。 + + version: 0.89.3 title: AnnoFab Web API x-logo: - url: https://annofab.com/images/logo_landscape.png - href: https://annofab.com/ + url: "https://annofab.com/images/logo_landscape.png" + href: "https://annofab.com/" contact: - url: https://annofab.com/docs/forms/trouble-shooting.html + url: "https://annofab.com/docs/forms/trouble-shooting.html" servers: - - url: https://annofab.com/api/v2 +- url: https://annofab.com/api/v2 tags: - - name: af-annotation-specs-v2 - x-displayName: Annotation Specs - description: アノテーション仕様に対する操作 - - name: af-cache-v2 - x-displayName: Cache - description: キャッシュに関係 - - name: af-organization-v2 - x-displayName: Organization - description: 組織に対する操作 - - name: af-project-member-v2 - x-displayName: Project Member - description: プロジェクトメンバーに対する操作 - - name: af-project-v2 - x-displayName: Project - description: プロジェクトに対する操作 - - name: af-statistics-v2 - x-displayName: Statistics - description: 統計 - - name: af-users-v2 - x-displayName: Users - description: 個人データ +- name: af-annotation-specs-v2 + x-displayName: Annotation Specs + description: アノテーション仕様に対する操作 +- name: af-cache-v2 + x-displayName: Cache + description: キャッシュに関係 +- name: af-organization-member-v2 + x-displayName: Organization Member + description: 組織メンバーに対する操作 +- name: af-organization-v2 + x-displayName: Organization + description: 組織に対する操作 +- name: af-project-member-v2 + x-displayName: Project Member + description: プロジェクトメンバーに対する操作 +- name: af-project-v2 + x-displayName: Project + description: プロジェクトに対する操作 +- name: af-statistics-v2 + x-displayName: Statistics + description: 統計 +- name: af-users-v2 + x-displayName: Users + description: 個人データ x-tagGroups: - name: API tags: - af-annotation-specs-v2 - af-cache-v2 + - af-organization-member-v2 - af-organization-v2 - af-project-member-v2 - af-project-v2 @@ -176,52 +163,52 @@ x-tagGroups: components: securitySchemes: SignedCookieKeyPairId: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/SignedCookieKeyPairId + $ref: "swagger-api-components.yaml#/components/securitySchemes/SignedCookieKeyPairId" SignedCookiePolicy: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/SignedCookiePolicy + $ref: "swagger-api-components.yaml#/components/securitySchemes/SignedCookiePolicy" SignedCookieSignature: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/SignedCookieSignature + $ref: "swagger-api-components.yaml#/components/securitySchemes/SignedCookieSignature" EveryoneRequestBody: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/EveryoneRequestBody + $ref: "swagger-api-components.yaml#/components/securitySchemes/EveryoneRequestBody" EveryoneQueryParameter: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/EveryoneQueryParameter + $ref: "swagger-api-components.yaml#/components/securitySchemes/EveryoneQueryParameter" Everyone: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/Everyone + $ref: "swagger-api-components.yaml#/components/securitySchemes/Everyone" AnnoFabAdminOnly: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AnnoFabAdminOnly + $ref: "swagger-api-components.yaml#/components/securitySchemes/AnnoFabAdminOnly" AllProjectMember: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AllProjectMember + $ref: "swagger-api-components.yaml#/components/securitySchemes/AllProjectMember" ProjectAccepter: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectAccepter + $ref: "swagger-api-components.yaml#/components/securitySchemes/ProjectAccepter" ProjectDataUser: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectDataUser + $ref: "swagger-api-components.yaml#/components/securitySchemes/ProjectDataUser" ProjectAccepterOrDataUser: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectAccepterOrDataUser + $ref: "swagger-api-components.yaml#/components/securitySchemes/ProjectAccepterOrDataUser" ProjectOwner: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectOwner + $ref: "swagger-api-components.yaml#/components/securitySchemes/ProjectOwner" AllOrganizationMember: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AllOrganizationMember + $ref: "swagger-api-components.yaml#/components/securitySchemes/AllOrganizationMember" OrganizationAdministrator: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/OrganizationAdministrator + $ref: "swagger-api-components.yaml#/components/securitySchemes/OrganizationAdministrator" OrganizationOwner: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/OrganizationOwner + $ref: "swagger-api-components.yaml#/components/securitySchemes/OrganizationOwner" paths: /sign-url: get: tags: - - af-cache-v2 + - af-cache-v2 summary: V2系APIへのアクセスに必要なSigned Cookieを発行します security: - - Everyone: [] + - Everyone: [] operationId: getSignedAccessV2 parameters: - - name: url - in: query - description: | - アクセスしたいページのアドレス(クエリパラメータ含み) - schema: - type: string - example: /api/v2/projects/{project_id}/statistics/inspections + - name: url + in: query + description: | + アクセスしたいページのアドレス(クエリパラメータ含み) + schema: + type: string + example: "/api/v2/projects/{project_id}/statistics/inspections" responses: "200": description: 正常 @@ -229,21 +216,18 @@ paths: Set-Cookie: schema: type: string - description: 署名付きCookieが発行されます。発行されるCookieの詳細は [こちら](#section/Authentication) - を参照ください。 - example: CloudFront-Key-Pair-Id=XXXXYYYZZZZ; - Path=/api/v2/projects/xxxx-xxxx-xxx; max-age=84600; HttpOnly; - SameSite=Strict; Secure + description: 署名付きCookieが発行されます。発行されるCookieの詳細は [こちら](#section/Authentication) を参照ください。 + example: CloudFront-Key-Pair-Id=XXXXYYYZZZZ; Path=/api/v2/projects/xxxx-xxxx-xxx; max-age=84600; HttpOnly; SameSite=Strict; Secure "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/cache": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/cache: get: tags: - - af-project-v2 + - af-project-v2 summary: キャッシュレコード security: - SignedCookieKeyPairId: [] @@ -251,29 +235,29 @@ paths: SignedCookieSignature: [] operationId: getProjectCacheV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectCacheRecord + $ref: "swagger-api-components.yaml#/components/schemas/ProjectCacheRecord" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/members": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/members: get: tags: - - af-project-member-v2 + - af-project-member-v2 summary: プロジェクトメンバー一括取得 security: - SignedCookieKeyPairId: [] @@ -281,71 +265,70 @@ paths: SignedCookieSignature: [] operationId: getProjectMembersV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: include_inactive_member - in: query - description: 脱退したプロジェクトメンバーも取得する時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: include_inactive_member + in: query + description: 脱退したプロジェクトメンバーも取得する時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMemberList + $ref: "swagger-api-components.yaml#/components/schemas/ProjectMemberList" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/members/{user_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/members/{user_id}: get: tags: - - af-project-member-v2 + - af-project-member-v2 summary: プロジェクトメンバー取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getProjectMemberV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: user_id - in: path - description: アカウントのユーザID. - RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: user_id + in: path + description: アカウントのユーザID. RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/UserId" + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: "200": description: 正常 @@ -354,39 +337,39 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + $ref: "swagger-api-components.yaml#/components/schemas/ProjectMember" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/tasks": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/tasks: get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: タスク集計取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getTaskStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: "200": description: 正常 @@ -395,39 +378,39 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectTaskStatisticsHistory + $ref: "swagger-api-components.yaml#/components/schemas/ProjectTaskStatisticsHistory" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/accounts": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/accounts: get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: ユーザー別タスク集計取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getAccountStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: "200": description: 正常 @@ -436,39 +419,39 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectAccountStatistics + $ref: "swagger-api-components.yaml#/components/schemas/ProjectAccountStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/inspections": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/inspections: get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: 検査コメント集計取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getInspectionStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: "200": description: 正常 @@ -477,39 +460,39 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InspectionStatistics + $ref: "swagger-api-components.yaml#/components/schemas/InspectionStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/task-phases": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/task-phases: get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: フェーズ別タスク集計取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getTaskPhaseStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: "200": description: 正常 @@ -518,39 +501,39 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhaseStatistics + $ref: "swagger-api-components.yaml#/components/schemas/TaskPhaseStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/labels": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/labels: get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: ラベル別アノテーション数集計取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] operationId: getLabelStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: "200": description: 正常 @@ -559,17 +542,17 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/LabelStatistics + $ref: "swagger-api-components.yaml#/components/schemas/LabelStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/worktimes": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/worktimes: get: tags: - - af-statistics-v2 + - af-statistics-v2 summary: タスク作業時間集計取得 description: | ヒストグラムは最終日のby_tasks、by_inputsでのみ返却する。 @@ -580,20 +563,20 @@ paths: SignedCookieSignature: [] operationId: getWorktimeStatisticsV2 parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: cache - in: query - description: | - CACHE TIMESTAMP - required: false - schema: - type: string - example: "123456789" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" responses: "200": description: 正常 @@ -602,19 +585,19 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/WorktimeStatistics + $ref: "swagger-api-components.yaml#/components/schemas/WorktimeStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/annotation-specs": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/annotation-specs: get: tags: - af-annotation-specs-v2 summary: アノテーション仕様取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -626,7 +609,7 @@ paths: description: プロジェクトID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" - name: cache in: query description: | @@ -637,10 +620,8 @@ paths: example: "123456789" - name: history_id in: query - description: > - 過去のアノテーション仕様を取得する場合、[アノテーション仕様履歴取得](#operation/getAnnotationSpecsHistories)APIで取得した - `history_id` の値を指定します。 - + description: | + 過去のアノテーション仕様を取得する場合、[アノテーション仕様履歴取得](#operation/getAnnotationSpecsHistories)APIで取得した `history_id` の値を指定します。 未指定時は最新のアノテーション仕様を取得します。 required: false schema: @@ -661,19 +642,19 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecs + $ref: "swagger-api-components.yaml#/components/schemas/AnnotationSpecs" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations-by-name/{organization_name}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations-by-name/{organization_name}: get: tags: - af-organization-v2 summary: 組織情報取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -685,7 +666,7 @@ paths: description: 組織名 required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationName" - name: cache in: query description: | @@ -700,19 +681,19 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + $ref: "swagger-api-components.yaml#/components/schemas/Organization" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations-by-name/{organization_name}/cache": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations-by-name/{organization_name}/cache: get: tags: - af-organization-v2 summary: キャッシュレコード - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -724,26 +705,26 @@ paths: description: 組織名 required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationName" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationCacheRecord + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationCacheRecord" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_id}: get: tags: - af-organization-v2 summary: 組織情報取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -755,7 +736,7 @@ paths: description: 組織ID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationId" - name: cache in: query description: | @@ -770,19 +751,19 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + $ref: "swagger-api-components.yaml#/components/schemas/Organization" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_id}/cache": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_id}/cache: get: tags: - af-organization-v2 summary: キャッシュレコード - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -794,63 +775,145 @@ paths: description: 組織ID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationCacheRecord + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationCacheRecord" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_id}/projects/{project_id}/task-counts": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_id}/members: get: tags: - - af-organization-v2 - summary: プロジェクトのタスク件数取得 - description: "" + - af-organization-member-v2 + summary: 組織メンバー一括取得 + description: | + 脱退したメンバーは含まれません。 security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] SignedCookieSignature: [] - operationId: getProjectTaskCountV2 + operationId: getOrganizationMembersV2 parameters: - name: organization_id in: path description: 組織ID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId - - name: project_id + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationId" + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" + responses: + 200: + description: 正常 + content: + application/json: + schema: + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationMemberList" + 401: + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" + 503: + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_id}/members/{user_id}: + get: + tags: + - af-organization-member-v2 + summary: 組織メンバー取得 + description: | + 指定したユーザーが指定した組織にどのようなロールで参加しているかを取得します。 + security: + - SignedCookieKeyPairId: [] + SignedCookiePolicy: [] + SignedCookieSignature: [] + operationId: getOrganizationMemberV2 + parameters: + - name: organization_id in: path - description: プロジェクトID + description: 組織ID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationId" + - name: user_id + in: path + description: ユーザID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/UserId" + - name: cache + in: query + description: | + CACHE TIMESTAMP + required: false + schema: + type: string + example: "123456789" + responses: + 200: + description: 正常 + content: + application/json: + schema: + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationMember" + 401: + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" + 503: + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_id}/projects/{project_id}/task-counts: + get: + tags: + - af-organization-v2 + summary: プロジェクトのタスク件数取得 + description: | + security: + - SignedCookieKeyPairId: [] + SignedCookiePolicy: [] + SignedCookieSignature: [] + operationId: getProjectTaskCountV2 + parameters: + - name: organization_id + in: path + description: 組織ID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationId" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectTaskCounts + $ref: "swagger-api-components.yaml#/components/schemas/ProjectTaskCounts" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/users/{account_id}/cache": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /users/{account_id}/cache: get: tags: - af-users-v2 summary: キャッシュレコード - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -862,26 +925,26 @@ paths: description: アカウントID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + $ref: "swagger-api-components.yaml#/components/schemas/AccountId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/UserCacheRecord + $ref: "swagger-api-components.yaml#/components/schemas/UserCacheRecord" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/users/{account_id}/project-members": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /users/{account_id}/project-members: get: tags: - af-users-v2 summary: 個人のプロジェクトメンバー情報一括取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -893,7 +956,7 @@ paths: description: アカウントID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + $ref: "swagger-api-components.yaml#/components/schemas/AccountId" - name: cache in: query description: | @@ -908,19 +971,19 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + $ref: "swagger-api-components.yaml#/components/schemas/ProjectMember" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/users/{account_id}/organizations": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /users/{account_id}/organizations: get: tags: - af-users-v2 summary: 個人の所属組織一括取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -932,7 +995,7 @@ paths: description: アカウントID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + $ref: "swagger-api-components.yaml#/components/schemas/AccountId" - name: cache in: query description: | @@ -947,19 +1010,19 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/MyOrganizationList + $ref: "swagger-api-components.yaml#/components/schemas/MyOrganizationList" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/users/{account_id}/projects": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /users/{account_id}/projects: get: tags: - af-users-v2 summary: 自分のプロジェクトメンバー情報一括取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -971,7 +1034,7 @@ paths: description: アカウントID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + $ref: "swagger-api-components.yaml#/components/schemas/AccountId" - name: page in: query description: | @@ -996,7 +1059,7 @@ paths: 指定した組織に属するプロジェクトに絞り込む。未指定時は全プロジェクト。 required: false schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationId" - name: title in: query description: | @@ -1010,14 +1073,14 @@ paths: 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 required: false schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectStatus + $ref: "swagger-api-components.yaml#/components/schemas/ProjectStatus" - name: input_data_type in: query description: | 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト required: false schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataType + $ref: "swagger-api-components.yaml#/components/schemas/InputDataType" - name: sort_by in: query description: | @@ -1041,19 +1104,19 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectContainer + $ref: "swagger-api-components.yaml#/components/schemas/ProjectContainer" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/users/{account_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /users/{account_id}: get: tags: - af-users-v2 summary: 個人情報取得 - description: "" + description: | security: - SignedCookieKeyPairId: [] SignedCookiePolicy: [] @@ -1065,7 +1128,7 @@ paths: description: アカウントID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId + $ref: "swagger-api-components.yaml#/components/schemas/AccountId" - name: cache in: query description: | @@ -1080,10 +1143,10 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/MyAccount + $ref: "swagger-api-components.yaml#/components/schemas/MyAccount" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" diff --git a/generate/swagger/swagger.yaml b/generate/swagger/swagger.yaml index 8cfad982..8fdd133d 100644 --- a/generate/swagger/swagger.yaml +++ b/generate/swagger/swagger.yaml @@ -1,58 +1,39 @@ -openapi: 3.0.0 + +openapi: "3.0.0" info: - description: > + description: | [AnnoFab](https://annofab.com) のWeb APIです。 - キャッシュが有効になって[大幅に高速化された v2 はこちら](/docs/api/v2) です。 - APIベースURL: https://annofab.com/api/v1
- 例) /projects というAPIを使う場合、 https://annofab.com/api/v1/projects をリクエストします。 - ■APIの変更ポリシー
- **現在、APIは開発途上版です。予告なく互換性のない変更がある可能性をご了承ください。** - ご要望の実現、あるいは、セキュリティやパフォーマンスの改善などを実現するにあたり、互換性のない変更が必要になる場合があります。 - その場合、開発途上版では開発リソースを改善に集中するため、古いバージョンを共存させずに互換性のない変更を行う場合があります。 - ■機能の要望や不具合報告
- 「こんな機能が欲しい」というご要望や、「APIが予期せぬ動作をする」といった不具合報告などは、[こちらのお問い合わせフォーム](https://docs.google.com/forms/d/e/1FAIpQLSePryikS_wo_H11pxL2ewUe2d0ud0jxZlBQwH2rVVfcifKyQw/viewform)からご連絡ください。 - # API Client - APIクライアントも提供しています。 - * https://github.com/kurusugawa-computer/annofab-cli - * https://github.com/kurusugawa-computer/annofab-api-python-client - # API Convention - ## 用語 - * **属性○○○を必須**とは、「JSONに属性キー○○○を含め、かつ、その値が`null`以外」であること - * **属性○○○を未指定**とは、「JSONに属性キー○○○を含めない」または「属性○○○のキーはあるが値は`null`」のどちらかであること - ## 更新系APIのリクエストボディに必須の属性 - * 更新系APIとは、HTTPメソッドが **PUT** または **POST** のAPIです。 - * 更新系APIでは、更新対象の「リソースの最終更新日」を必須とする場合があります。 * これは、複数ユーザーからのAPIリクエストのデータ競合を避けるための、一般的なAPI設計慣習によるものです。 * ここで「リソースの最終更新日」とは、`last_updated_datetime` または `updated_datetime` という名前の属性です。 @@ -64,23 +45,17 @@ info: * 更新しようとしたリソースが存在しないとき、またはすでに更新されているときは、更新リクエストは失敗します。 * 「リソースの最終更新日」以外の属性については、新規作成/更新それぞれで必須が異なる場合、API個別に特筆されています。 - ## APIのリクエストボディに指定する _type 属性について - * 一部のAPIではリクエストボディに `_type` 属性を任意で指定することができます。 - * `_type` 属性を指定する場合は、`_type` 属性で指定された型にデコードします。 例えば、`_type` 属性に `ByDirectory` を指定すると `TaskGenerateRuleByDirectory` にデコードされ、`Poliline` を指定すると `InspectionDataPolyline` にデコードされます。 リクエストボディが誤っている場合はエラーになります。 * `_type` 属性を指定しない場合は、リクエストボディで指定された `_type` 以外の属性からデコードすべき型を推論します。適切な型が見つからない場合はエラーになります。 - * `_type` 属性は「推論が失敗して別の型にデコードされる」ことを防ぐために指定することを推奨します。しかし、利便性のために一部APIを除き指定は必須ではありません。 - ## APIに指定するID/名前の制約 - * APIで使用する各データのIDに使用できる文字種は次の通りです。 * 半角英数字 * `_` (アンダースコア) @@ -90,267 +65,253 @@ info: * 例) `b048c6b3-b36f-4c8d-97ea-96828a50a44c` * 各データのIDは、以下のように特定のデータに対して一意な値である必要があります。 - ID/名前 | 一意制約 - ---|--- - 組織名 | AnnoFab内で一意 - 組織ID | AnnoFab内で一意 - ユーザID | AnnoFab内で一意 - アカウントID | AnnoFab内で一意 - プロジェクトID | AnnoFab内で一意 - タスクID(プレフィックス含む) | プロジェクト内で一意 - 入力データID | プロジェクト内で一意 - アノテーションID | フレーム内(タスクID、入力データIDの組み合わせ)で一意 - 検査ID | プロジェクト内で一意 - 補助情報ID | プロジェクト内で一意 - WebhookID | プロジェクト内で一意 - 作業ガイド画像ID | プロジェクト内で一意 - ラベルID | プロジェクト内で一意 - 属性ID | プロジェクト内で一意 - 選択肢ID | 属性内で一意 - ジョブID | プロジェクト内で一意 - 入力データセットID | 組織内で一意 - プラグインID | 組織内で一意 - version: 0.88.0 + + ## 検索結果の集約を表す AggregationResult + + いくつかの検索系 API の検索結果レスポンスは、`AggregationResult` というデータ構造のフィールドを持っています。 + `AggergationResult` は、検索対象リソースをある観点で集約した結果を表します。 + このような集約は、「検索結果を属性 XXX の件数別に分類」などするために使われます。 + + 例えば、タスクを検索する API には、以下のような「タスクの現在担当者での集約 `account_id_count`」などの `AggregationResult` がいくつか含まれています。 + + ```json + { + "list": [ ... ], + "aggregations": [ + { + "_type": "CountResult", + "name": "account_id_count", + "field": "account_id", + "items": [ + {"key":"c5eee002", "count":9, "aggregations":[], "_type":"..."}, + {"key":"9f110e48", "count":5, "aggregations":[], "_type":"..."}, + {"key":"b25dfeb3", "count":1, "aggregations":[], "_type":"..."} + ] + } + ] + } + ``` + + 上記例 `account_id_count` は、タスクのフィールド `account_id` でタスクを分類したところ「`account_id` が `c5eee002` であるタスクが9件、`9f110e48` であるタスクが5件、`b25dfeb3` であるタスクが1件」だったという結果を表しています。 + + version: 0.89.3 title: AnnoFab Web API x-logo: - url: https://annofab.com/images/logo_landscape.png - href: https://annofab.com/ + url: "https://annofab.com/images/logo_landscape.png" + href: "https://annofab.com/" contact: - url: https://annofab.com/docs/forms/trouble-shooting.html + url: "https://annofab.com/docs/forms/trouble-shooting.html" servers: - - url: https://annofab.com/api/v1 +- url: https://annofab.com/api/v1 tags: - - name: af-account - x-displayName: Account - description: ユーザーアカウントに対する操作 - - name: af-annotation - x-displayName: Annotation - description: アノテーションに対する操作 - - name: af-annotation-specs - x-displayName: Annotation Specs - description: アノテーション仕様に対する操作 - - name: af-input - x-displayName: Input - description: | - **入力データ(input data)**に対する操作です。 - - 入力データとは、アノテーションする対象となる画像、動画、CSVなどのファイル全般のことです。 - 入力データは、プロジェクトごとに作成されます。 - - すべてのAF利用プランで、入力データをAnnoFabにアップロードできます。 - AnnoFabにアップロードされた入力データは、AnnoFabからアノテーションツール上に配信されます。 - - ビジネスプランでは、入力データをお客様が管理される**プライベートストレージ**に置き、URLだけをAnnoFabに登録できます。 - プライベートストレージには、**httpsサーバーに対応したNAS**または**AWS S3**を利用できます。 - プライベートストレージに置かれた入力データは、AnnoFabのサーバーを経由せず、直接アノテーションツール上に配信されます。 - セキュリティ要件のためお客様の入力データを社外(AnnoFab含む)に非公開にしたい場合、プライベートストレージを利用することができます。 - また場合によっては、AnnoFabから入力データを配信するよりも配信速度が改善する場合があります。 - - 関連 - * [af-supplementary](#tag/af-supplementary): 入力データを補う補助情報 - - name: af-inspection - x-displayName: Inspection - description: 検査コメントに対する操作 - - name: af-instruction - x-displayName: Instruction - description: 作業ガイドに対する操作 - - name: af-job - x-displayName: Job - description: バッチ処理ジョブに対する操作 - - name: af-login - x-displayName: Login - description: ログイン関連の操作 - - name: af-my - x-displayName: My - description: 自身のリソースに対する操作 - - name: af-organization - x-displayName: Organization - description: 組織に対する操作 - - name: af-organization-member - x-displayName: Organization Member - description: 組織メンバーに対する操作 - - name: af-organization-plugin - x-displayName: Organization Plugin - description: | - 組織で使用するプラグインに対する操作 - - **このAPIは AnnoFab に許可された組織だけで使用できます。またアルファ版につき、予告なく変更されることがあります。** - - name: af-project - x-displayName: Project - description: プロジェクトに対する操作 - - name: af-project-member - x-displayName: Project Member - description: プロジェクトメンバーに対する操作 - - name: af-statistics - x-displayName: Statistics - description: 集計に関する操作 - - name: af-supplementary - x-displayName: Supplementary - description: | - **補助情報(supprementary data)**に対する操作です。 - - 補助情報とは、アノテーションする対象となる[入力データ](#tag/af-input)では*ありません*が、 - アノテーションするときに何らかの手がかりや文脈を与えるデータのことです。 - 例えば、次のようなものです。 - * 現在の写真に対する、過去の写真 - * 光学写真に対する、暗視写真 - * 前方を撮影した写真に対する、左側面・右側面・後方の写真 - * 写真や動画を撮影した日時、緯度経度、撮影者などのメタデータ(テキスト) - - 補助情報は、画像やテキストで、プロジェクトの入力データごとにひも付けられます。 - 補助情報で扱う画像は、入力データと同様にAnnoFabにアップロードする他に、プライベートストレージの画像を利用することもできます。 - - 関連 - * [af-input](#tag/af-input): 補助情報をひもづける入力データ - * [af-project](#tag/af-project): 補助情報をひもづけるプロジェクト - - name: af-task - x-displayName: Task - description: タスクに対する操作 - - name: af-webhook - x-displayName: Webhook - description: Webhookに対する操作 - - name: x-annotation-zip - x-displayName: Annotation ZIP - description: > - AnnoFabで作成したアノテーションは、元となった入力データ(画像や動画など)に対応する形で1ファイルのJSONとなります。 - - これらのJSONはZIP形式で圧縮され、一括で取得できます。 - - - AnnoFabから取得できるアノテーションの構造は、現在2種類あります。 - - - 1. Simple - * バウンディングボックスや属性など、いわゆるアノテーションにしぼった軽量な構造。 - * いかなるプロジェクトでも取得できます。 - * 推奨版です。 - * アノテーションZIPおよびアノテーション構造の詳細は、 [Simple Annotation ZIP](#section/Simple-Annotation-ZIP) を参照ください。 - 2. Full - * バウンディングボックスや属性に加え、アノテーションを作成したタスクに関する構造が含まれる重厚長大な構造。 - * Businessプラン組織のプロジェクトでのみ取得できます。 - * 非推奨版です。長期的には廃止予定なので、新規の使用は控え、Simpleへ移行してください。 - * アノテーションZIPおよびアノテーション構造の詳細は、 [Full Annotation ZIP](#section/Full-Annotation-ZIP) を参照ください。 - - アノテーションは、各プロジェクトのトップページでダウンロードできます。また、次のAPIを利用して取得することもできます。 - - - * Simple版アノテーションZIP取得API: [getAnnotationArchive](#operation/getAnnotationArchive) - - * Full版アノテーションZIP取得API: [getArchiveFullWithProId](#operation/getArchiveFullWithProId) - - - なお、アノテーションZIPは毎日AM 03:00 JSTごろに自動更新されます。 - - - ## Simple Annotation ZIP +- name: af-account + x-displayName: Account + description: ユーザーアカウントに対する操作 +- name: af-annotation + x-displayName: Annotation + description: アノテーションに対する操作 +- name: af-annotation-specs + x-displayName: Annotation Specs + description: アノテーション仕様に対する操作 +- name: af-input + x-displayName: Input + description: | + **入力データ(input data)**に対する操作です。 + + 入力データとは、アノテーションする対象となる画像、動画、CSVなどのファイル全般のことです。 + 入力データは、プロジェクトごとに作成されます。 + + すべてのAF利用プランで、入力データをAnnoFabにアップロードできます。 + AnnoFabにアップロードされた入力データは、AnnoFabからアノテーションツール上に配信されます。 + + ビジネスプランでは、入力データをお客様が管理される**プライベートストレージ**に置き、URLだけをAnnoFabに登録できます。 + プライベートストレージには、**httpsサーバーに対応したNAS**または**AWS S3**を利用できます。 + プライベートストレージに置かれた入力データは、AnnoFabのサーバーを経由せず、直接アノテーションツール上に配信されます。 + セキュリティ要件のためお客様の入力データを社外(AnnoFab含む)に非公開にしたい場合、プライベートストレージを利用することができます。 + また場合によっては、AnnoFabから入力データを配信するよりも配信速度が改善する場合があります。 + + 関連 + * [af-supplementary](#tag/af-supplementary): 入力データを補う補助情報 +- name: af-inspection + x-displayName: Inspection + description: 検査コメントに対する操作 +- name: af-instruction + x-displayName: Instruction + description: 作業ガイドに対する操作 +- name: af-job + x-displayName: Job + description: バッチ処理ジョブに対する操作 +- name: af-login + x-displayName: Login + description: ログイン関連の操作 +- name: af-my + x-displayName: My + description: 自身のリソースに対する操作 +- name: af-organization + x-displayName: Organization + description: 組織に対する操作 +- name: af-organization-member + x-displayName: Organization Member + description: 組織メンバーに対する操作 +- name: af-organization-plugin + x-displayName: Organization Plugin + description: | + 組織で使用するプラグインに対する操作 + + **このAPIは AnnoFab に許可された組織だけで使用できます。またアルファ版につき、予告なく変更されることがあります。** +- name: af-project + x-displayName: Project + description: プロジェクトに対する操作 +- name: af-project-member + x-displayName: Project Member + description: プロジェクトメンバーに対する操作 +- name: af-statistics + x-displayName: Statistics + description: 集計に関する操作 +- name: af-supplementary + x-displayName: Supplementary + description: | + **補助情報(supprementary data)**に対する操作です。 + + 補助情報とは、アノテーションする対象となる[入力データ](#tag/af-input)では*ありません*が、 + アノテーションするときに何らかの手がかりや文脈を与えるデータのことです。 + 例えば、次のようなものです。 + * 現在の写真に対する、過去の写真 + * 光学写真に対する、暗視写真 + * 前方を撮影した写真に対する、左側面・右側面・後方の写真 + * 写真や動画を撮影した日時、緯度経度、撮影者などのメタデータ(テキスト) + + 補助情報は、画像やテキストで、プロジェクトの入力データごとにひも付けられます。 + 補助情報で扱う画像は、入力データと同様にAnnoFabにアップロードする他に、プライベートストレージの画像を利用することもできます。 + + 関連 + * [af-input](#tag/af-input): 補助情報をひもづける入力データ + * [af-project](#tag/af-project): 補助情報をひもづけるプロジェクト +- name: af-task + x-displayName: Task + description: タスクに対する操作 +- name: af-webhook + x-displayName: Webhook + description: Webhookに対する操作 +- name: x-annotation-zip + x-displayName: Annotation ZIP + description: | + AnnoFabで作成したアノテーションは、元となった入力データ(画像や動画など)に対応する形で1ファイルのJSONとなります。 + これらのJSONはZIP形式で圧縮され、一括で取得できます。 + + AnnoFabから取得できるアノテーションの構造は、現在2種類あります。 + + 1. Simple + * バウンディングボックスや属性など、いわゆるアノテーションにしぼった軽量な構造。 + * いかなるプロジェクトでも取得できます。 + * 推奨版です。 + * アノテーションZIPおよびアノテーション構造の詳細は、 [Simple Annotation ZIP](#section/Simple-Annotation-ZIP) を参照ください。 + 2. Full + * バウンディングボックスや属性に加え、アノテーションを作成したタスクに関する構造が含まれる重厚長大な構造。 + * Businessプラン組織のプロジェクトでのみ取得できます。 + * 非推奨版です。長期的には廃止予定なので、新規の使用は控え、Simpleへ移行してください。 + * アノテーションZIPおよびアノテーション構造の詳細は、 [Full Annotation ZIP](#section/Full-Annotation-ZIP) を参照ください。 + + アノテーションは、各プロジェクトのトップページでダウンロードできます。また、次のAPIを利用して取得することもできます。 + + * Simple版アノテーションZIP取得API: [getAnnotationArchive](#operation/getAnnotationArchive) + * Full版アノテーションZIP取得API: [getArchiveFullWithProId](#operation/getArchiveFullWithProId) + + なお、アノテーションZIPは毎日AM 03:00 JSTごろに自動更新されます。 + + ## Simple Annotation ZIP + ### ファイル名 + `af-annotation-{プロジェクトID}-{更新日時: yyyyMMdd-hhmmss}.zip` + + ### ZIPファイル内の構造 + * / (ZIPファイルのルートディレクトリ) + * {タスクID}/ + * {入力データ名}.json + * アノテーションJSONデータ (詳細は次節を参照) + * {入力データ名}/ (塗りつぶしアノテーション時のみ) + * {アノテーションデータID} (塗りつぶしのPNG画像) + + ### アノテーションJSONデータの構造 + Simple版アノテーションZIPに含まれるアノテーションJSONは、機械学習の一般的な利用で扱いやすい構造になっています。 + + + ### 注意事項 + 同じ入力データ名を持つ入力データが複数存在する場合、Simple版アノテーションZIP内のファイル名およびディレクトリ名が `{入力データ名__入力データID}` となる場合があります。 + + この現象は[入力データ更新API](#operation/putInputData)を使用して、複数の入力データの入力データ名を重複させた場合に発生することがあります。 + AnnoFabの画像アップロード機能のみ使用していた場合には発生しません。 + + この現象を回避したい場合、入力データ更新APIを使用して入力データ名の重複を解消した後、アノテーションZIPを再作成してください。 + + ## Full Annotation ZIP + ### ファイル名 + `af-annotation-{プロジェクトID}-{更新日時: yyyyMMdd-hhmmss}.zip` + + ### ZIPファイル内の構造 + * / (ZIPファイルのルートディレクトリ) + * {タスクID}/ + * {入力データID}.json + * アノテーションJSONデータ (詳細は次節を参照) + * {入力データID}/ (塗りつぶしアノテーション時のみ) + * {アノテーションデータID} (塗りつぶしのPNG画像) + + ### アノテーションJSONデータの構造 + Full版アノテーションZIPに含まれるアノテーションJSONは、画像やアノテーションやアノテーション作成者など管理用の詳細情報が付随しています。 + + +- name: x-data-types + x-displayName: Data Types + description: | + # Task + + + # TaskHistory + + + # TaskHistoryEvent + + + # Inspection + + + # TaskStatus + + + # TaskPhase + + + # AnnotationId + + + # InputData + + + # JobType + + + # AnnotationQuery + - ### ファイル名 - - `af-annotation-{プロジェクトID}-{更新日時: yyyyMMdd-hhmmss}.zip` - - - ### ZIPファイル内の構造 - - * / (ZIPファイルのルートディレクトリ) - * {タスクID}/ - * {入力データ名}.json - * アノテーションJSONデータ (詳細は次節を参照) - * {入力データ名}/ (塗りつぶしアノテーション時のみ) - * {アノテーションデータID} (塗りつぶしのPNG画像) - - ### アノテーションJSONデータの構造 - - Simple版アノテーションZIPに含まれるアノテーションJSONは、機械学習の一般的な利用で扱いやすい構造になっています。 - - - - - ### 注意事項 - - 同じ入力データ名を持つ入力データが複数存在する場合、Simple版アノテーションZIP内のファイル名およびディレクトリ名が `{入力データ名__入力データID}` となる場合があります。 - - - この現象は[入力データ更新API](#operation/putInputData)を使用して、複数の入力データの入力データ名を重複させた場合に発生することがあります。 - - AnnoFabの画像アップロード機能のみ使用していた場合には発生しません。 - - - この現象を回避したい場合、入力データ更新APIを使用して入力データ名の重複を解消した後、アノテーションZIPを再作成してください。 - - - ## Full Annotation ZIP - - ### ファイル名 - - `af-annotation-{プロジェクトID}-{更新日時: yyyyMMdd-hhmmss}.zip` - - - ### ZIPファイル内の構造 - - * / (ZIPファイルのルートディレクトリ) - * {タスクID}/ - * {入力データID}.json - * アノテーションJSONデータ (詳細は次節を参照) - * {入力データID}/ (塗りつぶしアノテーション時のみ) - * {アノテーションデータID} (塗りつぶしのPNG画像) - - ### アノテーションJSONデータの構造 - - Full版アノテーションZIPに含まれるアノテーションJSONは、画像やアノテーションやアノテーション作成者など管理用の詳細情報が付随しています。 - - - - name: x-data-types - x-displayName: Data Types - description: | - # Task - - - # TaskHistory - - - # TaskHistoryEvent - - - # Inspection - - - # TaskStatus - - - # TaskPhase - - - # AnnotationId - - - # InputData - - - # JobType - - - # AnnotationQuery - x-tagGroups: - name: API tags: @@ -379,133 +340,108 @@ x-tagGroups: components: securitySchemes: EveryoneRequestBody: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/EveryoneRequestBody + $ref: "swagger-api-components.yaml#/components/securitySchemes/EveryoneRequestBody" EveryoneQueryParameter: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/EveryoneQueryParameter + $ref: "swagger-api-components.yaml#/components/securitySchemes/EveryoneQueryParameter" Everyone: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/Everyone + $ref: "swagger-api-components.yaml#/components/securitySchemes/Everyone" AnnoFabAdminOnly: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AnnoFabAdminOnly + $ref: "swagger-api-components.yaml#/components/securitySchemes/AnnoFabAdminOnly" AllProjectMember: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AllProjectMember + $ref: "swagger-api-components.yaml#/components/securitySchemes/AllProjectMember" ProjectAccepter: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectAccepter + $ref: "swagger-api-components.yaml#/components/securitySchemes/ProjectAccepter" ProjectDataUser: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectDataUser + $ref: "swagger-api-components.yaml#/components/securitySchemes/ProjectDataUser" ProjectAccepterOrDataUser: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectAccepterOrDataUser + $ref: "swagger-api-components.yaml#/components/securitySchemes/ProjectAccepterOrDataUser" ProjectOwner: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/ProjectOwner + $ref: "swagger-api-components.yaml#/components/securitySchemes/ProjectOwner" AllOrganizationMember: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/AllOrganizationMember + $ref: "swagger-api-components.yaml#/components/securitySchemes/AllOrganizationMember" OrganizationAdministrator: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/OrganizationAdministrator + $ref: "swagger-api-components.yaml#/components/securitySchemes/OrganizationAdministrator" OrganizationOwner: - $ref: swagger-api-components.redoc.yaml#/components/securitySchemes/OrganizationOwner - schemas: - SimpleAnnotation: - $ref: swagger-api-components.redoc.yaml#/components/schemas/SimpleAnnotation - FullAnnotation: - $ref: swagger-api-components.redoc.yaml#/components/schemas/FullAnnotation - Task: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Task - TaskHistory: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskHistory - TaskHistoryEvent: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskHistoryEvent - Inspection: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Inspection - TaskStatus: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskStatus - TaskPhase: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhase - AnnotationId: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationId - InputData: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData - JobType: - $ref: swagger-api-components.redoc.yaml#/components/schemas/JobType - AnnotationQuery: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationQuery + $ref: "swagger-api-components.yaml#/components/securitySchemes/OrganizationOwner" paths: /login: post: tags: - - af-login + - af-login summary: ログイン description: "" security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: login requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/LoginRequest + $ref: "swagger-api-components.yaml#/components/schemas/LoginRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/LoginResponse + $ref: "swagger-api-components.yaml#/components/schemas/LoginResponse" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /logout: post: tags: - - af-login + - af-login summary: ログアウト - description: 本人認証にはリクエストボディのトークンを使用します。 + description: "本人認証にはリクエストボディのトークンを使用します。" security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: logout requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Token + $ref: "swagger-api-components.yaml#/components/schemas/Token" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /refresh-token: post: tags: - - af-login + - af-login summary: トークン リフレッシュ description: "" security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: refreshToken requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/RefreshTokenRequest + $ref: "swagger-api-components.yaml#/components/schemas/RefreshTokenRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Token + $ref: "swagger-api-components.yaml#/components/schemas/Token" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorRefreshTokenExpired + $ref: "swagger-api-components.yaml#/components/responses/ErrorRefreshTokenExpired" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /sign-up: post: tags: - - af-account + - af-account summary: サインアップstep1(開始) description: "" operationId: initiateSignup @@ -514,221 +450,218 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/SignUpRequest + $ref: "swagger-api-components.yaml#/components/schemas/SignUpRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" /confirm-sign-up: post: tags: - - af-account + - af-account summary: サインアップstep2(確定) description: "" operationId: confirmSignup security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmSignUpRequest + $ref: "swagger-api-components.yaml#/components/schemas/ConfirmSignUpRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /change-password: post: tags: - - af-account + - af-account summary: パスワード変更 description: "" security: - - Everyone: [] + - Everyone: [] operationId: changePassword requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ChangePasswordRequest + $ref: "swagger-api-components.yaml#/components/schemas/ChangePasswordRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /request-password-reset: post: tags: - - af-account + - af-account summary: パスワードリセットstep1(開始) - description: > + description: | パスワードリセットに必要な確認コードをメールで送付します。 - 後続の[新しいパスワードに変更](#operation/confirmResetPassword)を実行することで、新しいパスワードに変更できます。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: initiatePasswordReset requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PasswordResetRequest + $ref: "swagger-api-components.yaml#/components/schemas/PasswordResetRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /confirm-reset-password: post: tags: - - af-account + - af-account summary: パスワードリセットstep2(新しいパスワードに変更) - description: > + description: | 新しいパスワードに変更します。 - 本人確認のため、[パスワードリセットを要求](#operation/initiateResetPassword)で受信したメールに記載された検証コードを使用します。 - パスワードリセットプロセスの最終ステップです。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: confirmResetPassword requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmResetPasswordRequest + $ref: "swagger-api-components.yaml#/components/schemas/ConfirmResetPasswordRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /reset-email: post: tags: - - af-account + - af-account summary: メールアドレスリセットstep1(開始) description: | メールアドレス変更プロセスを開始します。 本人からの要求かどうかを検証するための確認コードがメールで送付されます。 security: - - Everyone: [] + - Everyone: [] operationId: initiateResetEmail requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ResetEmailRequest + $ref: "swagger-api-components.yaml#/components/schemas/ResetEmailRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /confirm-reset-email: post: tags: - - af-account + - af-account summary: メールアドレスstep2(確定) description: | [受け取った確認コード](#operation/initiateResetEmail)を使い、メールアドレスを変更します。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: confirmResetEmail requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmResetEmailRequest + $ref: "swagger-api-components.yaml#/components/schemas/ConfirmResetEmailRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /verify-email: post: tags: - - af-account + - af-account summary: メールアドレス検証step1(開始) description: | メールアドレスが有効かどうかの確認プロセスを開始します。 本人からの要求かどうかを検証するための確認コードがメールで送付されます。 security: - - Everyone: [] + - Everyone: [] operationId: initiateVerifyEmail requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/VerifyEmailRequest + $ref: "swagger-api-components.yaml#/components/schemas/VerifyEmailRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /confirm-verify-email: post: tags: - - af-account + - af-account summary: メールアドレス検証step2(確定) description: | [受け取った確認コード](#operation/initiateVerifyEmail)を使い、メールアドレスが有効であることを確認します。 security: - - Everyone: [] + - Everyone: [] operationId: confirmVerifyEmail requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmVerifyEmailRequest + $ref: "swagger-api-components.yaml#/components/schemas/ConfirmVerifyEmailRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /my/account: get: tags: - - af-my + - af-my summary: 自分のアカウント取得 description: "" security: - - Everyone: [] + - Everyone: [] operationId: getMyAccount responses: "200": @@ -736,98 +669,98 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/MyAccount + $ref: "swagger-api-components.yaml#/components/schemas/MyAccount" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-my + - af-my summary: 自分のアカウント情報更新 description: "" security: - - Everyone: [] + - Everyone: [] operationId: putMyAccount requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PutMyAccountRequest + $ref: "swagger-api-components.yaml#/components/schemas/PutMyAccountRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/MyAccount + $ref: "swagger-api-components.yaml#/components/schemas/MyAccount" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /my/account/delete-request: post: tags: - - af-my + - af-my summary: アカウント削除step1 description: | アカウント削除プロセスを開始します。 本人からの要求かどうかを検証するための確認コードがメールで送付されます。 security: - - Everyone: [] + - Everyone: [] operationId: initiateMyAccountDelete responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /my/account/delete-request/confirm: post: tags: - - af-my + - af-my summary: アカウント削除step2(確定) description: | [受け取った確認コード](#operation/initiateMyAccountDelete)を使い、アカウントを削除します。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: confirmMyAccountDelete requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ConfirmAccountDeleteRequest + $ref: "swagger-api-components.yaml#/components/schemas/ConfirmAccountDeleteRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "409": description: 自身のみがオーナーのプロジェクト、または組織が1つ以上存在した content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /my/project-members: get: tags: - - af-my + - af-my summary: 自分のプロジェクトメンバー情報一括取得 description: "" security: - - Everyone: [] + - Everyone: [] operationId: getMyProjectMembers responses: "200": @@ -837,9 +770,9 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + $ref: "swagger-api-components.yaml#/components/schemas/ProjectMember" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" /organizations: post: tags: @@ -855,127 +788,127 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationRegistrationRequest + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationRegistrationRequest" responses: "200": description: 作成に成功すると、その組織 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + $ref: "swagger-api-components.yaml#/components/schemas/Organization" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /my/organizations: get: tags: - - af-my + - af-my summary: 所属組織一括取得 description: "" security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getMyOrganizations parameters: - - name: page - in: query - description: | - 表示するページ番号 - - 現在は未実装のパラメータです。(今後対応予定) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: | - 1ページあたりの取得するデータ件数 - - 現在は未実装のパラメータです。(今後対応予定) - required: false - schema: - type: integer - minimum: 1 - default: 30 - maximum: 200 + - name: page + in: query + description: | + 表示するページ番号 + + 現在は未実装のパラメータです。(今後対応予定) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: | + 1ページあたりの取得するデータ件数 + + 現在は未実装のパラメータです。(今後対応予定) + required: false + schema: + type: integer + minimum: 1 + default: 30 + maximum: 200 responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/MyOrganizationList + $ref: "swagger-api-components.yaml#/components/schemas/MyOrganizationList" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-my + - af-my summary: 組織名変更 description: | 同じ name の組織が既に存在する場合は失敗(400)します。 security: - - OrganizationOwner: [] + - OrganizationOwner: [] operationId: updateOrganization requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PutOrganizationNameRequest + $ref: "swagger-api-components.yaml#/components/schemas/PutOrganizationNameRequest" responses: "200": description: 変更に成功すると、その組織 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + $ref: "swagger-api-components.yaml#/components/schemas/Organization" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "409": description: 先に更新されているため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorAlreadyUpdated + $ref: "swagger-api-components.yaml#/components/schemas/ErrorAlreadyUpdated" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}: get: tags: - - af-organization + - af-organization summary: 組織情報取得 - description: "" + description: | security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getOrganization parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + $ref: "swagger-api-components.yaml#/components/schemas/Organization" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" delete: tags: - af-organization @@ -1002,373 +935,371 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + $ref: "swagger-api-components.yaml#/components/schemas/Organization" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": description: プロジェクトが存在する組織を削除しようとした content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}/projects": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}/projects: get: tags: - - af-organization + - af-organization summary: 組織配下プロジェクト一括取得 description: | 指定した組織のプロジェクトを一括で取得します。 security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getProjectsOfOrganization parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: page - in: query - description: | - 表示するページ番号 - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: | - 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 1 - default: 30 - maximum: 200 - - name: account_id - in: query - description: | - 指定したアカウントIDをメンバーに持つプロジェクトで絞り込む。 - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId - - name: except_account_id - in: query - description: | - 指定したアカウントIDをメンバーに持たないプロジェクトで絞り込む。 - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId - - name: title - in: query - description: | - プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 - required: false - schema: - type: string - - name: status - in: query - description: | - 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectStatus - - name: input_data_type - in: query - description: | - 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト。 - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataType - - name: sort_by - in: query - description: | - `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 - 未指定時はプロジェクト名でソートする。 - required: false - schema: - type: string - example: date + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: page + in: query + description: | + 表示するページ番号 + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: | + 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 1 + default: 30 + maximum: 200 + - name: account_id + in: query + description: | + 指定したアカウントIDをメンバーに持つプロジェクトで絞り込む。 + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/AccountId" + - name: except_account_id + in: query + description: | + 指定したアカウントIDをメンバーに持たないプロジェクトで絞り込む。 + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/AccountId" + - name: title + in: query + description: | + プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 + required: false + schema: + type: string + - name: status + in: query + description: | + 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectStatus" + - name: input_data_type + in: query + description: | + 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト。 + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataType" + - name: sort_by + in: query + description: | + `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 + 未指定時はプロジェクト名でソートする。 + required: false + schema: + type: string + example: date responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectList + $ref: "swagger-api-components.yaml#/components/schemas/ProjectList" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}/members": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}/members: get: tags: - - af-organization-member + - af-organization-member summary: 組織メンバー一括取得 description: | 脱退したメンバーは含まれません。 security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getOrganizationMembers parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMemberList + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationMemberList" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}/members/{user_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}/members/{user_id}: get: tags: - - af-organization-member + - af-organization-member summary: 組織メンバー取得 description: | 指定したユーザーが指定した組織にどのようなロールで参加しているかを取得します。 security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getOrganizationMember parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/UserId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMember + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationMember" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" delete: tags: - - af-organization-member + - af-organization-member summary: 組織メンバー削除 description: | 指定したメンバーを指定した組織から削除します。 組織の管理者が実行する場合、組織のオーナーは削除できません。(権限エラーになります) security: - - OrganizationAdministrator: [] + - OrganizationAdministrator: [] operationId: deleteOrganizationMember parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/UserId" responses: "200": description: 正常。削除したメンバーを返します content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMember + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationMember" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}/members/{user_id}/role": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}/members/{user_id}/role: put: tags: - - af-organization-member + - af-organization-member summary: 組織メンバーのロール更新 - description: "" + description: | security: - - OrganizationOwner: [] + - OrganizationOwner: [] operationId: updateOrganizationMemberRole parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/UserId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PutOrganizationMemberRoleRequest + $ref: "swagger-api-components.yaml#/components/schemas/PutOrganizationMemberRoleRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMember + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationMember" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}/members/{user_id}/invitation": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}/members/{user_id}/invitation: post: tags: - - af-organization-member + - af-organization-member summary: 組織への招待送信 - description: > + description: | 指定したユーザーに、組織への招待(メール)を送信します。 - 組織の管理者が実行する場合、リクエストボディ内の `role` には `contributor` を指定してください。(それ以外の値を指定した場合エラーとなります) security: - - OrganizationAdministrator: [] + - OrganizationAdministrator: [] operationId: inviteOrganizationMember parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザ名 - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザ名 + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/UserId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InviteOrganizationMemberRequest + $ref: "swagger-api-components.yaml#/components/schemas/InviteOrganizationMemberRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationMember + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationMember" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}/members/{user_id}/invitation/accept": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}/members/{user_id}/invitation/accept: post: tags: - - af-organization-member + - af-organization-member summary: 組織への招待受諾 - description: > + description: | 組織への招待を受諾し、組織へのメンバー登録を完了します。 - [組織招待API](#operation/postInviteOrganizationMember)で送信されたメールに記載されているトークンが必要です。 security: - - EveryoneRequestBody: [] + - EveryoneRequestBody: [] operationId: acceptOrganizationInvitation parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string - - name: user_id - in: path - description: ユーザ名 - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string + - name: user_id + in: path + description: ユーザ名 + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/UserId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AcceptOrganizationInvitationRequest + $ref: "swagger-api-components.yaml#/components/schemas/AcceptOrganizationInvitationRequest" responses: "200": - $ref: swagger-api-components.redoc.yaml#/components/responses/SuccessMessage + $ref: "swagger-api-components.yaml#/components/responses/SuccessMessage" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}/activity": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}/activity: get: tags: - - af-organization + - af-organization summary: 組織活動サマリー取得 - description: "" + description: | security: - - AllOrganizationMember: [] + - AllOrganizationMember: [] operationId: getOrganizationActivity parameters: - - name: organization_name - in: path - description: 組織名 - required: true - schema: - type: string + - name: organization_name + in: path + description: 組織名 + required: true + schema: + type: string responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationActivity + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationActivity" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}/plugins": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}/plugins: get: operationId: getOrganizationPlugins summary: プラグイン一括取得 @@ -1385,7 +1316,7 @@ paths: in: path required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationName" description: 組織名 responses: "200": @@ -1393,14 +1324,14 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationPluginList + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationPluginList" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/organizations/{organization_name}/plugins/{plugin_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /organizations/{organization_name}/plugins/{plugin_id}: get: operationId: getOrganizationPlugin summary: プラグイン取得 @@ -1417,13 +1348,13 @@ paths: in: path required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationName" description: 組織名 - name: plugin_id in: path required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PluginId + $ref: "swagger-api-components.yaml#/components/schemas/PluginId" description: プラグインID responses: "200": @@ -1431,13 +1362,13 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationPlugin + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationPlugin" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: operationId: putOrganizationPlugin summary: プラグイン更新 @@ -1455,33 +1386,33 @@ paths: in: path required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationName" description: 組織名 - name: plugin_id in: path required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PluginId + $ref: "swagger-api-components.yaml#/components/schemas/PluginId" description: プラグインID requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PutOrganizationPluginRequest + $ref: "swagger-api-components.yaml#/components/schemas/PutOrganizationPluginRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationPlugin + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationPlugin" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" delete: operationId: deleteOrganizationPlugin summary: プラグイン削除 @@ -1499,13 +1430,13 @@ paths: in: path required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationName + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationName" description: 組織名 - name: plugin_id in: path required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PluginId + $ref: "swagger-api-components.yaml#/components/schemas/PluginId" description: プラグインID responses: "200": @@ -1513,201 +1444,195 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationPlugin + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationPlugin" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" /my/projects: get: tags: - - af-my + - af-my summary: 所属プロジェクト一括取得 description: | 自身が所属するプロジェクトを一括で取得します。 security: - - Everyone: [] + - Everyone: [] operationId: getMyProjects parameters: - - name: page - in: query - description: | - 表示するページ番号 - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: | - 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 0 - maximum: 200 - - name: organization_id - in: query - description: | - 指定した組織に属するプロジェクトに絞り込む。未指定時は全プロジェクト。 - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/OrganizationId - - name: title - in: query - description: | - プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 - required: false - schema: - type: string - - name: status - in: query - description: | - 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectStatus - - name: input_data_type - in: query - description: | - 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataType - - name: sort_by - in: query - description: | - `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 - 未指定時はプロジェクト名でソートする。 - required: false - schema: - type: string - example: date + - name: page + in: query + description: | + 表示するページ番号 + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: | + 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 0 + maximum: 200 + - name: organization_id + in: query + description: | + 指定した組織に属するプロジェクトに絞り込む。未指定時は全プロジェクト。 + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/OrganizationId" + - name: title + in: query + description: | + プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 + required: false + schema: + type: string + - name: status + in: query + description: | + 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectStatus" + - name: input_data_type + in: query + description: | + 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataType" + - name: sort_by + in: query + description: | + `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 + 未指定時はプロジェクト名でソートする。 + required: false + schema: + type: string + example: date responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectContainer + $ref: "swagger-api-components.yaml#/components/schemas/ProjectContainer" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}: get: tags: - - af-project + - af-project summary: プロジェクト取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getProject parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Project + $ref: "swagger-api-components.yaml#/components/schemas/Project" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-project + - af-project summary: プロジェクト作成/更新 - description: > + description: | プロジェクトを新規作成または更新します。 - ### 新規作成する場合 - ユーザーは、作成するプロジェクトをひもづける組織の [OrganizationAdministrator](#section/Authentication/OrganizationAdministrator) である必要があります。 - ### 更新する場合 - ユーザーは、更新するプロジェクトの [ProjectOwner](#section/Authentication/ProjectOwner) である必要があります。 - また所属組織を変更する場合は、新しくひもづける組織の [OrganizationAdministrator](#section/Authentication/OrganizationAdministrator) である必要があります。 - なお、プロジェクト状態を「停止中」にした場合、アノテーションZIPやタスク進捗状況などの集計情報は自動更新されなくなります。 security: - - OrganizationAdministrator: [] - ProjectOwner: [] + - OrganizationAdministrator: [] + ProjectOwner: [] operationId: putProject parameters: - - name: project_id - in: path - description: | - プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: v - in: query - description: | - APIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":Project - - "2":PutProjectResponse - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: | + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Project + - "2":PutProjectResponse + required: false + schema: + type: string + default: "1" + example: "2" requestBody: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PutProjectRequest + $ref: "swagger-api-components.yaml#/components/schemas/PutProjectRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Project + $ref: "swagger-api-components.yaml#/components/schemas/Project" "202": description: 組織変更実施時 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PutProjectResponseWrapper + $ref: "swagger-api-components.yaml#/components/schemas/PutProjectResponseWrapper" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "409": description: 現在のプロジェクトやタスクの状態ではできない操作をしようとした content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" delete: tags: - - af-project + - af-project summary: プロジェクト削除 description: | プロジェクトを完全に削除します。 @@ -1716,180 +1641,160 @@ paths: 削除されたプロジェクトは元に戻せません。 完了したプロジェクトは削除せず、プロジェクト状態を「停止中」に変更するのをおすすめします。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteProject parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: v - in: query - description: | - APIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":Project - - "2":DeleteProjectResponse - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Project + - "2":DeleteProjectResponse + required: false + schema: + type: string + default: "1" + example: "2" responses: "202": description: バッチにてプロジェクトの削除開始 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/DeleteProjectResponseWrapper + $ref: "swagger-api-components.yaml#/components/schemas/DeleteProjectResponseWrapper" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": description: 停止中ではないプロジェクトを削除しようとした content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/organization": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/organization: get: tags: - - af-project + - af-project summary: プロジェクトの所属組織取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getOrganizationOfProject parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Organization + $ref: "swagger-api-components.yaml#/components/schemas/Organization" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/copy": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/copy: post: tags: - - af-project + - af-project summary: プロジェクト複製 - description: > + description: | 指定したプロジェクトのデータを引き継いだ新しいプロジェクトを作成します。 - 新しいプロジェクトに引き継がれるデータは次の通りです。 - * プロジェクト設定 - * プロジェクトメンバー - * アノテーション仕様 - また、オプションを指定することで新しいプロジェクトに次のデータを引き継ぐことも可能です。 - |引き継ぎ対象|同時に引き継ぐ必要があるデータ| - |:--|:--| - |入力データ|| - |タスク|入力データ| - |アノテーション|入力データ、タスク| - |補助情報|入力データ| - |作業ガイド|| - |Webhook|| - このAPIを利用するには、プロジェクトを登録する組織の[OrganizationAdministrator](#section/Authentication/OrganizationAdministrator) かつ コピー元プロジェクトの [ProjectOwner](#section/Authentication/ProjectOwner) である必要があります。 - 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`copy-project`)。 security: - - OrganizationAdministrator: [] - ProjectOwner: [] + - OrganizationAdministrator: [] + ProjectOwner: [] operationId: initiateProjectCopy parameters: - - name: project_id - in: path - description: コピー元となるプロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: v - in: query - description: | - APIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":Project - - "2":ProjectCopyResponse - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: コピー元となるプロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Project + - "2":ProjectCopyResponse + required: false + schema: + type: string + default: "1" + example: "2" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectCopyRequest + $ref: "swagger-api-components.yaml#/components/schemas/ProjectCopyRequest" responses: "202": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectCopyResponseWrapper + $ref: "swagger-api-components.yaml#/components/schemas/ProjectCopyResponseWrapper" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/rawdata/inputs": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/rawdata/inputs: get: tags: - af-project summary: プロジェクトの入力データ情報全件URLの取得 - description: > + description: | 入力データ情報全件ファイルにアクセスするための、認証済み一時URLを取得します。 - 取得したURLは1時間で失効し、アクセスできなくなります。 - ### 入力データ情報全件ファイル - 入力データ情報全件ファイルには、プロジェクトの入力データ情報がJSON形式([InputData](#section/InputData)の配列)で記録されています。 - ただし`InputData`中の`url`は常に`null`です。 - このファイルは毎日AM 02:00 JSTに更新されます。 security: - ProjectOwner: [] @@ -1900,7 +1805,7 @@ paths: description: プロジェクトID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -1913,32 +1818,26 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + $ref: "swagger-api-components.yaml#/components/schemas/TemporaryUrl" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" post: tags: - af-project summary: プロジェクトの入力データ情報全件ファイル更新開始 - description: > + description: | プロジェクト内の入力データ情報全件ファイルの更新を開始します。 - ファイルの更新時間は、データ量に応じて数分~数十分程度かかります。 - 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-inputs-list`)。 - 入力データ情報全件ファイルは毎日AM 02:00 JSTに自動更新されます。 - 本APIを用いると、自動更新を待たずに更新を要求できます。 - ただし、入力データ情報全件ファイル以外は更新されません。 - 入力データ情報全件ファイルについては、[getProjectInputsUrl](#operation/getProjectInputsUrl) APIを参照ください。 security: - ProjectOwner: [] @@ -1949,48 +1848,43 @@ paths: description: プロジェクトID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "202": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectInputsUpdateResponse + $ref: "swagger-api-components.yaml#/components/schemas/ProjectInputsUpdateResponse" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/rawdata/tasks": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/rawdata/tasks: get: tags: - - af-project + - af-project summary: プロジェクトのタスク全件URLの取得 - description: > + description: | タスク全件ファイルにアクセスするための、認証済み一時URLを取得します。 - 取得したURLは1時間で失効し、アクセスできなくなります。 - ### タスク全件ファイル - タスク全件ファイルには、プロジェクトのタスク情報がJSON形式([Task](#section/Task)の配列)で記録されています。 - このファイルは毎日AM 02:00 JSTに更新されます。 - また、[postProjectTasksUpdate](#operation/postProjectTasksUpdate) APIを利用することで、手動でタスク全件ファイルを更新することも可能です。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: getProjectTasksUrl parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2003,32 +1897,26 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + $ref: "swagger-api-components.yaml#/components/schemas/TemporaryUrl" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" post: tags: - - af-project + - af-project summary: プロジェクトのタスク全件ファイル更新開始 - description: > + description: | プロジェクト内のタスク全件ファイルの更新を開始します。 - ファイルの更新時間は、データ量に応じて数分~数十分程度かかります。 - 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-tasks-list`)。 - タスク全件ファイルは毎日AM 02:00 JSTに自動更新されます。 - 本APIを用いると、自動更新を待たずに更新を要求できます。 - ただし、タスク全件ファイル以外は更新されません。 - タスク全件ファイルについては、[getProjectTasksUrl](#operation/getProjectTasksUrl) APIを参照ください。 security: - ProjectOwner: [] @@ -2039,7 +1927,7 @@ paths: description: プロジェクトID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" - name: v in: query description: | @@ -2058,39 +1946,35 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PostProjectTasksUpdateResponseWrapper + $ref: "swagger-api-components.yaml#/components/schemas/PostProjectTasksUpdateResponseWrapper" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/rawdata/inspections": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/rawdata/inspections: get: tags: - - af-project + - af-project summary: プロジェクトの検査コメント全件URLの取得 - description: > + description: | 検査コメント全件ファイルにアクセスするための、認証済み一時URLを取得します。 - 取得したURLは1時間で失効し、アクセスできなくなります。 - ### 検査コメント全件ファイル - 検査コメント全件ファイルには、プロジェクトの検査コメント情報がJSON形式([Inspection](#section/Inspection)の配列)で記録されています。 - このファイルは毎日AM 02:00 JSTに更新されます。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: getProjectInspectionsUrl parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2103,40 +1987,36 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + $ref: "swagger-api-components.yaml#/components/schemas/TemporaryUrl" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/rawdata/task_history_events": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/rawdata/task_history_events: get: deprecated: true tags: - - af-project + - af-project summary: プロジェクトのタスク履歴イベント全件URLの取得 - description: > + description: | タスク履歴イベント全件ファイルにアクセスするための、認証済み一時URLを取得します。 - 取得したURLは1時間で失効し、アクセスできなくなります。 - ### タスク履歴イベント全件ファイル - タスク履歴イベント全件ファイルには、プロジェクトのタスク履歴イベント情報がJSON形式([TaskHistoryEvent](#section/TaskHistoryEvent)の配列)で記録されています。 - このファイルは毎日AM 02:00 JSTに更新されます。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: getProjectTaskHistoryEventsUrl parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2149,28 +2029,24 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + $ref: "swagger-api-components.yaml#/components/schemas/TemporaryUrl" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/rawdata/task_histories": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/rawdata/task_histories: get: tags: - af-project summary: プロジェクトのタスク履歴全件URLの取得 - description: > + description: | タスク履歴全件ファイルにアクセスするための、認証済み一時URLを取得します。 - 取得したURLは1時間で失効し、アクセスできなくなります。 - ### タスク履歴全件ファイル - タスク履歴イベント全件ファイルには、プロジェクトのタスク履歴情報がJSON形式(キーがタスクID、値が[TaskHistory](#section/TaskHistory)の配列となるマップ)で記録されています。 - このファイルは毎日AM 02:00 JSTに更新されます。 security: - ProjectOwner: [] @@ -2181,7 +2057,7 @@ paths: description: プロジェクトID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2194,178 +2070,174 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + $ref: "swagger-api-components.yaml#/components/schemas/TemporaryUrl" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/my/projects/{project_id}/member": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /my/projects/{project_id}/member: get: tags: - - af-my + - af-my summary: 自分のプロジェクトメンバー取得 - description: > - 備考: - システム管理者が自身が所属しないプロジェクトに対して実行した場合、オーナーであるというダミーのプロジェクトメンバー情報が取得できます。ダミーには更新日は含まれません。 + description: | + 備考: システム管理者が自身が所属しないプロジェクトに対して実行した場合、オーナーであるというダミーのプロジェクトメンバー情報が取得できます。ダミーには更新日は含まれません。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getMyMemberInProject parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + $ref: "swagger-api-components.yaml#/components/schemas/ProjectMember" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/members": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/members: get: tags: - - af-project-member + - af-project-member summary: プロジェクトメンバー一括取得 - description: > - 備考: - 組織に加入していないメンバーも取得できることがあります([プロジェクト更新](#operation/putProject)でプロジェクトの組織移動をおこなった場合)。 + description: | + 備考: 組織に加入していないメンバーも取得できることがあります([プロジェクト更新](#operation/putProject)でプロジェクトの組織移動をおこなった場合)。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getProjectMembers parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: include_inactive_member - in: query - description: 脱退したプロジェクトメンバーも取得する時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: include_inactive_member + in: query + description: 脱退したプロジェクトメンバーも取得する時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMemberList + $ref: "swagger-api-components.yaml#/components/schemas/ProjectMemberList" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/members/{user_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/members/{user_id}: get: tags: - - af-project-member + - af-project-member summary: プロジェクトメンバー取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getProjectMember parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: user_id - in: path - description: アカウントのユーザID. - RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: user_id + in: path + description: アカウントのユーザID. RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/UserId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + $ref: "swagger-api-components.yaml#/components/schemas/ProjectMember" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-project-member + - af-project-member summary: プロジェクトメンバー作成/更新 - description: "" + description: | security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putProjectMember parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: user_id - in: path - description: アカウントのユーザID. - RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/UserId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: user_id + in: path + description: アカウントのユーザID. RESTクライアントユーザが指定しやすいように、Cognitoのaccount_idではなくuser_idとしている。 + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/UserId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMemberRequest + $ref: "swagger-api-components.yaml#/components/schemas/ProjectMemberRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectMember + $ref: "swagger-api-components.yaml#/components/schemas/ProjectMember" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/tasks": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/tasks: get: tags: - - af-statistics + - af-statistics summary: タスク集計取得 description: | 日ごと、タスクフェーズごと、タスクステータスごとに集計した以下のデータを取得します。 * タスク数 * 累計作業時間 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTaskStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2374,17 +2246,17 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectTaskStatisticsHistory + $ref: "swagger-api-components.yaml#/components/schemas/ProjectTaskStatisticsHistory" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/accounts": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/accounts: get: tags: - - af-statistics + - af-statistics summary: ユーザー別タスク集計取得 description: | ユーザごと、日ごとに集計した以下のデータを取得します。 @@ -2392,15 +2264,15 @@ paths: * 教師付を担当したタスクが差し戻された回数 * 作業時間 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAccountStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2409,30 +2281,30 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectAccountStatistics + $ref: "swagger-api-components.yaml#/components/schemas/ProjectAccountStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/inspections": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/inspections: get: tags: - - af-statistics + - af-statistics summary: 検査コメント集計取得 description: | ラベルごと、定型指摘ごとに集計した検査コメント数を取得します。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInspectionStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2441,31 +2313,31 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InspectionStatistics + $ref: "swagger-api-components.yaml#/components/schemas/InspectionStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/task-phases": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/task-phases: get: tags: - - af-statistics + - af-statistics summary: フェーズ別タスク集計取得 description: | 日ごと、フェーズごとに集計した以下のデータを取得します。 * 累積作業時間 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTaskPhaseStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2474,32 +2346,32 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhaseStatistics + $ref: "swagger-api-components.yaml#/components/schemas/TaskPhaseStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/labels": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/labels: get: tags: - - af-statistics + - af-statistics summary: ラベル別アノテーション数集計取得 description: | ラベルごとの以下集計データを取得します。 * 受入が完了したアノテーション数 * 受入が完了していないアノテーション数 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getLabelStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2508,35 +2380,33 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/LabelStatistics + $ref: "swagger-api-components.yaml#/components/schemas/LabelStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/worktimes": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/worktimes: get: tags: - - af-statistics + - af-statistics summary: タスク作業時間集計取得 - description: > + description: | 単位当たり(タスク1個、画像1個、動画1分)の作業時間情報が格納されたファイルに対して、認証済み一時URLを取得します。認証済み一時URLはLocationヘッダに格納されています。 - ヒストグラムは最終日のby_tasks、by_inputsでのみ返却する。 - アカウント毎の集計のby_tasks、by_inputsには、最終日であってもヒストグラムを返却しない。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getWorktimeStatistics parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2550,191 +2420,191 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/WorktimeStatistics + $ref: "swagger-api-components.yaml#/components/schemas/WorktimeStatistics" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/statistics/markers": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/statistics/markers: get: tags: - - af-statistics + - af-statistics summary: 統計グラフマーカー取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getMarkers parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Markers + $ref: "swagger-api-components.yaml#/components/schemas/Markers" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-statistics + - af-statistics summary: 統計グラフマーカー更新 - description: "" + description: | security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putMarkers parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PutMarkersRequest + $ref: "swagger-api-components.yaml#/components/schemas/PutMarkersRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Markers + $ref: "swagger-api-components.yaml#/components/schemas/Markers" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/jobs": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/jobs: get: tags: - - af-job + - af-job summary: バックグラウンドジョブ情報取得 description: | バックグラウンドジョブの情報を取得する。 取得されるジョブの情報は作成日付の新しい順にソートされる。 バックグラウンドジョブ情報は完了(失敗含む)から14日経過後に削除される。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getProjectJob parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: type - in: query - description: 取得するジョブの種別。[詳細はこちら](#section/JobType)。 - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/JobType - - name: page - in: query - description: | - 検索結果のうち、取得したいページの番号(1始まり) - - 現在は未実装のパラメータです。(今後対応予定) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: | - 1ページあたりの取得するデータ件数。 - 未指定時は1件のみ取得。 - required: false - schema: - type: integer - minimum: 0 - maximum: 200 - default: 1 - - name: exclusive_start_created_datetime - in: query - description: 取得するデータの直前の作成日時 - required: false - schema: - type: string + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: type + in: query + description: 取得するジョブの種別。[詳細はこちら](#section/JobType)。 + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/JobType" + - name: page + in: query + description: | + 検索結果のうち、取得したいページの番号(1始まり) + + 現在は未実装のパラメータです。(今後対応予定) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: | + 1ページあたりの取得するデータ件数。 + 未指定時は1件のみ取得。 + required: false + schema: + type: integer + minimum: 0 + maximum: 200 + default: 1 + - name: exclusive_start_created_datetime + in: query + description: 取得するデータの直前の作成日時 + required: false + schema: + type: string responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/JobInfoContainer + $ref: "swagger-api-components.yaml#/components/schemas/JobInfoContainer" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/jobs/gen-inputs/{job_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/jobs/gen-inputs/{job_id}: delete: tags: - - af-job + - af-job summary: バックグラウンドジョブ情報削除 - description: "" + description: | security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteProjectJob parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: job_id - in: path - description: ジョブID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/JobId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: job_id + in: path + description: ジョブID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/JobId" responses: "200": description: 正常 "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/webhooks": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/webhooks: get: tags: - - af-webhook + - af-webhook summary: プロジェクトのWebhookをすべて取得 - description: "" + description: | security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: getWebhooks parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -2743,17 +2613,17 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Webhook + $ref: "swagger-api-components.yaml#/components/schemas/Webhook" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/webhooks/{webhook_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/webhooks/{webhook_id}: put: tags: - - af-webhook + - af-webhook summary: プロジェクトのWebhookを更新 description: | プロジェクトのWebhookを新規登録/更新することができます。 @@ -2789,82 +2659,83 @@ paths: * {{DEST_PROJECT_TITLE}} : コピー先プロジェクトタイトル * {{COMPLETE_DATETIME}} : 完了日時 * 例 : 2019-05-08T10:00:00.000+09:00 + security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putWebhook parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: webhook_id - in: path - description: | - WebhookID。[値の制約についてはこちら。](#section/API-Convention/APIID) - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: webhook_id + in: path + description: | + WebhookID。[値の制約についてはこちら。](#section/API-Convention/APIID) + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/WebhookId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Webhook + $ref: "swagger-api-components.yaml#/components/schemas/Webhook" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Webhook + $ref: "swagger-api-components.yaml#/components/schemas/Webhook" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" delete: tags: - - af-webhook + - af-webhook summary: プロジェクトのWebhookを削除 - description: "" + description: | security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteWebhook parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: webhook_id - in: path - description: WebhookID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: webhook_id + in: path + description: WebhookID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/WebhookId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Webhook + $ref: "swagger-api-components.yaml#/components/schemas/Webhook" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/webhooks/{webhook_id}/test": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/webhooks/{webhook_id}/test: post: tags: - af-webhook summary: プロジェクトのWebhookをテスト実行 - description: "" + description: | security: - ProjectOwner: [] operationId: testWebhook @@ -2874,133 +2745,131 @@ paths: description: プロジェクトID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" - name: webhook_id in: path description: WebhookID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookId + $ref: "swagger-api-components.yaml#/components/schemas/WebhookId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookTestRequest + $ref: "swagger-api-components.yaml#/components/schemas/WebhookTestRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/WebhookTestResponse + $ref: "swagger-api-components.yaml#/components/schemas/WebhookTestResponse" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/annotation-specs": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/annotation-specs: get: tags: - - af-annotation-specs + - af-annotation-specs summary: アノテーション仕様取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAnnotationSpecs parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: history_id - in: query - description: > - 過去のアノテーション仕様を取得する場合、[アノテーション仕様履歴取得](#operation/getAnnotationSpecsHistories)APIで取得した - `history_id` の値を指定します。 - - 未指定時は最新のアノテーション仕様を取得します。 - required: false - schema: - type: string - example: "123456789" - - name: v - in: query - description: | - 取得するアノテーション仕様のフォーマットバージョンを指定します。 - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: history_id + in: query + description: | + 過去のアノテーション仕様を取得する場合、[アノテーション仕様履歴取得](#operation/getAnnotationSpecsHistories)APIで取得した `history_id` の値を指定します。 + 未指定時は最新のアノテーション仕様を取得します。 + required: false + schema: + type: string + example: "123456789" + - name: v + in: query + description: | + 取得するアノテーション仕様のフォーマットバージョンを指定します。 + required: false + schema: + type: string + default: "1" + example: "2" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecs + $ref: "swagger-api-components.yaml#/components/schemas/AnnotationSpecs" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-annotation-specs + - af-annotation-specs summary: アノテーション仕様更新 - description: "" + description: | security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putAnnotationSpecs parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecsRequest + $ref: "swagger-api-components.yaml#/components/schemas/AnnotationSpecsRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecsV2 + $ref: "swagger-api-components.yaml#/components/schemas/AnnotationSpecsV2" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/annotation-specs-histories": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/annotation-specs-histories: get: tags: - - af-annotation-specs + - af-annotation-specs summary: アノテーション仕様履歴取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAnnotationSpecsHistories parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -3009,64 +2878,64 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationSpecsHistory + $ref: "swagger-api-components.yaml#/components/schemas/AnnotationSpecsHistory" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/start-task": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/start-task: post: deprecated: true tags: - - af-task + - af-task summary: タスク割当 description: | タスクの割当を要求します。 個々のタスクの情報を取得する場合は、[タスク取得](#operation/getTask)を使います。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: startTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskStart + $ref: "swagger-api-components.yaml#/components/schemas/TaskStart" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + $ref: "swagger-api-components.yaml#/components/schemas/Task" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": description: タスクを開始できる状態ではない content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/tasks": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/tasks: get: tags: - - af-task + - af-task summary: タスク一括取得 description: | プロジェクトに含まれる複数のタスクをまとめて取得します。 @@ -3075,135 +2944,139 @@ paths: パフォーマンスのため、結果はページング形式で返ります。全件取得したい場合は、レスポンスを見て、ページ移動してください。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTasks parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: page - in: query - description: 検索結果のうち、取得したいページの番号(1始まり) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 1 - maximum: 200 - default: 30 - - name: task_id - in: query - description: タスクIDでの部分一致検索で使用。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId - - name: input_data_ids - in: query - description: 指定された入力データIDを使用しているタスクを絞り込みます。カンマ区切りで複数の入力データIDを指定可能です。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId - - name: phase - in: query - description: 絞り込み条件となるフェーズ名。未指定時は全フェーズ - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhase - - name: phase_stage - in: query - description: 絞り込み条件となるステージ。未指定時は全ステージ - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhaseStage - - name: status - in: query - description: 絞り込み条件となる状態名。未指定時は全ステータス。 - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskStatus - - name: account_id - in: query - description: 絞り込み条件となる作業中のアカウントID。未指定時は全アカウント - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId - - name: no_user - in: query - description: 未割り当てのタスクを絞り込む時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string - - name: previous_account_id - in: query - description: そのタスクをこれまでに担当したことのあるユーザー(現在の担当者含む)のアカウントID。未指定時は全ユーザ - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AccountId - - name: previous_phase - in: query - description: そのタスクがこれまでに遷移したことのあるフェーズ名(現在のフェーズ含む)。未指定時は全フェーズ - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhase - - name: previous_phase_stage - in: query - description: そのタスクがこれまでに遷移したことのあるステージ(現在のステージ含む)。未指定時は全ステージ - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskPhaseStage - - name: rejected_only - in: query - description: 差し戻されたタスクだけを絞り込む時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string - - name: auto_accepted_only - in: query - description: 「抜取検査の対象外となり、自動受入されたタスク」だけを絞り込む時に、キーのみ指定します(値は無視されます)。 - required: false - allowEmptyValue: true - schema: - type: string - - name: sort - in: query - description: > - ソート順の指定。 - - 使用可能キーはtask_id、updated_datetime、number_of_rejections、phase、phase_stage、status、account_idのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 - - 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 - required: false - example: account_id,-updated_datetime - schema: - type: string + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: page + in: query + description: 検索結果のうち、取得したいページの番号(1始まり) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 1 + maximum: 200 + default: 30 + - name: task_id + in: query + description: タスクIDでの部分一致検索で使用。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" + - name: input_data_ids + in: query + description: 指定された入力データIDを使用しているタスクを絞り込みます。カンマ区切りで複数の入力データIDを指定可能です。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" + - name: phase + in: query + description: 絞り込み条件となるフェーズ名。未指定時は全フェーズ + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskPhase" + - name: phase_stage + in: query + description: 絞り込み条件となるステージ。未指定時は全ステージ + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskPhaseStage" + - name: status + in: query + description: 絞り込み条件となる状態名。未指定時は全ステータス。 + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskStatus" + - name: account_id + in: query + description: 絞り込み条件となる作業中のアカウントID。未指定時は全アカウント + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/AccountId" + - name: no_user + in: query + description: 未割り当てのタスクを絞り込む時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string + - name: previous_account_id + in: query + description: そのタスクをこれまでに担当したことのあるユーザー(現在の担当者含む)のアカウントID。未指定時は全ユーザ + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/AccountId" + - name: previous_phase + in: query + description: そのタスクがこれまでに遷移したことのあるフェーズ名(現在のフェーズ含む)。未指定時は全フェーズ + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskPhase" + - name: previous_phase_stage + in: query + description: そのタスクがこれまでに遷移したことのあるステージ(現在のステージ含む)。未指定時は全ステージ + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskPhaseStage" + - name: rejected_only + in: query + description: 差し戻されたタスクだけを絞り込む時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string + - name: auto_accepted_only + in: query + description: 「抜取検査の対象外となり、自動受入されたタスク」だけを絞り込む時に、キーのみ指定します(値は無視されます)。 + required: false + allowEmptyValue: true + schema: + type: string + - name: sort + in: query + description: | + ソート順の指定。 + 使用可能キーはtask_id、updated_datetime、number_of_rejections、phase、phase_stage、status、account_idのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 + 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 + required: false + example: account_id,-updated_datetime + schema: + type: string + - name: annotation + in: query + description: アノテーションの絞り込み条件をJSON形式で指定したもの。指定した条件に合致するアノテーションを持つタスクを絞り込む際に指定する。 + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/AnnotationQuery" responses: "200": description: 指定された条件にあてはまるタスクを返します。条件にあてはまるタスクが多数に及ぶことがあるので、すべての結果を得るにはページングしてください。 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskList + $ref: "swagger-api-components.yaml#/components/schemas/TaskList" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" post: tags: - - af-task + - af-task summary: タスク一括更新 description: | タスクを一括更新します。 @@ -3214,15 +3087,15 @@ paths: 複数の操作のうち、1つでも失敗するとAPIのレスポンス全体としては失敗になります。 成功した部分までは反映されます。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: batchUpdateTasks parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" requestBody: required: true content: @@ -3230,7 +3103,7 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/BatchTaskRequestItem + $ref: "swagger-api-components.yaml#/components/schemas/BatchTaskRequestItem" responses: "200": description: 正常 @@ -3239,73 +3112,55 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + $ref: "swagger-api-components.yaml#/components/schemas/Task" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": + # TODO Error定義構造化(KRSANNOFAC-1502) description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + $ref: "swagger-api-components.yaml#/components/schemas/Errors" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/generate-tasks": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/generate-tasks: post: tags: - - af-task + - af-task summary: タスク一括作成 - description: > + description: | 典型的なタスク作成ルールにもとづいた、一括作成を行うAPIです。 - タスク作成ルールは、リクエストペイロードの `task_generate_rule` フィールドで指定できます。
- `ByCount` を指定した場合、1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。この作成ルールは、画像を同じ枚数均等にタスクに割り振りたい場合に便利です。
- `ByDirectory` を指定した場合、入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。この作成ルールは、動画などから切り出した画像をディレクトリ別に格納し、、その動画(ディレクトリ)の単位でタスクを作りたい場合に便利です。 - `ByInputDataCsv` を指定した場合、入力データを各タスクに割り振ったCSVへのS3パスを指定してタスクを生成できます。この作成ルールは特定のデータの組み合わせを持ったタスクを作成したい場合に便利です。
- 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-tasks`)。 - #### ByDirectory: ディレクトリ単位でのタスク一括生成の使い方 - 例えば、次のような `input_data_name_` の入力データが登録されているとします。 - * a.zip/dir1/image1.png - * a.zip/dir1/image2.png - * a.zip/dir1/subdir/image3.png - * a.zip/dir1/subdir/image4.png - * a.zip/dir1/subdir/image5.png - * b.zip/dir2/subdir1/image6.png - * b.zip/dir2/subdir1/image7.png - * b.zip/dir2/subdir1/image8.png - * b.zip/dir2/subdir2/image9.png - * b.zip/dir2/subdir2/image10.png - ここで、`input_data_name_prefix`フィールド に `a.zip` を指定すると、次の2タスクが生成されます。 - 1. タスク: `{task_id_prefix}_a.zip_dir1` * a.zip/dir1/image1.png * a.zip/dir1/image2.png @@ -3316,7 +3171,6 @@ paths: 次に、`input_data_name_prefix` に `b.zip/dir2` を指定すると、次の2タスクが生成されます。 - 1. タスク: `{task_id_prefix}_b.zip_dir2_subdir1` * b.zip/dir2/subdir1/image6.png * b.zip/dir2/subdir1/image7.png @@ -3327,7 +3181,6 @@ paths: `input_data_name_prefix` が未指定の時は、全ディレクトリごとにタスクが作成されます。つまり次のように4つのタスクが生成されます。 - 1. タスク: `{task_id_prefix}_a.zip_dir1` * a.zip/dir1/image1.png * a.zip/dir1/image2.png @@ -3344,237 +3197,213 @@ paths: * b.zip/dir2/subdir2/image10.png 画像プロジェクトの場合、タスクに割り当てられる「ディレクトリ内の入力データ」の順序は、名前の昇順となります。
- 動画プロジェクトの場合、タスクに割り当てられる「ディレクトリ内の入力データ」の順序は、動画の入力データが先頭に来るようにソートされたうえで、名前の昇順となります。 - **注意:** `ByDirectory`では、入力データ名がファイルパス形式になっていない入力データはタスクの作成対象になりません。 - 例えば、`foo/bar.png` はタスクの作成対象になりますが、ディレクトリを含まない`bar.png` や、最後がディレクトリになっている`foo/bar.png/` は対象になりません。 - **注意:** 動画プロジェクトの場合、ディレクトリに含まれる動画の入力データは一つに制限してください。 - これが守られない場合、作成されたタスクで動画を再生できない場合があります。 - #### ByInputDataCsv: CSVによるタスク一括生成の使い方 - 以下のように「タスクID,入力データ名,入力データID」を1行毎に指定したCSVを作成します。 - ``` - task_1,a001.jpg,ca0cb2f9-fec5-49b4-98df-dc34490f9785 - task_1,a002.jpg,5ac1987e-ca7c-42a0-9c19-b5b23a41836b - task_1,centinel.jpg,81d6407b-2172-4fa8-8525-2e43c49267ee - task_2,b001.jpg,4f2ae4d0-7a38-4f9a-be6f-170ba76aba73 - task_2,b002.jpg,45ac5852-f20c-4938-9ee9-cc0274401df7 - task_2,centinel.jpg,81d6407b-2172-4fa8-8525-2e43c49267ee - task_3,c001.jpg,3260c7a0-4820-424d-a26e-db7e91dbc139 - task_3,centinel.jpg,81d6407b-2172-4fa8-8525-2e43c49267ee - ``` - CSVのエンコーディングは UTF-8(BOM付き)、UTF-8(BOMなし)、UTF-16(BOM付きLE) のいずれかのみ対応しています。 - **注意:** 動画プロジェクトの場合、一つのタスクに含まれる動画の入力データは一つに制限し、動画の入力データの位置は先頭にしてください。 - これが守られない場合、作成されたタスクで動画を再生できない場合があります。 - [createTempPath](#operation/createTempPath) APIを使ってアップロード用のURLとS3パスを取得してCSVをアップロードした上で`csv_data_path` フィールドに取得したS3パスを記述します。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: initiateTasksGeneration parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: v - in: query - description: | - APIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":Project - - "2":TaskGenerateResponse - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Project + - "2":TaskGenerateResponse + required: false + schema: + type: string + default: "1" + example: "2" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskGenerateRequest + $ref: "swagger-api-components.yaml#/components/schemas/TaskGenerateRequest" responses: "202": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskGenerateResponseWrapper + $ref: "swagger-api-components.yaml#/components/schemas/TaskGenerateResponseWrapper" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "409": description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/tasks/{task_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/tasks/{task_id}: get: tags: - - af-task + - af-task summary: タスク取得 description: | 個々のタスクの情報を取得します。 タスクを割り当てる場合は、[タスク割当](#operation/startTask)を使います。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + $ref: "swagger-api-components.yaml#/components/schemas/Task" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-task + - af-task summary: タスク作成/更新 - description: > + description: | 1つのタスクを作成または更新します。 - 複数のタスクを一括生成する場合は、効率のよい[一括作成API](#operation/initiateTasksGeneration)を検討してください。 - このAPIで変更できるのは、タスクの入力データ(`input_data_list`)のみです。タスクに割り当てた画像や動画などの入力データを差し替えることができます。 - タスクの担当者やステータスを変更するには、[タスク割当](#operation/startTask)や[タスクの状態遷移](#operation/operateTask)を使用します。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: | - タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: | + タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskRequest + $ref: "swagger-api-components.yaml#/components/schemas/TaskRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + $ref: "swagger-api-components.yaml#/components/schemas/Task" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "409": description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" delete: tags: - - af-task + - af-task summary: タスク削除 description: | 不要になったタスクや、間違って投入したタスクを削除します。教師データなどは削除せず残すので、あとから復元することも可能です。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" responses: "200": description: 正常。削除したタスクを返します content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + $ref: "swagger-api-components.yaml#/components/schemas/Task" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/assign-tasks": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/assign-tasks: post: tags: - af-task @@ -3592,13 +3421,13 @@ paths: description: プロジェクトID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskAssignRequest + $ref: "swagger-api-components.yaml#/components/schemas/TaskAssignRequest" responses: "200": description: 正常。割当したタスクを返します。 @@ -3607,33 +3436,31 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + $ref: "swagger-api-components.yaml#/components/schemas/Task" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": description: プロジェクトが停止中のため、タスクの割当ができない。 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/tasks/{task_id}/operate": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/tasks/{task_id}/operate: post: tags: - - af-task + - af-task summary: タスク状態変更 - description: > + description: | タスクの状態、もしくはタスクの担当者を変更することができます。 - #### ユースケースごとの使い方 - * タスクを作業中(working)にしたい場合 * 制約 * 現在タスクを担当しているユーザーのみ、この操作を行うことができます。 @@ -3701,108 +3528,108 @@ paths: * リクエストボディのJSONサンプル * ```{ status: "not_started", last_updated_datetime: "2018-08-14T19:01:51.775+09:00"}``` security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: operateTask parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskOperation + $ref: "swagger-api-components.yaml#/components/schemas/TaskOperation" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Task + $ref: "swagger-api-components.yaml#/components/schemas/Task" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": description: 指定された現在の状態が実際の現在の状態と食い違っている content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorStateMismatch + $ref: "swagger-api-components.yaml#/components/schemas/ErrorStateMismatch" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/tasks/{task_id}/validation": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/tasks/{task_id}/validation: get: deprecated: true tags: - - af-task + - af-task summary: タスク自動検査 description: | 指定したタスクの自動検査で見つかった警告やエラーを一括で取得します。 [タスクの状態遷移](#operation/operateTask)の際に検査を行うようになったので、本APIは非推奨となります。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTaskValidation parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskValidation + $ref: "swagger-api-components.yaml#/components/schemas/TaskValidation" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/tasks/{task_id}/histories": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/tasks/{task_id}/histories: get: tags: - - af-task + - af-task summary: タスク履歴一括取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getTaskHistories parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" responses: "200": description: 正常 @@ -3811,87 +3638,86 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskHistory + $ref: "swagger-api-components.yaml#/components/schemas/TaskHistory" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/annotations": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/annotations: get: tags: - - af-annotation + - af-annotation summary: アノテーション一括取得 - description: 指定したタスク-入力データにつけられたアノテーションを一括で取得します。 + description: + 指定したタスク-入力データにつけられたアノテーションを一括で取得します。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAnnotationList parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: page - in: query - description: 検索結果のうち、取得したいページの番号(1始まり) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 1 - maximum: 200 - default: 30 - - name: aggregate_by_task_and_input - in: query - description: trueを指定した場合に「タスクIDと入力IDの組」ごとに検索結果を集計するようにする。 - required: false - schema: - type: boolean - default: false - - name: query - in: query - description: | - 絞り込み条件([AnnotationQuery](#section/AnnotationQuery))をJSON形式で表した文字列。 - required: false - example: '{"label_id":"b048c6b3-b36f-4c8d-97ea-96828a50a44c"}' - schema: - type: string - - name: sort - in: query - description: > - ソート順の指定。 - - 使用可能キーはtask_id, input_data_id, detail.annotation_id, detail.account_id, detail.label_id, detail.data_holding_type, detail.created_datetime, detail.updated_datetimeのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 - - 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 - required: false - example: task_id,input_data_id,detail.annotation_id,-detail.updated_datetime - schema: - type: string + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: page + in: query + description: 検索結果のうち、取得したいページの番号(1始まり) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 1 + maximum: 200 + default: 30 + - name: aggregate_by_task_and_input + in: query + description: trueを指定した場合に「タスクIDと入力IDの組」ごとに検索結果を集計するようにする。 + required: false + schema: + type: boolean + default: false + - name: query + in: query + description: | + 絞り込み条件([AnnotationQuery](#section/AnnotationQuery))をJSON形式で表した文字列。 + required: false + example: '{"label_id":"b048c6b3-b36f-4c8d-97ea-96828a50a44c"}' + schema: + type: string + - name: sort + in: query + description: | + ソート順の指定。 + 使用可能キーはtask_id, input_data_id, detail.annotation_id, detail.account_id, detail.label_id, detail.data_holding_type, detail.created_datetime, detail.updated_datetimeのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 + 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 + required: false + example: task_id,input_data_id,detail.annotation_id,-detail.updated_datetime + schema: + type: string responses: "200": description: 指定された条件にあてはまるアノテーションを返します。条件にあてはまるアノテーションが多数に及ぶことがあるので、すべての結果を得るにはページングしてください。 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/AnnotationList + $ref: "swagger-api-components.yaml#/components/schemas/AnnotationList" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" post: tags: - - af-annotation + - af-annotation summary: アノテーション一括更新 description: | 複数のアノテーションを一括更新します。 @@ -3918,15 +3744,15 @@ paths: 受入が完了しているタスクのアノテーション更新を含む場合、オーナー以上の権限が必要になります。 security: - - ProjectAccepter: [] + - ProjectAccepter: [] operationId: batchUpdateAnnotations parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" requestBody: required: true content: @@ -3934,7 +3760,7 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/BatchAnnotationRequestItem + $ref: "swagger-api-components.yaml#/components/schemas/BatchAnnotationRequestItem" responses: "200": description: 正常 @@ -3943,38 +3769,35 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/SingleAnnotation + $ref: "swagger-api-components.yaml#/components/schemas/SingleAnnotation" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": + # TODO Error定義構造化(KRSANNOFAC-1502) description: 停止中プロジェクトに対する操作、または、先に更新されているため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + $ref: "swagger-api-components.yaml#/components/schemas/Errors" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/annotation": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/annotation: get: tags: - af-annotation summary: タスク/入力データのアノテーション一括取得 - description: > + description: | [putAnnotation](#operation/putAnnotation)が要求する構造のアノテーションを取得します。 - このAPIは、[putAnnotation](#operation/putAnnotation)をより利用しやすくする目的で提供しています。 - 機械学習などで利用する成果物としてのアノテーションを取得するには、以下をご利用いただけます。 - * [getAnnotation](#operation/getAnnotation): 特定のタスク - 入力データのアノテーション取得 - * [getAnnotationArchive](#operation/getAnnotationArchive): プロジェクト全体のアノテーション(ZIP) security: - AllProjectMember: [] @@ -3985,185 +3808,171 @@ paths: description: プロジェクトID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" - name: task_id in: path description: タスクID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" - name: input_data_id in: path description: 入力データID required: true schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Annotation + $ref: "swagger-api-components.yaml#/components/schemas/Annotation" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-annotation + - af-annotation summary: タスク-入力データのアノテーション更新 - description: > + description: | 「過去に誰にも割り当てられていないタスクに含まれる入力データ」に限り、プロジェクトオーナーであればアノテーションを更新できます。 - この挙動は、[AnnoFab外部で作成されたアノテーションをインポート](/docs/tutorial/tutorial-ex-importing-annotation.html) する目的にも利用できます。 - 1度でも誰かに割り当てられたタスクは、タスクの現在の担当者であればアノテーションを更新できます。 - タスクの現在の担当者でない場合、エラーになります。 - この制限は、アノテーション作業中の予期せぬ同時編集を防ぐためです。 - `is_protected`(保護) を `true` にすることで、アノテーションをアノテーションエディタ上での削除から保護できます。 - 属性の変更もさせたくない場合は、アノテーション仕様で特定の属性を読取専用にすることで保護できます。保護は、 - * 外部からインポートしたアノテーション - * 別プロジェクトからコピーしたアノテーション - などを誤って削除したくないときに便利です。 - `is_protected`は、プロジェクトオーナーのみ変更可能です。 - なお、本APIでは `is_protected` によらず、更新や削除が可能です。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: putAnnotation parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Annotation + $ref: "swagger-api-components.yaml#/components/schemas/Annotation" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Annotation + $ref: "swagger-api-components.yaml#/components/schemas/Annotation" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": + # TODO Error定義構造化(KRSANNOFAC-1502) description: 停止中プロジェクトに対する操作、または、先に更新されているため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + $ref: "swagger-api-components.yaml#/components/schemas/Errors" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/annotation/simple": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/annotation/simple: get: tags: - - af-annotation + - af-annotation summary: タスク-入力データのSimpleアノテーション一括取得 - description: > + description: | 指定したタスク - 入力データにつけられたアノテーションを一括で取得します。 - Simple版のアノテーションJSONは、機械学習の一般的な利用で扱いやすい構造になっています。 - なお、プロジェクト全体のアノテーションを一括で取得したい場合には、 [getAnnotationArchive](#operation/getAnnotationArchive) APIを使用することもできます。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getAnnotation parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/SimpleAnnotation + $ref: "swagger-api-components.yaml#/components/schemas/SimpleAnnotation" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/archive/full": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/archive/full: get: tags: - - af-annotation + - af-annotation summary: FullアノテーションZIP取得 - description: > + description: | プロジェクト内のアノテーション(Full版)がまとめられたZIPを取得するための、認証済み一時URLを取得します。 - 取得したURLは1時間で失効し、アクセスできなくなります。 - FullアノテーションZIPのデータ構造については、 [Full Annotation ZIP](#section/Full-Annotation-ZIP) を参照ください。 security: - - ProjectDataUser: [] - operationId: getArchiveFullWithProId + - ProjectDataUser: [] + operationId: getArchiveFullWithProId #getFullAnnotationArchiveByProjectId parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -4175,51 +3984,45 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + $ref: "swagger-api-components.yaml#/components/schemas/TemporaryUrl" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/archive/simple": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/archive/simple: get: tags: - - af-annotation + - af-annotation summary: SimpleアノテーションZIP取得 - description: > + description: | プロジェクト内のアノテーション(Simple版)がまとめられたZIPを取得するための、認証済み一時URLを取得します。 - 取得したURLは1時間で失効し、アクセスできなくなります。 - SimpleアノテーションZIPのデータ構造については、 [Simple Annotation ZIP](#section/Simple-Annotation-ZIP) を参照ください。 - なお、特定のタスクのSimpleアノテーションを取得したい場合には、 [getAnnotation](#operation/getAnnotation) APIを使用することもできます。 security: - - ProjectDataUser: [] + - ProjectDataUser: [] operationId: getAnnotationArchive parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: v2 - in: query - description: > - このクエリパラメータのキーだけを指定(`?v2`)、または値 `true` - も指定(`?v2=true`)すると、アノテーションJSONのファイル名は `{入力データID}.json` になります。 - - この v2 形式は、入力データ名がファイル名の長さ上限を上回ってもよいように再設計されたものです。 - - 以前の v1 形式(アノテーションJSONのファイル名は `{入力データ名}.json` )はいずれ廃止され、クエリパラメータ `v2` があってもなくても v2 形式に置き換わる予定です。 - required: false - schema: - type: string - example: "true" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: v2 + in: query + description: | + このクエリパラメータのキーだけを指定(`?v2`)、または値 `true` も指定(`?v2=true`)すると、アノテーションJSONのファイル名は `{入力データID}.json` になります。 + この v2 形式は、入力データ名がファイル名の長さ上限を上回ってもよいように再設計されたものです。 + 以前の v1 形式(アノテーションJSONのファイル名は `{入力データ名}.json` )はいずれ廃止され、クエリパラメータ `v2` があってもなくても v2 形式に置き換わる予定です。 + required: false + schema: + type: string + example: "true" responses: "200": description: 正常 @@ -4231,90 +4034,88 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TemporaryUrl + $ref: "swagger-api-components.yaml#/components/schemas/TemporaryUrl" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/archive/update": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/archive/update: post: tags: - - af-annotation + - af-annotation summary: アノテーションZIP更新開始 - description: > + description: | プロジェクト内のアノテーションZIP(Simple版とFull版の両方)の更新を開始します。 - ZIPの更新は、データ量に応じて数分〜数十分かかります。 - アノテーションZIPは毎日AM 03:00 JSTごろに自動更新されますが、本APIを用いると、自動更新を待たずに更新を要求できます。 - 本APIを実行すると、バックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-annotation`)。 + security: - - ProjectDataUser: [] + - ProjectDataUser: [] operationId: postAnnotationArchiveUpdate parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: v - in: query - description: | - APIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":Message - - "2":PostAnnotationArchiveUpdateResponse - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: v + in: query + description: | + APIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":Message + - "2":PostAnnotationArchiveUpdateResponse + required: false + schema: + type: string + default: "1" + example: "2" responses: "202": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/PostAnnotationArchiveUpdateResponseWrapper + $ref: "swagger-api-components.yaml#/components/schemas/PostAnnotationArchiveUpdateResponseWrapper" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/inspections": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/tasks/{task_id}/inputs/{input_data_id}/inspections: get: tags: - - af-inspection + - af-inspection summary: 検査コメント一括取得 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInspections parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" responses: "200": description: 正常 @@ -4323,14 +4124,14 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Inspection + $ref: "swagger-api-components.yaml#/components/schemas/Inspection" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" post: tags: - - af-inspection + - af-inspection summary: 検査コメント一括更新 description: | 検査コメントを一括更新します。 @@ -4344,27 +4145,27 @@ paths: 複数の操作のうち、1つでも失敗するとAPIのレスポンス全体としては失敗になります。 成功した部分までは反映されます。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: batchUpdateInspections parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: task_id - in: path - description: タスクID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/TaskId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: task_id + in: path + description: タスクID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/TaskId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" requestBody: required: true content: @@ -4372,7 +4173,7 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/BatchInspectionRequestItem + $ref: "swagger-api-components.yaml#/components/schemas/BatchInspectionRequestItem" responses: "200": description: 正常 @@ -4381,110 +4182,111 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Inspection + $ref: "swagger-api-components.yaml#/components/schemas/Inspection" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": + # TODO Error定義構造化(KRSANNOFAC-1502) description: 停止中プロジェクトに対する操作、または、先に更新されているため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + $ref: "swagger-api-components.yaml#/components/schemas/Errors" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/inputs": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/inputs: get: tags: - - af-input + - af-input summary: 入力データ一括取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInputDataList parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: input_data_id - in: query - description: 入力データIDでの部分一致検索で使用。1文字以上あれば使用します。 - required: false - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId - - name: input_data_name - in: query - description: 入力データ名での部分一致検索で使用。1文字以上あれば使用します。 - required: false - schema: - type: string - - name: input_data_path - in: query - description: 入力データパスでの部分一致検索で使用。1文字以上あれば使用します。 - required: false - schema: - type: string - - name: task_id - in: query - description: 入力データが紐づくタスクIDの部分一致検索で使用。1文字以上あれば使用します。条件に合致した先頭100件のタスクに使われている入力データを検索します。 - required: false - schema: - type: string - - name: from - in: query - description: 更新日時での範囲検索で使用(ISO 8601 拡張形式) - required: false - schema: - type: string - format: date-time - - name: to - in: query - description: 更新日時での範囲検索で使用(ISO 8601 拡張形式) - required: false - schema: - type: string - format: date-time - - name: page - in: query - description: 検索結果のうち、取得したいページの番号(1始まり) - required: false - schema: - type: integer - minimum: 1 - default: 1 - - name: limit - in: query - description: 1ページあたりの取得するデータ件数 - required: false - schema: - type: integer - minimum: 1 - maximum: 200 - default: 30 + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: input_data_id + in: query + description: 入力データIDでの部分一致検索で使用。1文字以上あれば使用します。 + required: false + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" + - name: input_data_name + in: query + description: 入力データ名での部分一致検索で使用。1文字以上あれば使用します。 + required: false + schema: + type: string + - name: input_data_path + in: query + description: 入力データパスでの部分一致検索で使用。1文字以上あれば使用します。 + required: false + schema: + type: string + - name: task_id + in: query + description: 入力データが紐づくタスクIDの部分一致検索で使用。1文字以上あれば使用します。条件に合致した先頭100件のタスクに使われている入力データを検索します。 + required: false + schema: + type: string + - name: from + in: query + description: 更新日時での範囲検索で使用(ISO 8601 拡張形式) + required: false + schema: + type: string + format: date-time + - name: to + in: query + description: 更新日時での範囲検索で使用(ISO 8601 拡張形式) + required: false + schema: + type: string + format: date-time + - name: page + in: query + description: 検索結果のうち、取得したいページの番号(1始まり) + required: false + schema: + type: integer + minimum: 1 + default: 1 + - name: limit + in: query + description: 1ページあたりの取得するデータ件数 + required: false + schema: + type: integer + minimum: 1 + maximum: 200 + default: 30 responses: "200": description: 指定された条件にあてはまる入力データを返します。条件にあてはまる入力データが多数に及ぶことがあるので、すべての結果を得るにはページングしてください。 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataList + $ref: "swagger-api-components.yaml#/components/schemas/InputDataList" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" post: tags: - - af-input + - af-input summary: 入力データ一括更新 description: | 入力データを一括更新します。 @@ -4495,15 +4297,15 @@ paths: 複数の操作のうち、1つでも失敗するとAPIのレスポンス全体としては失敗になります。 成功した部分までは反映されます。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: batchUpdateInputs parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" requestBody: required: true content: @@ -4511,7 +4313,7 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/BatchInputDataRequestItem + $ref: "swagger-api-components.yaml#/components/schemas/BatchInputDataRequestItem" responses: "200": description: 正常 @@ -4520,88 +4322,79 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData + $ref: "swagger-api-components.yaml#/components/schemas/InputData" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": + # TODO Error定義構造化(KRSANNOFAC-1502) description: 停止中プロジェクトに対する操作のため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Errors + $ref: "swagger-api-components.yaml#/components/schemas/Errors" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/inputs/{input_data_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/inputs/{input_data_id}: get: tags: - - af-input + - af-input summary: 入力データ取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInputData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData + $ref: "swagger-api-components.yaml#/components/schemas/InputData" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-input + - af-input summary: | 入力データ更新 - description: > + description: | 入力データ(画像プロジェクトなら画像、動画プロジェクトなら動画や時系列データ)を登録します。 - 画像プロジェクトの場合、複数の画像ファイルをZIPでまとめてアップロードできます。ZIPは最大5GB、UTF-8エンコーディングのみ対応しています。
- アノテーション作業生産性を高めるため、画像は「長辺4096px以内」かつ「4MB以内」になるよう圧縮されます。
- 作成されるアノテーションは、元の解像度でつけた場合相当に自動で復元されます。 - 動画プロジェクトの場合、複数の動画ファイルをZIPでまとめてアップロードできます。ZIPは最大5GB、UTF-8エンコーディングのみ対応しています。
- また、複数のストリーミング形式の動画をアップロードすることもできます。
- この場合はZIP形式必須で、同一のZIPファイル内にm3u8ファイルとtsファイルを両方含めてください。
- なお、このm3u8ファイルに記述された相対パスでtsファイルが参照可能である必要があります。 - ZIPファイルを登録するとバックグラウンドジョブが登録されます。ジョブは [getProjectJob](#operation/getProjectJob) APIで確認できます(ジョブ種別は`gen-inputs`)。 - ### ディレクトリ例 - ``` hoge.zip/ hoge.ts @@ -4615,134 +4408,133 @@ paths: bar.m3u8(hoge.ts, piyo1/piyo2/bar.tsを参照) ``` - ファイルの登録には、[アップロード用一時データ保存先作成API](#operation/createTempPath) を組み合わせて使用します。 security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putInputData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: input_data_id - in: path - description: | - 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId - - name: v - in: query - description: | - zipファイルを受領時のAPIの戻り型のバージョンを指定します。 - 値と戻り型の対応は以下です。 - - "1":登録処理を開始した旨の固定メッセージ - - "2":JobInfo - required: false - schema: - type: string - default: "1" - example: "2" + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: input_data_id + in: path + description: | + 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" + - name: v + in: query + description: | + zipファイルを受領時のAPIの戻り型のバージョンを指定します。 + 値と戻り型の対応は以下です。 + - "1":登録処理を開始した旨の固定メッセージ + - "2":JobInfo + required: false + schema: + type: string + default: "1" + example: "2" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataRequest + $ref: "swagger-api-components.yaml#/components/schemas/InputDataRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData + $ref: "swagger-api-components.yaml#/components/schemas/InputData" "202": description: zipファイルを受領、バッチにて登録開始。 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/MessageOrJobInfo + $ref: "swagger-api-components.yaml#/components/schemas/MessageOrJobInfo" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "409": description: 先に更新されているため失敗 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ErrorAlreadyUpdated + $ref: "swagger-api-components.yaml#/components/schemas/ErrorAlreadyUpdated" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" delete: tags: - - af-input + - af-input summary: 入力データ削除 - description: "" + description: | security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteInputData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" responses: "200": description: 正常。削除した入力データを返します content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputData + $ref: "swagger-api-components.yaml#/components/schemas/InputData" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "403": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorForbiddenResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorForbiddenResource" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/inputs/{input_data_id}/data": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/inputs/{input_data_id}/data: get: deprecated: true tags: - - af-input + - af-input summary: 実体参照用認証済みURL取得 description: | 入力データの実体(画像や動画などのファイルそのもの)にアクセスするための、認証済み一時URLを取得します。 取得したURLは、1時間で失効し、アクセスできなくなります。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getSignedUrlOfInputData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" responses: "200": description: 正常 @@ -4757,33 +4549,33 @@ paths: type: string description: 認証済み一時URL "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/inputs/{input_data_id}/supplementary-data": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/inputs/{input_data_id}/supplementary-data: get: tags: - - af-supplementary + - af-supplementary summary: 補助情報一括取得 - description: "" + description: | security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getSupplementaryDataList parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" responses: "200": description: 正常 @@ -4792,109 +4584,107 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryData + $ref: "swagger-api-components.yaml#/components/schemas/SupplementaryData" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/inputs/{input_data_id}/supplementary-data/{supplementary_data_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/inputs/{input_data_id}/supplementary-data/{supplementary_data_id}: put: tags: - - af-supplementary + - af-supplementary summary: 補助情報作成/更新 - description: "" + description: | security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: putSupplementaryData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId - - name: supplementary_data_id - in: path - description: 補助情報ID(プロジェクトIDとの2つ組で一意となる値) - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" + - name: supplementary_data_id + in: path + description: 補助情報ID(プロジェクトIDとの2つ組で一意となる値) + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/SupplementaryDataId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryDataRequest + $ref: "swagger-api-components.yaml#/components/schemas/SupplementaryDataRequest" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryData + $ref: "swagger-api-components.yaml#/components/schemas/SupplementaryData" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" delete: tags: - - af-supplementary + - af-supplementary summary: 補助情報削除 - description: "" + description: | security: - - ProjectOwner: [] + - ProjectOwner: [] operationId: deleteSupplementaryData parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: input_data_id - in: path - description: 入力データID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InputDataId - - name: supplementary_data_id - in: path - description: 補助情報ID(プロジェクトIDとの2つ組で一意となる値) - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/SupplementaryDataId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: input_data_id + in: path + description: 入力データID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/InputDataId" + - name: supplementary_data_id + in: path + description: 補助情報ID(プロジェクトIDとの2つ組で一意となる値) + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/SupplementaryDataId" responses: "200": description: 正常 "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/create-temp-path": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/create-temp-path: post: tags: - - af-input + - af-input summary: 一時データ保存先取得 - description: > + description: | 「複数の入力データを圧縮したZIPファイル」や「4MBを超える画像」などをAnnoFabに一時的に保存するための、URLと登録用データパスを発行します。 - このAPIと他のAPIを以下に示すように使うことで、ZIPファイルなどをAFにアップロードできます。 - 1. 本APIを実行して、URLを取得する。 * `curl -X POST -H 'Content-Type: {CONTENT_TYPE_HERE}' 'https://annofab.com/api/v1/projects/{project_id}/create-temp-path'` 2. 1で取得したURLに、一時保存したいファイルをPUTする。 @@ -4903,30 +4693,27 @@ paths: * `curl -X PUT -H 'Content-Type: text/json' -d '{"input_data_name":"{表示名}", "input_data_path":"{登録用データパス}" }' 'https://annofab.com/api/v1/projects/{project_id}/inputs/{input_data_id}'` ここで、1と2で `CONTENT_TYPE_HERE` は必ず一致しなければいけません。 - ZIPファイルの場合は `application/zip` 、画像ファイルの場合は `image/png` など、適切な Content-Type を指定します。 - 登録するファイルはどのような内容であれ、アップロードから24時間経過すると削除されます。 - したがって、ZIP圧縮した入力データを登録する場合は、URL発行から24時間以内に完了してください。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: createTempPath parameters: - - in: header - name: Content-Type - schema: - type: string - example: application/zip - description: | - アップロードしたいファイルの Content-Type を指定します。 - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - in: header + name: Content-Type + schema: + type: string + example: "application/zip" + description: | + アップロードしたいファイルの Content-Type を指定します。 + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: | @@ -4934,107 +4721,107 @@ paths: content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/DataPath + $ref: "swagger-api-components.yaml#/components/schemas/DataPath" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/instruction": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/instruction: get: tags: - - af-instruction + - af-instruction summary: 作業ガイドの取得 description: | 指定された版の作業ガイドのHTMLを取得します。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInstruction parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: history_id - in: query - description: 取得する版の履歴ID - required: true - schema: - type: string - example: ed55914c-9f04-470e-8af2-373c8def3e8b + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: history_id + in: query + description: 取得する版の履歴ID + required: true + schema: + type: string + example: "ed55914c-9f04-470e-8af2-373c8def3e8b" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Instruction + $ref: "swagger-api-components.yaml#/components/schemas/Instruction" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" put: tags: - - af-instruction + - af-instruction summary: 作業ガイドの更新 description: | 作業ガイドのHTMLを更新します。 security: - - ProjectOwner: [] - - ProjectAccepter: [] + - ProjectOwner: [] + - ProjectAccepter: [] operationId: putInstruction parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" requestBody: required: true content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/Instruction + $ref: "swagger-api-components.yaml#/components/schemas/Instruction" responses: "200": description: 作業ガイドの更新が成功した。 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InstructionHistory + $ref: "swagger-api-components.yaml#/components/schemas/InstructionHistory" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/instruction-history": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/instruction-history: get: tags: - - af-instruction + - af-instruction summary: 作業ガイドの編集履歴の取得 description: | プロジェクトの作業ガイドの編集履歴を取得します。 取得される編集履歴は日付の新しい順にソートされます。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInstructionHistory parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: limit - in: query - description: 取得する編集履歴の件数 - required: false - schema: - type: integer - minimum: 30 + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: limit + in: query + description: 取得する編集履歴の件数 + required: false + schema: + type: integer + minimum: 30 responses: "200": description: 正常 @@ -5043,32 +4830,32 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InstructionHistory + $ref: "swagger-api-components.yaml#/components/schemas/InstructionHistory" "400": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorInvalidRequest + $ref: "swagger-api-components.yaml#/components/responses/ErrorInvalidRequest" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/instruction-images": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/instruction-images: get: tags: - - af-instruction + - af-instruction summary: 作業ガイドの画像一覧の取得 description: | プロジェクトの作業ガイドの画像一覧を取得します。 security: - - AllProjectMember: [] + - AllProjectMember: [] operationId: getInstructionImages parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" responses: "200": description: 正常 @@ -5077,103 +4864,101 @@ paths: schema: type: array items: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InstructionImage + $ref: "swagger-api-components.yaml#/components/schemas/InstructionImage" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/instruction-images/{image_id}": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/instruction-images/{image_id}: delete: tags: - - af-instruction + - af-instruction summary: 作業ガイドの画像削除 description: | プロジェクトの作業ガイドの画像を削除します。 security: - - ProjectOwner: [] - - ProjectAccepter: [] + - ProjectOwner: [] + - ProjectAccepter: [] operationId: deleteInstructionImage parameters: - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: image_id - in: path - description: 作業ガイド画像ID - required: true - schema: - type: string - example: ed55914c-9f04-470e-8af2-373c8def3e8b + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: image_id + in: path + description: 作業ガイド画像ID + required: true + schema: + type: string + example: "ed55914c-9f04-470e-8af2-373c8def3e8b" responses: "200": description: 正常 "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance - "/projects/{project_id}/instruction-images/{image_id}/put-url": + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" + /projects/{project_id}/instruction-images/{image_id}/put-url: get: tags: - - af-instruction + - af-instruction summary: 作業ガイドの画像登録・更新用URL取得 - description: > + description: | プロジェクトの作業ガイドの画像を登録するためのput先URLを取得します。 - リクエストヘッダには、登録する画像に応じた適切な Content-Type を指定してください。 - 作業ガイド画像の登録/更新方法は以下の通りです。 - 1. `getInstructionImageUrlForPut` APIを実行して、ファイルアップロード用のURLを取得する。 * `curl -X GET -H 'Content-Type: {CONTENT_TYPE_HERE}' 'https://annofab.com/api/v1/projects/{project_id}/instruction-images/{image_id}/put-url'` 2. 手順1で取得したファイルアップロード用のURLに対して、登録/更新する作業ガイド画像ファイル(`hoge.jpg`)をPUTする。 * `curl -X PUT -H 'Content-Type: {CONTENT_TYPE_HERE}' --data-binary @/hoge.jpg '{ファイルアップロード用のURL}'` 手順1と2で `CONTENT_TYPE_HERE` は必ず一致しなければいけません。 + security: - - ProjectOwner: [] - - ProjectAccepter: [] + - ProjectOwner: [] + - ProjectAccepter: [] operationId: getInstructionImageUrlForPut parameters: - - in: header - name: Content-Type - schema: - type: string - example: image/png - description: | - 登録する画像ファイルの Content-Type を指定します。 - - name: project_id - in: path - description: プロジェクトID - required: true - schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/ProjectId - - name: image_id - in: path - description: 作業ガイド画像ID - required: true - schema: - type: string - example: ed55914c-9f04-470e-8af2-373c8def3e8b + - in: header + name: Content-Type + schema: + type: string + example: "image/png" + description: | + 登録する画像ファイルの Content-Type を指定します。 + - name: project_id + in: path + description: プロジェクトID + required: true + schema: + $ref: "swagger-api-components.yaml#/components/schemas/ProjectId" + - name: image_id + in: path + description: 作業ガイド画像ID + required: true + schema: + type: string + example: "ed55914c-9f04-470e-8af2-373c8def3e8b" responses: "200": description: 正常 content: application/json: schema: - $ref: swagger-api-components.redoc.yaml#/components/schemas/InstructionImagePath + $ref: "swagger-api-components.yaml#/components/schemas/InstructionImagePath" "401": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnauthorizedApi + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnauthorizedApi" "404": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorMissingResource + $ref: "swagger-api-components.yaml#/components/responses/ErrorMissingResource" "503": - $ref: swagger-api-components.redoc.yaml#/components/responses/ErrorUnderMaintenance + $ref: "swagger-api-components.yaml#/components/responses/ErrorUnderMaintenance" From 59c62b120621a5c71d3374ab1c88de85ca1e417c Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Tue, 23 Jun 2020 19:17:26 +0900 Subject: [PATCH 04/15] update --- generate/generate.sh | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/generate/generate.sh b/generate/generate.sh index 1872db49..c0bb948c 100755 --- a/generate/generate.sh +++ b/generate/generate.sh @@ -1,6 +1,6 @@ #!/bin/bash -uex -DOCKER_IMAGE=openapitools/openapi-generator-cli:v4.2.3 +DOCKER_IMAGE=openapitools/openapi-generator-cli:v4.3.1 PROGNAME=$(basename $0) @@ -47,18 +47,17 @@ if "${FLAG_DOWNLOAD}"; then curl https://annofab.com/docs/api/swagger.yaml --output swagger/swagger.yaml curl https://annofab.com/docs/api/swagger.v2.yaml --output swagger/swagger.v2.yaml curl https://annofab.com/docs/api/swagger-api-components.yaml --output swagger/swagger-api-components.yaml -# curl https://annofab.com/docs/api/swagger.internal.yaml --output swagger.internal.yaml - # インデントを1つ深くする - sed -e "s/#\/schemas/#\/components\/schemas/g" -e "s/^/ /g" swagger/swagger-api-components.yaml --in-place - - sed '/swagger-api-components.yaml/d' swagger/swagger.yaml > swagger/swagger-tmp.yaml - cat swagger/swagger-tmp.yaml swagger/swagger-api-components.yaml > swagger/swagger.yaml - - sed '/swagger-api-components.yaml/d' swagger/swagger.v2.yaml > swagger/swagger-tmp.v2.yaml - cat swagger/swagger-tmp.v2.yaml swagger/swagger-api-components.yaml > swagger/swagger.v2.yaml - - rm swagger/swagger-tmp.yaml swagger/swagger-tmp.v2.yaml +# # インデントを1つ深くする +# sed -e "s/#\/schemas/#\/components\/schemas/g" -e "s/^/ /g" swagger/swagger-api-components.yaml --in-place +# +# sed '/swagger-api-components.yaml/d' swagger/swagger.yaml > swagger/swagger-tmp.yaml +# cat swagger/swagger-tmp.yaml swagger/swagger-api-components.yaml > swagger/swagger.yaml +# +# sed '/swagger-api-components.yaml/d' swagger/swagger.v2.yaml > swagger/swagger-tmp.v2.yaml +# cat swagger/swagger-tmp.v2.yaml swagger/swagger-api-components.yaml > swagger/swagger.v2.yaml +# +# rm swagger/swagger-tmp.yaml swagger/swagger-tmp.v2.yaml fi From b4cb3406702526163cf9713a5ccb0e9a444fd0b8 Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 00:06:26 +0900 Subject: [PATCH 05/15] update generate.sh --- generate/generate.sh | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/generate/generate.sh b/generate/generate.sh index c0bb948c..abd94360 100755 --- a/generate/generate.sh +++ b/generate/generate.sh @@ -72,8 +72,7 @@ docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=$ --input-spec swagger/swagger.yaml \ ${OPENAPI_GENERATOR_CLI_COMMON_OPTION} \ --template-dir /local/template \ - -Dapis -DapiTests=false -DapiDocs=false \ - -Dmodels -DmodelTests=false -DmodelDocs=false \ + --global-property=apis,apiTests=false,apiDocs=false,models,modelTests=false,modelDocs=false \ --ignore-file-override=/local/.openapi-generator-ignore_v1 cat partial-header/generated_api_partial_header_v1.py out/openapi_client/api/*_api.py > ../annofabapi/generated_api.py @@ -88,7 +87,7 @@ docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=${ --input-spec swagger/swagger.v2.yaml \ ${OPENAPI_GENERATOR_CLI_COMMON_OPTION} \ --template-dir /local/template \ - -Dapis -DapiTests=false -DapiDocs=false \ + --global-property=apis,apiTests=false,apiDocs=false \ --ignore-file-override=/local/.openapi-generator-ignore_v2 cat partial-header/generated_api_partial_header_v2.py out/openapi_client/api/*_api.py > ../annofabapi/generated_api2.py @@ -101,7 +100,7 @@ docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=$ --input-spec swagger/swagger.yaml \ ${OPENAPI_GENERATOR_CLI_COMMON_OPTION} \ --template-dir /local/template_dataclass \ - -Dmodels -DmodelTests=false -DmodelDocs=false \ + --global-property=models,modelTests=false,modelDocs=false \ MODELS_DIR=out/openapi_client/models From bcf41a51669ec3e01a593e1f9d63111138e07e1b Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 00:31:35 +0900 Subject: [PATCH 06/15] =?UTF-8?q?full=20annotation=E3=81=AE=E3=83=87?= =?UTF-8?q?=E3=83=BC=E3=82=BF=E3=82=92=E5=89=8A=E9=99=A4=E3=81=99=E3=82=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- generate/generate.sh | 3 --- 1 file changed, 3 deletions(-) diff --git a/generate/generate.sh b/generate/generate.sh index abd94360..082f555a 100755 --- a/generate/generate.sh +++ b/generate/generate.sh @@ -119,9 +119,6 @@ declare -a model_files=(${MODELS_DIR}/point.py \ ${MODELS_DIR}/full_annotation_data_single_point.py \ ${MODELS_DIR}/full_annotation_data_range.py \ ${MODELS_DIR}/additional_data.py \ - ${MODELS_DIR}/full_annotation_additional_data.py \ - ${MODELS_DIR}/full_annotation_detail.py \ - ${MODELS_DIR}/full_annotation.py \ ${MODELS_DIR}/simple_annotation_detail.py \ ${MODELS_DIR}/simple_annotation.py \ ${MODELS_DIR}/single_annotation_detail.py \ From 2986e6a31c5b309caad0ba52d38e277af4d1beee Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 00:41:43 +0900 Subject: [PATCH 07/15] update --- annofabapi/dataclass/annotation.py | 100 +- annofabapi/dataclass/annotation_specs.py | 8 +- annofabapi/dataclass/input.py | 3 + annofabapi/dataclass/inspection.py | 12 +- annofabapi/generated_api.py | 68 +- annofabapi/generated_api2.py | 211 +++- annofabapi/models.py | 1433 +++++++++++----------- annofabapi/wrapper.py | 15 +- 8 files changed, 982 insertions(+), 868 deletions(-) diff --git a/annofabapi/dataclass/annotation.py b/annofabapi/dataclass/annotation.py index a237d9e0..7452a734 100644 --- a/annofabapi/dataclass/annotation.py +++ b/annofabapi/dataclass/annotation.py @@ -152,7 +152,7 @@ class AdditionalData: """ additional_data_definition_id: str - """属性ID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。""" + """""" flag: Optional[bool] """`additional_data_definition`の`type`が`flag`のときの属性値。 """ @@ -164,99 +164,9 @@ class AdditionalData: """`additional_data_definition`の`type`が`text`,`comment`,`link` または `tracking`のときの属性値。 """ choice: Optional[str] - """`additional_data_definition`の`type`が`choice` または `select `のときの属性値(選択肢ID)。 """ - - -@dataclass_json -@dataclass -class FullAnnotationAdditionalData: - """ - - """ - - additional_data_definition_id: Optional[str] - """""" - - additional_data_definition_name: Optional[InternationalizationMessage] - """""" - - type: Optional[AdditionalDataDefinitionType] - """""" - - value: Optional[AdditionalDataValue] - """""" - - -@dataclass_json -@dataclass -class FullAnnotationDetail: - """ - - """ - - annotation_id: Optional[str] - """アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
annotation_type が classification の場合は label_id と同じ値が格納されます。 """ - - user_id: Optional[str] - """""" - - label_id: Optional[str] - """""" - - label_name: Optional[InternationalizationMessage] - """""" - - annotation_type: Optional[AnnotationType] - """""" - - data_holding_type: Optional[AnnotationDataHoldingType] - """""" - - data: Optional[FullAnnotationData] - """""" - - additional_data_list: Optional[List[FullAnnotationAdditionalData]] """""" -@dataclass_json -@dataclass -class FullAnnotation: - """ - - """ - - project_id: Optional[str] - """プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) """ - - task_id: Optional[str] - """タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) """ - - task_phase: Optional[TaskPhase] - """""" - - task_phase_stage: Optional[int] - """""" - - task_status: Optional[TaskStatus] - """""" - - input_data_id: Optional[str] - """入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) """ - - input_data_name: Optional[str] - """""" - - details: Optional[List[FullAnnotationDetail]] - """""" - - updated_datetime: Optional[str] - """""" - - annotation_format_version: Optional[str] - """アノテーションフォーマットのバージョンです。 アノテーションフォーマットとは、プロジェクト個別のアノテーション仕様ではなく、AnnoFabのアノテーション構造のことです。 したがって、アノテーション仕様を更新しても、このバージョンは変化しません。 バージョンの読み方と更新ルールは、業界慣習の[Semantic Versioning](https://semver.org/)にもとづきます。 JSONに出力されるアノテーションフォーマットのバージョンは、アノテーションZIPが作成される時点のものが使われます。 すなわち、`1.0.0`の時点のタスクで作成したアノテーションであっても、フォーマットが `1.0.1` に上がった次のZIP作成時では `1.0.1` となります。 バージョンを固定してZIPを残しておきたい場合は、プロジェクトが完了した時点でZIPをダウンロードして保管しておくか、またはプロジェクトを「停止中」にします。 """ - - @dataclass_json @dataclass class SimpleAnnotationDetail: @@ -387,10 +297,10 @@ class AnnotationDetail: """アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
annotation_type が classification の場合は label_id と同じ値が格納されます。 """ account_id: str - """アノテーションを作成したユーザのアカウントID。""" + """""" label_id: str - """ラベルID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。""" + """""" is_protected: bool """`true`の場合、アノテーションをアノテーションエディタ上での削除から保護できます。 外部から取り込んだアノテーションに属性を追加するときなどに指定すると、データの削除を防げます。 """ @@ -398,8 +308,8 @@ class AnnotationDetail: data_holding_type: AnnotationDataHoldingType """""" - data: Optional[OneOfstringFullAnnotationData] - """アノテーションの座標値や区間などのデータ。レスポンスの場合は`string`形式、[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は`string`または`object`形式です。 `annotation_type`に応じて`string`,`object`の形式が変わります。
annotation_typedata_holding_typestring形式object形式
bounding_box inner左上x,左上y,右下x,右下yFullAnnotationDataBoundingBox
pointinnerx1,y1FullAnnotationDataSinglePoint
polygon / polyline innerx1,y1,x2,y2, ... FullAnnotationDataPoints
range inner開始時間(ミリ秒),終了時間(ミリ秒) FullAnnotationDataRange
classification innernull FullAnnotationDataClassification / null
segmentationouternull FullAnnotationDataSegmentation / null
segmentation_v2 outernull FullAnnotationDataSegmentationV2 / null
""" + data: Optional[AnnotationData] + """""" path: Optional[str] """外部ファイルに保存されたアノテーションのパス。`data_holding_type`が`inner`の場合は未指定です。 レスポンスの場合は`annotation_id`と同じ値が格納されます。 [putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は、[createTempPath](#operation/createTempPath) APIで取得できる一時データ保存先S3パスを格納してください。 更新しない場合は、[getEditorAnnotation](#operation/getEditorAnnotation) APIで取得した`path`をそのまま渡せます。 外部ファイルのフォーマットは下表の通りです。
annotation_type形式
segmentation / segmentation_v2 PNG画像。塗りつぶした部分はrgba(255, 255, 255, 1) 、塗りつぶしていない部分はrgba(0, 0, 0, 0)
""" diff --git a/annofabapi/dataclass/annotation_specs.py b/annofabapi/dataclass/annotation_specs.py index f6534d29..9fe1e0ca 100644 --- a/annofabapi/dataclass/annotation_specs.py +++ b/annofabapi/dataclass/annotation_specs.py @@ -226,8 +226,8 @@ class AdditionalDataDefinitionV1: name: Optional[InternationalizationMessage] """""" - default: Optional[OneOfbooleanintegerstring] - """属性の初期値です。 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 * type が flag の場合: 真偽値(`true` or `false`) * type が integer の場合: 整数値 * type が text の場合: 文字列 * type が comment の場合: 文字列 * type が choice の場合: 選択肢(`choices`)の `choice_id` * type が select の場合: 選択肢(`choices`)の `choice_id` 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 なお、トラッキングとリンクには初期値を設定できません。 """ + default: Optional[AdditionalDataDefaultType] + """""" keybind: Optional[List[Keybind]] """""" @@ -264,8 +264,8 @@ class AdditionalDataDefinitionV2: name: Optional[InternationalizationMessage] """""" - default: Optional[OneOfbooleanintegerstring] - """属性の初期値です。 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 * type が flag の場合: 真偽値(`true` or `false`) * type が integer の場合: 整数値 * type が text の場合: 文字列 * type が comment の場合: 文字列 * type が choice の場合: 選択肢(`choices`)の `choice_id` * type が select の場合: 選択肢(`choices`)の `choice_id` 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 なお、トラッキングとリンクには初期値を設定できません。 """ + default: Optional[AdditionalDataDefaultType] + """""" keybind: Optional[List[Keybind]] """""" diff --git a/annofabapi/dataclass/input.py b/annofabapi/dataclass/input.py index 80cf1b20..10236a39 100644 --- a/annofabapi/dataclass/input.py +++ b/annofabapi/dataclass/input.py @@ -75,3 +75,6 @@ class InputData: metadata: Optional[Dict[str, str]] """ユーザーが自由に登録できるkey-value型のメタデータです。主にカスタムエディタで使われることを想定しています。 """ + + system_metadata: Optional[SystemMetadata] + """""" diff --git a/annofabapi/dataclass/inspection.py b/annofabapi/dataclass/inspection.py index a87842fa..7ab3f6aa 100644 --- a/annofabapi/dataclass/inspection.py +++ b/annofabapi/dataclass/inspection.py @@ -40,22 +40,22 @@ class Inspection: """検査ID。[値の制約についてはこちら。](#section/API-Convention/APIID) """ phase: TaskPhase - """検査コメントを付与したときのタスクフェーズ。[詳細はこちら](#section/TaskPhase)""" + """""" phase_stage: int """検査コメントを付与したときのフェーズのステージ""" commenter_account_id: str - """検査コメントを付与したユーザのアカウントID""" + """""" annotation_id: Optional[str] - """検査コメントに紐づくアノテーションのID。アノテーションに紐付けられていない場合(アノテーションの付け忘れに対する指定など)は未指定。 [詳細はこちら](#section/AnnotationId)。 """ + """アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
annotation_type が classification の場合は label_id と同じ値が格納されます。 """ - data: OneOfInspectionDataPointInspectionDataPolylineInspectionDataTime - """検査コメントの座標値や区間。 * `InspectionDataPoint`:点で検査コメントを付与したときの座標値 * `InspectionDataPolyline`:ポリラインで検査コメントを付与したときの座標値 * `InspectionDataTime`:検査コメントを付与した区間(動画プロジェクトの場合) """ + data: InspectionData + """""" parent_inspection_id: Optional[str] - """返信先の検査コメントの検査ID。返信先の検査コメントは「スレッド内の直前のコメント」ではなく「スレッドの先頭のコメント」を指します。 """ + """検査ID。[値の制約についてはこちら。](#section/API-Convention/APIID) """ phrases: Optional[List[str]] """参照している定型指摘のID。""" diff --git a/annofabapi/generated_api.py b/annofabapi/generated_api.py index 3f004959..a40f89b4 100644 --- a/annofabapi/generated_api.py +++ b/annofabapi/generated_api.py @@ -278,7 +278,7 @@ def batch_update_annotations( Args: project_id (str): プロジェクトID (required) request_body (Any): Request Body - one_of_batch_annotation_request_item_put_batch_annotation_request_item_delete (List[OneOfBatchAnnotationRequestItemPutBatchAnnotationRequestItemDelete]): (required) + batch_annotation_request_item (List[BatchAnnotationRequestItem]): (required) Returns: Tuple[List[SingleAnnotation], requests.Response] @@ -335,7 +335,7 @@ def get_annotation_archive( v2 (str): このクエリパラメータのキーだけを指定(`?v2`)、または値 `true` も指定(`?v2=true`)すると、アノテーションJSONのファイル名は `{入力データID}.json` になります。 この v2 形式は、入力データ名がファイル名の長さ上限を上回ってもよいように再設計されたものです。 以前の v1 形式(アノテーションJSONのファイル名は `{入力データ名}.json` )はいずれ廃止され、クエリパラメータ `v2` があってもなくても v2 形式に置き換わる予定です。 Returns: - Tuple[InlineResponse20010, requests.Response] + Tuple[TemporaryUrl, requests.Response] """ @@ -363,11 +363,11 @@ def get_annotation_list( page (int): 検索結果のうち、取得したいページの番号(1始まり) limit (int): 1ページあたりの取得するデータ件数 aggregate_by_task_and_input (bool): trueを指定した場合に「タスクIDと入力IDの組」ごとに検索結果を集計するようにする。 - query (AnnotationQuery): 絞り込み条件をJSON形式で表したもの。 + query (str): 絞り込み条件([AnnotationQuery](#section/AnnotationQuery))をJSON形式で表した文字列。 sort (str): ソート順の指定。 使用可能キーはtask_id, input_data_id, detail.annotation_id, detail.account_id, detail.label_id, detail.data_holding_type, detail.created_datetime, detail.updated_datetimeのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 Returns: - Tuple[InlineResponse2009, requests.Response] + Tuple[AnnotationList, requests.Response] """ @@ -391,7 +391,7 @@ def get_archive_full_with_pro_id(self, project_id: str, **kwargs) -> Tuple[Any, project_id (str): プロジェクトID (required) Returns: - Tuple[InlineResponse20010, requests.Response] + Tuple[TemporaryUrl, requests.Response] """ @@ -443,7 +443,7 @@ def post_annotation_archive_update( v (str): APIの戻り型のバージョンを指定します。 値と戻り型の対応は以下です。 - \"1\":Message - \"2\":PostAnnotationArchiveUpdateResponse Returns: - Tuple[OneOfMessagePostAnnotationArchiveUpdateResponse, requests.Response] + Tuple[PostAnnotationArchiveUpdateResponseWrapper, requests.Response] """ @@ -506,7 +506,7 @@ def get_annotation_specs( v (str): 取得するアノテーション仕様のフォーマットバージョンを指定します。 Returns: - Tuple[OneOfAnnotationSpecsV1AnnotationSpecsV2, requests.Response] + Tuple[AnnotationSpecs, requests.Response] """ @@ -551,7 +551,7 @@ def put_annotation_specs( Args: project_id (str): プロジェクトID (required) request_body (Any): Request Body - unknown_base_type (UNKNOWN_BASE_TYPE): (required) + annotation_specs_request (AnnotationSpecsRequest): (required) Returns: Tuple[AnnotationSpecsV2, requests.Response] @@ -584,7 +584,7 @@ def batch_update_inputs( Args: project_id (str): プロジェクトID (required) request_body (Any): Request Body - one_of_batch_input_data_request_item_delete (List[OneOfBatchInputDataRequestItemDelete]): (required) + batch_input_data_request_item (List[BatchInputDataRequestItem]): (required) Returns: Tuple[List[InputData], requests.Response] @@ -693,7 +693,7 @@ def get_input_data_list( limit (int): 1ページあたりの取得するデータ件数 Returns: - Tuple[InlineResponse20011, requests.Response] + Tuple[InputDataList, requests.Response] """ @@ -789,7 +789,7 @@ def batch_update_inspections( task_id (str): タスクID (required) input_data_id (str): 入力データID (required) request_body (Any): Request Body - one_of_batch_inspection_request_item_put_batch_inspection_request_item_delete (List[OneOfBatchInspectionRequestItemPutBatchInspectionRequestItemDelete]): (required) + batch_inspection_request_item (List[BatchInspectionRequestItem]): (required) Returns: Tuple[List[Inspection], requests.Response] @@ -1038,7 +1038,7 @@ def get_project_job( exclusive_start_created_datetime (str): 取得するデータの直前の作成日時 Returns: - Tuple[InlineResponse2007, requests.Response] + Tuple[JobInfoContainer, requests.Response] """ @@ -1137,7 +1137,7 @@ def get_my_organizations( limit (int): 1ページあたりの取得するデータ件数 現在は未実装のパラメータです。(今後対応予定) Returns: - Tuple[InlineResponse200, requests.Response] + Tuple[MyOrganizationList, requests.Response] """ @@ -1188,7 +1188,7 @@ def get_my_projects(self, query_params: Optional[Dict[str, Any]] = None, **kwarg sort_by (str): `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 未指定時はプロジェクト名でソートする。 Returns: - Tuple[InlineResponse2004, requests.Response] + Tuple[ProjectContainer, requests.Response] """ @@ -1387,7 +1387,7 @@ def get_projects_of_organization( sort_by (str): `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 未指定時はプロジェクト名でソートする。 Returns: - Tuple[InlineResponse2001, requests.Response] + Tuple[ProjectList, requests.Response] """ @@ -1493,7 +1493,7 @@ def get_organization_members(self, organization_name: str, **kwargs) -> Tuple[An organization_name (str): 組織名 (required) Returns: - Tuple[InlineResponse2002, requests.Response] + Tuple[OrganizationMemberList, requests.Response] """ @@ -1627,7 +1627,7 @@ def get_organization_plugins(self, organization_name: str, **kwargs) -> Tuple[An organization_name (str): 組織名 (required) Returns: - Tuple[InlineResponse2003, requests.Response] + Tuple[OrganizationPluginList, requests.Response] """ @@ -1687,7 +1687,7 @@ def delete_project( v (str): APIの戻り型のバージョンを指定します。 値と戻り型の対応は以下です。 - \"1\":Project - \"2\":DeleteProjectResponse Returns: - Tuple[OneOfProjectDeleteProjectResponse, requests.Response] + Tuple[DeleteProjectResponseWrapper, requests.Response] """ @@ -1753,7 +1753,7 @@ def get_project_inputs_url(self, project_id: str, **kwargs) -> Tuple[Any, reques project_id (str): プロジェクトID (required) Returns: - Tuple[InlineResponse2005, requests.Response] + Tuple[TemporaryUrl, requests.Response] """ @@ -1775,7 +1775,7 @@ def get_project_inspections_url(self, project_id: str, **kwargs) -> Tuple[Any, r project_id (str): プロジェクトID (required) Returns: - Tuple[InlineResponse2005, requests.Response] + Tuple[TemporaryUrl, requests.Response] """ @@ -1797,7 +1797,7 @@ def get_project_task_histories_url(self, project_id: str, **kwargs) -> Tuple[Any project_id (str): プロジェクトID (required) Returns: - Tuple[InlineResponse2005, requests.Response] + Tuple[TemporaryUrl, requests.Response] """ @@ -1820,7 +1820,7 @@ def get_project_task_history_events_url(self, project_id: str, **kwargs) -> Tupl project_id (str): プロジェクトID (required) Returns: - Tuple[InlineResponse2005, requests.Response] + Tuple[TemporaryUrl, requests.Response] """ @@ -1843,7 +1843,7 @@ def get_project_tasks_url(self, project_id: str, **kwargs) -> Tuple[Any, request project_id (str): プロジェクトID (required) Returns: - Tuple[InlineResponse2005, requests.Response] + Tuple[TemporaryUrl, requests.Response] """ @@ -1875,7 +1875,7 @@ def initiate_project_copy( project_copy_request (ProjectCopyRequest): (required) Returns: - Tuple[OneOfProjectProjectCopyResponse, requests.Response] + Tuple[ProjectCopyResponseWrapper, requests.Response] """ @@ -1926,7 +1926,7 @@ def post_project_tasks_update( v (str): APIの戻り型のバージョンを指定します。 値と戻り型の対応は以下です。 - \"1\":Message - \"2\":PostProjectTasksUpdateResponse Returns: - Tuple[OneOfMessagePostProjectTasksUpdateResponse, requests.Response] + Tuple[PostProjectTasksUpdateResponseWrapper, requests.Response] """ @@ -1938,7 +1938,11 @@ def post_project_tasks_update( return self._request_wrapper(http_method, url_path, **keyword_params) def put_project( - self, project_id: str, request_body: Optional[Any] = None, **kwargs + self, + project_id: str, + query_params: Optional[Dict[str, Any]] = None, + request_body: Optional[Any] = None, + **kwargs, ) -> Tuple[Any, requests.Response]: """プロジェクト作成/更新 @@ -1950,6 +1954,8 @@ def put_project( Args: project_id (str): プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) (required) + query_params (Dict[str, Any]): Query Parameters + v (str): APIの戻り型のバージョンを指定します。 値と戻り型の対応は以下です。 - \"1\":Project - \"2\":PutProjectResponse request_body (Any): Request Body put_project_request (PutProjectRequest): @@ -1961,6 +1967,7 @@ def put_project( url_path = f"/projects/{project_id}" http_method = "PUT" keyword_params: Dict[str, Any] = { + "query_params": query_params, "request_body": request_body, } return self._request_wrapper(http_method, url_path, **keyword_params) @@ -2009,7 +2016,7 @@ def get_project_members( include_inactive_member (str): 脱退したプロジェクトメンバーも取得する時に、キーのみ指定します(値は無視されます)。 Returns: - Tuple[InlineResponse2006, requests.Response] + Tuple[ProjectMemberList, requests.Response] """ @@ -2368,7 +2375,7 @@ def batch_update_tasks( Args: project_id (str): プロジェクトID (required) request_body (Any): Request Body - one_of_batch_task_request_item_delete (List[OneOfBatchTaskRequestItemDelete]): (required) + batch_task_request_item (List[BatchTaskRequestItem]): (required) Returns: Tuple[List[Task], requests.Response] @@ -2504,9 +2511,10 @@ def get_tasks( rejected_only (str): 差し戻されたタスクだけを絞り込む時に、キーのみ指定します(値は無視されます)。 auto_accepted_only (str): 「抜取検査の対象外となり、自動受入されたタスク」だけを絞り込む時に、キーのみ指定します(値は無視されます)。 sort (str): ソート順の指定。 使用可能キーはtask_id、updated_datetime、number_of_rejections、phase、phase_stage、status、account_idのいずれかです。降順指定時は先頭に-(ハイフン)を付与します。 複数指定時は,(カンマ)区切りで列挙します。複数キーを列挙した場合は、先頭から優先順位を割り振られます。 + annotation (AnnotationQuery): アノテーションの絞り込み条件をJSON形式で指定したもの。指定した条件に合致するアノテーションを持つタスクを絞り込む際に指定する。 Returns: - Tuple[InlineResponse2008, requests.Response] + Tuple[TaskList, requests.Response] """ @@ -2540,7 +2548,7 @@ def initiate_tasks_generation( task_generate_request (TaskGenerateRequest): (required) Returns: - Tuple[OneOfProjectTaskGenerateResponse, requests.Response] + Tuple[TaskGenerateResponseWrapper, requests.Response] """ diff --git a/annofabapi/generated_api2.py b/annofabapi/generated_api2.py index e1fad185..abc1c1af 100644 --- a/annofabapi/generated_api2.py +++ b/annofabapi/generated_api2.py @@ -56,7 +56,7 @@ def get_annotation_specs_v2( v (str): 取得するアノテーション仕様のフォーマットバージョンを指定します。 Returns: - Tuple[OneOfAnnotationSpecsV1AnnotationSpecsV2, requests.Response] + Tuple[AnnotationSpecs, requests.Response] """ @@ -67,6 +67,68 @@ def get_annotation_specs_v2( } return self._request_wrapper(http_method, url_path, **keyword_params) + ######################################### + # Public Method : AfOrganizationMemberV2Api + # NOTE: This method is auto generated by OpenAPI Generator + ######################################### + + def get_organization_member_v2( + self, organization_id: str, user_id: str, query_params: Optional[Dict[str, Any]] = None, **kwargs + ) -> Tuple[Any, requests.Response]: + """組織メンバー取得 + + + authorizations: SignedCookieKeyPairId, SignedCookiePolicy, SignedCookieSignature + + + 指定したユーザーが指定した組織にどのようなロールで参加しているかを取得します。 + + Args: + organization_id (str): 組織ID (required) + user_id (str): ユーザID (required) + query_params (Dict[str, Any]): Query Parameters + cache (str): CACHE TIMESTAMP + + Returns: + Tuple[OrganizationMember, requests.Response] + + + """ + url_path = f"/organizations/{organization_id}/members/{user_id}" + http_method = "GET" + keyword_params: Dict[str, Any] = { + "query_params": query_params, + } + return self._request_wrapper(http_method, url_path, **keyword_params) + + def get_organization_members_v2( + self, organization_id: str, query_params: Optional[Dict[str, Any]] = None, **kwargs + ) -> Tuple[Any, requests.Response]: + """組織メンバー一括取得 + + + authorizations: SignedCookieKeyPairId, SignedCookiePolicy, SignedCookieSignature + + + 脱退したメンバーは含まれません。 + + Args: + organization_id (str): 組織ID (required) + query_params (Dict[str, Any]): Query Parameters + cache (str): CACHE TIMESTAMP + + Returns: + Tuple[OrganizationMemberList, requests.Response] + + + """ + url_path = f"/organizations/{organization_id}/members" + http_method = "GET" + keyword_params: Dict[str, Any] = { + "query_params": query_params, + } + return self._request_wrapper(http_method, url_path, **keyword_params) + ######################################### # Public Method : AfOrganizationV2Api # NOTE: This method is auto generated by OpenAPI Generator @@ -78,7 +140,7 @@ def get_organization_by_name_v2( """組織情報取得 - authorizations: AllOrganizationMember + authorizations: SignedCookieKeyPairId, SignedCookiePolicy, SignedCookieSignature @@ -147,7 +209,7 @@ def get_organization_v2( """組織情報取得 - authorizations: AllOrganizationMember + authorizations: SignedCookieKeyPairId, SignedCookiePolicy, SignedCookieSignature @@ -242,7 +304,7 @@ def get_project_members_v2( cache (str): CACHE TIMESTAMP Returns: - Tuple[InlineResponse200, requests.Response] + Tuple[ProjectMemberList, requests.Response] """ @@ -446,3 +508,144 @@ def get_worktime_statistics_v2( "query_params": query_params, } return self._request_wrapper(http_method, url_path, **keyword_params) + + ######################################### + # Public Method : AfUsersV2Api + # NOTE: This method is auto generated by OpenAPI Generator + ######################################### + + def get_account_v2( + self, account_id: str, query_params: Optional[Dict[str, Any]] = None, **kwargs + ) -> Tuple[Any, requests.Response]: + """個人情報取得 + + + authorizations: SignedCookieKeyPairId, SignedCookiePolicy, SignedCookieSignature + + + + Args: + account_id (str): アカウントID (required) + query_params (Dict[str, Any]): Query Parameters + cache (str): CACHE TIMESTAMP + + Returns: + Tuple[MyAccount, requests.Response] + + + """ + url_path = f"/users/{account_id}" + http_method = "GET" + keyword_params: Dict[str, Any] = { + "query_params": query_params, + } + return self._request_wrapper(http_method, url_path, **keyword_params) + + def get_user_cache_v2(self, account_id: str, **kwargs) -> Tuple[Any, requests.Response]: + """キャッシュレコード + + + authorizations: SignedCookieKeyPairId, SignedCookiePolicy, SignedCookieSignature + + + + Args: + account_id (str): アカウントID (required) + + Returns: + Tuple[UserCacheRecord, requests.Response] + + + """ + url_path = f"/users/{account_id}/cache" + http_method = "GET" + keyword_params: Dict[str, Any] = {} + return self._request_wrapper(http_method, url_path, **keyword_params) + + def get_user_organizations_v2( + self, account_id: str, query_params: Optional[Dict[str, Any]] = None, **kwargs + ) -> Tuple[Any, requests.Response]: + """個人の所属組織一括取得 + + + authorizations: SignedCookieKeyPairId, SignedCookiePolicy, SignedCookieSignature + + + + Args: + account_id (str): アカウントID (required) + query_params (Dict[str, Any]): Query Parameters + cache (str): CACHE TIMESTAMP + + Returns: + Tuple[MyOrganizationList, requests.Response] + + + """ + url_path = f"/users/{account_id}/organizations" + http_method = "GET" + keyword_params: Dict[str, Any] = { + "query_params": query_params, + } + return self._request_wrapper(http_method, url_path, **keyword_params) + + def get_user_project_members_v2( + self, account_id: str, query_params: Optional[Dict[str, Any]] = None, **kwargs + ) -> Tuple[Any, requests.Response]: + """個人のプロジェクトメンバー情報一括取得 + + + authorizations: SignedCookieKeyPairId, SignedCookiePolicy, SignedCookieSignature + + + + Args: + account_id (str): アカウントID (required) + query_params (Dict[str, Any]): Query Parameters + cache (str): CACHE TIMESTAMP + + Returns: + Tuple[ProjectMember, requests.Response] + + + """ + url_path = f"/users/{account_id}/project-members" + http_method = "GET" + keyword_params: Dict[str, Any] = { + "query_params": query_params, + } + return self._request_wrapper(http_method, url_path, **keyword_params) + + def get_user_projects_v2( + self, account_id: str, query_params: Optional[Dict[str, Any]] = None, **kwargs + ) -> Tuple[Any, requests.Response]: + """自分のプロジェクトメンバー情報一括取得 + + + authorizations: SignedCookieKeyPairId, SignedCookiePolicy, SignedCookieSignature + + + + Args: + account_id (str): アカウントID (required) + query_params (Dict[str, Any]): Query Parameters + page (int): 表示するページ番号 + limit (int): 1ページあたりの取得するデータ件数 + organization_id (str): 指定した組織に属するプロジェクトに絞り込む。未指定時は全プロジェクト。 + title (str): プロジェクトタイトルでの部分一致検索。1文字以上あれば使用します。利便性のため、大文字小文字は区別しません。 + status (ProjectStatus): 指定した状態のプロジェクトで絞り込む。未指定時は全プロジェクト。 + input_data_type (InputDataType): 指定した入力データ種別でプロジェクトを絞り込む。未指定時は全プロジェクト + sort_by (str): `date` を指定することでプロジェクトの最新のタスク更新時間の順にソートして出力する。 未指定時はプロジェクト名でソートする。 + cache (str): CACHE TIMESTAMP + + Returns: + Tuple[ProjectContainer, requests.Response] + + + """ + url_path = f"/users/{account_id}/projects" + http_method = "GET" + keyword_params: Dict[str, Any] = { + "query_params": query_params, + } + return self._request_wrapper(http_method, url_path, **keyword_params) diff --git a/annofabapi/models.py b/annofabapi/models.py index 420f8349..2d383928 100644 --- a/annofabapi/models.py +++ b/annofabapi/models.py @@ -232,7 +232,7 @@ class AccountAuthority(Enum): Kyes of Dict * additional_data_definition_id: str - 属性ID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 + * flag: bool `additional_data_definition`の`type`が`flag`のときの属性値。 * integer: int @@ -240,20 +240,16 @@ class AccountAuthority(Enum): * comment: str `additional_data_definition`の`type`が`text`,`comment`,`link` または `tracking`のときの属性値。 * choice: str - `additional_data_definition`の`type`が`choice` または `select `のときの属性値(選択肢ID)。 + """ -AdditionalDataChoiceValue = Dict[str, Any] +AdditionalDataDefaultType = Dict[str, Any] """ - +属性の初期値です。 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 * type が flag の場合: 真偽値(`true` or `false`) * type が integer の場合: 整数値 * type が text の場合: 文字列 * type が comment の場合: 文字列 * type が choice の場合: 選択肢(`choices`)の `choice_id` * type が select の場合: 選択肢(`choices`)の `choice_id` 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 なお、トラッキングとリンクには初期値を設定できません。 Kyes of Dict -* id: str - -* name: InternationalizationMessage - """ @@ -285,8 +281,8 @@ class AdditionalDataDefinitionType(Enum): * name: InternationalizationMessage -* default: OneOfbooleanintegerstring - 属性の初期値です。 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 * type が flag の場合: 真偽値(`true` or `false`) * type が integer の場合: 整数値 * type が text の場合: 文字列 * type が comment の場合: 文字列 * type が choice の場合: 選択肢(`choices`)の `choice_id` * type が select の場合: 選択肢(`choices`)の `choice_id` 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 なお、トラッキングとリンクには初期値を設定できません。 +* default: AdditionalDataDefaultType + * keybind: List[Keybind] * type: AdditionalDataDefinitionType @@ -329,8 +325,8 @@ class AdditionalDataDefinitionType(Enum): * name: InternationalizationMessage -* default: OneOfbooleanintegerstring - 属性の初期値です。 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 * type が flag の場合: 真偽値(`true` or `false`) * type が integer の場合: 整数値 * type が text の場合: 文字列 * type が comment の場合: 文字列 * type が choice の場合: 選択肢(`choices`)の `choice_id` * type が select の場合: 選択肢(`choices`)の `choice_id` 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 なお、トラッキングとリンクには初期値を設定できません。 +* default: AdditionalDataDefaultType + * keybind: List[Keybind] * type: AdditionalDataDefinitionType @@ -419,6 +415,8 @@ class AdditionalDataDefinitionType(Enum): Kyes of Dict +* type: str + * premise: AdditionalDataRestriction * condition: AdditionalDataRestrictionCondition @@ -463,97 +461,6 @@ class AdditionalDataDefinitionType(Enum): * value: str -""" - -AdditionalDataValue = Dict[str, Any] -""" - - -Kyes of Dict - -* type: str - Link -* value: str - リンク先アノテーションID - -""" - -AdditionalDataValueChoice = Dict[str, Any] -""" - - -Kyes of Dict - -* type: str - Choice -* value: AdditionalDataChoiceValue - - -""" - -AdditionalDataValueComment = Dict[str, Any] -""" - - -Kyes of Dict - -* type: str - Comment -* value: str - 自由記述 - -""" - -AdditionalDataValueFlag = Dict[str, Any] -""" - - -Kyes of Dict - -* type: str - Flag -* value: bool - フラグのON(true)またはOFF(false) - -""" - -AdditionalDataValueInteger = Dict[str, Any] -""" - - -Kyes of Dict - -* type: str - Integer -* value: int - 整数値 - -""" - -AdditionalDataValueLink = Dict[str, Any] -""" - - -Kyes of Dict - -* type: str - Link -* value: str - リンク先アノテーションID - -""" - -AdditionalDataValueTracking = Dict[str, Any] -""" - - -Kyes of Dict - -* type: str - Tracking -* value: str - トラッキングID - """ AggregationResult = Dict[str, Any] @@ -584,6 +491,15 @@ class AdditionalDataDefinitionType(Enum): """ +AnnotationData = Dict[str, Any] +""" +アノテーションの座標値や区間などのデータ。 `annotation_type` に応じて `string` や `object` の構造が変わります。 API レスポンスに使われる場合は常に `string` 形式です。 [putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は `string` に加え、`object` 形式も使用できます。 + +Kyes of Dict + + +""" + class AnnotationDataHoldingType(Enum): """ @@ -603,15 +519,15 @@ class AnnotationDataHoldingType(Enum): * annotation_id: str アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
annotation_type が classification の場合は label_id と同じ値が格納されます。 * account_id: str - アノテーションを作成したユーザのアカウントID。 + * label_id: str - ラベルID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 + * is_protected: bool `true`の場合、アノテーションをアノテーションエディタ上での削除から保護できます。 外部から取り込んだアノテーションに属性を追加するときなどに指定すると、データの削除を防げます。 * data_holding_type: AnnotationDataHoldingType -* data: OneOfstringFullAnnotationData - アノテーションの座標値や区間などのデータ。レスポンスの場合は`string`形式、[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は`string`または`object`形式です。 `annotation_type`に応じて`string`,`object`の形式が変わります。
annotation_typedata_holding_typestring形式object形式
bounding_box inner左上x,左上y,右下x,右下yFullAnnotationDataBoundingBox
pointinnerx1,y1FullAnnotationDataSinglePoint
polygon / polyline innerx1,y1,x2,y2, ... FullAnnotationDataPoints
range inner開始時間(ミリ秒),終了時間(ミリ秒) FullAnnotationDataRange
classification innernull FullAnnotationDataClassification / null
segmentationouternull FullAnnotationDataSegmentation / null
segmentation_v2 outernull FullAnnotationDataSegmentationV2 / null
+* data: AnnotationData + * path: str 外部ファイルに保存されたアノテーションのパス。`data_holding_type`が`inner`の場合は未指定です。 レスポンスの場合は`annotation_id`と同じ値が格納されます。 [putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は、[createTempPath](#operation/createTempPath) APIで取得できる一時データ保存先S3パスを格納してください。 更新しない場合は、[getEditorAnnotation](#operation/getEditorAnnotation) APIで取得した`path`をそのまま渡せます。 外部ファイルのフォーマットは下表の通りです。
annotation_type形式
segmentation / segmentation_v2 PNG画像。塗りつぶした部分はrgba(255, 255, 255, 1) 、塗りつぶしていない部分はrgba(0, 0, 0, 0)
* etag: str @@ -646,6 +562,27 @@ class AnnotationDataHoldingType(Enum): * fill_near: bool +""" + +AnnotationList = Dict[str, Any] +""" + + +Kyes of Dict + +* list: List[SingleAnnotation] + 現在のページ番号に含まれる0件以上のアノテーションです。 +* page_no: float + 現在のページ番号です。 +* total_page_no: float + 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるアノテーションが0件であっても、総ページ数は1となります。 +* total_count: float + 検索結果の総件数。 +* over_limit: bool + 検索結果が1万件を超えた場合にtrueとなる。 +* aggregations: List[AggregationResult] + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + """ AnnotationQuery = Dict[str, Any] @@ -666,6 +603,33 @@ class AnnotationDataHoldingType(Enum): * attributes: List[AdditionalData] +* updated_from: str + 開始日・終了日を含む区間[updated_from, updated_to]でアノテーションの更新日を絞り込むときに使用する、開始日。updated_toより後ろに指定された場合、期間指定は開始日・終了日を含む区間[updated_to, updated_from]となる。未指定の場合、本日であるとして扱われる。 +* updated_to: str + 開始日・終了日を含む区間[updated_from, updated_to]でアノテーションの更新日を絞り込むときに使用する、終了日。未指定の場合、本日であるとして扱われる。 + +""" + +AnnotationSpecs = Dict[str, Any] +""" + + +Kyes of Dict + +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* labels: List[LabelV2] + +* inspection_phrases: List[InspectionPhrase] + +* updated_datetime: str + アノテーション仕様の最終更新時刻 +* additionals: List[AdditionalDataDefinitionV2] + +* restrictions: List[AdditionalDataRestriction] + +* format_version: str + """ @@ -688,6 +652,31 @@ class AnnotationDataHoldingType(Enum): * comment: str +""" + +AnnotationSpecsRequest = Dict[str, Any] +""" + + +Kyes of Dict + +* labels: List[LabelV2] + +* inspection_phrases: List[InspectionPhrase] + +* comment: str + +* auto_marking: bool + trueが指定された場合、各統計グラフにマーカーを自動追加します。 マーカーのタイトルには `comment` に指定された文字列が設定されます。 `comment` が指定されていなかった場合は \"アノテーション仕様の変更\" という文字列が設定されます。 +* last_updated_datetime: str + 新規作成時は未指定、更新時は必須(更新前の日時) +* additionals: List[AdditionalDataDefinitionV2] + +* restrictions: List[AdditionalDataRestriction] + +* format_version: str + + """ AnnotationSpecsRequestV1 = Dict[str, Any] @@ -705,7 +694,7 @@ class AnnotationDataHoldingType(Enum): * auto_marking: bool trueが指定された場合、各統計グラフにマーカーを自動追加します。 マーカーのタイトルには `comment` に指定された文字列が設定されます。 `comment` が指定されていなかった場合は \"アノテーション仕様の変更\" という文字列が設定されます。 * last_updated_datetime: str - 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 新規作成時は未指定。 + 新規作成時は未指定、更新時は必須(更新前の日時) """ @@ -730,7 +719,7 @@ class AnnotationDataHoldingType(Enum): * format_version: str * last_updated_datetime: str - 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 新規作成時は未指定。 + 新規作成時は未指定、更新時は必須(更新前の日時) """ @@ -777,7 +766,7 @@ class AnnotationDataHoldingType(Enum): class AnnotationType(Enum): """ - * `bounding_box` - 矩形を表します。 * `segmentation` - ピクセルレベルでの塗りつぶし(ラスター)を表します。 * `segmentation_v2` - 塗りつぶしv2を表します。v2はSemantic Segmentationに特化しています。 * `polygon` - ポリゴン(閉じた頂点集合)を表します。 * `polyline` - ポリライン(開いた頂点集合)を表します。 * `point` - 点を表します。 * `classification` - 入力データ全体に対するアノテーションを表します。 * `range` - 動画の区間を表します。 + * `bounding_box` - 矩形を表します。 * `segmentation` - ピクセルレベルでの塗りつぶし(ラスター)を表します。 * `segmentation_v2` - 塗りつぶしv2を表します。v2はSemantic Segmentationに特化しています。 * `polygon` - ポリゴン(閉じた頂点集合)を表します。 * `polyline` - ポリライン(開いた頂点集合)を表します。 * `point` - 点を表します。 * `classification` - 入力データ全体に対するアノテーションを表します。 * `range` - 動画の区間を表します。 * `custom` - カスタム """ BOUNDING_BOX = "bounding_box" @@ -788,6 +777,7 @@ class AnnotationType(Enum): POINT = "point" CLASSIFICATION = "classification" RANGE = "range" + CUSTOM = "custom" class AssigneeRuleOfResubmittedTask(Enum): @@ -820,6 +810,29 @@ class AssigneeRuleOfResubmittedTask(Enum): * updated_datetime: str +""" + +BatchAnnotationRequestItem = Dict[str, Any] +""" + + +Kyes of Dict + +* data: BatchAnnotation + +* type: str + `Delete` [詳しくはこちら](#section/API-Convention/API-_type) +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* task_id: str + タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* input_data_id: str + 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* annotation_id: str + アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
annotation_type が classification の場合は label_id と同じ値が格納されます。 +* updated_datetime: str + + """ BatchAnnotationRequestItemDelete = Dict[str, Any] @@ -854,6 +867,15 @@ class AssigneeRuleOfResubmittedTask(Enum): * type: str `Put` [詳しくはこちら](#section/API-Convention/API-_type) +""" + +BatchInputDataRequestItem = Dict[str, Any] +""" + + +Kyes of Dict + + """ BatchInputDataRequestItemDelete = Dict[str, Any] @@ -871,6 +893,27 @@ class AssigneeRuleOfResubmittedTask(Enum): """ +BatchInspectionRequestItem = Dict[str, Any] +""" + + +Kyes of Dict + +* data: Inspection + +* type: str + `Delete` [詳しくはこちら](#section/API-Convention/API-_type) +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* task_id: str + タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* input_data_id: str + 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* inspection_id: str + 検査ID。[値の制約についてはこちら。](#section/API-Convention/APIID) + +""" + BatchInspectionRequestItemDelete = Dict[str, Any] """ 検査コメント削除 @@ -901,6 +944,15 @@ class AssigneeRuleOfResubmittedTask(Enum): * type: str `Put` [詳しくはこちら](#section/API-Convention/API-_type) +""" + +BatchTaskRequestItem = Dict[str, Any] +""" + + +Kyes of Dict + + """ BatchTaskRequestItemDelete = Dict[str, Any] @@ -1028,11 +1080,11 @@ class AssigneeRuleOfResubmittedTask(Enum): Kyes of Dict * key: str - + 集約対象の `field` の値です。 * count: int - + 集約対象 `field` の値が `key` の値と等しかったリソースの件数です。 * aggregations: List[AggregationResult] - + この集約のサブ集約です。サブ集約がないときは空の配列になります。 """ @@ -1043,13 +1095,13 @@ class AssigneeRuleOfResubmittedTask(Enum): Kyes of Dict * type: str - 他と区別するために `CountResult` を指定します + `CountResult` [詳しくはこちら](#section/API-Convention/API-_type) * name: str - + 複数の集約を区別するための名前です。 `(フィールド名)_(集約内容)` のように命名されます。例えば `account_id` フィールドを `count` する場合、`account_id_count` となります。 * field: str - + 集約に使われたリソースのフィールド名です。 リソースの属性のさらに属性を参照するときは、`foo.bar.buz` のようにドット区切りになります。 * items: List[Count] - + 集約結果の値です。 """ @@ -1077,6 +1129,39 @@ class AssigneeRuleOfResubmittedTask(Enum): * project: Project +""" + +DeleteProjectResponseWrapper = Dict[str, Any] +""" + + +Kyes of Dict + +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* organization_id: str + 組織ID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* title: str + プロジェクトのタイトル +* overview: str + プロジェクトの概要 +* project_status: ProjectStatus + +* input_data_type: InputDataType + +* configuration: ProjectConfiguration + +* created_datetime: str + +* updated_datetime: str + +* summary: ProjectSummary + +* job: JobInfo + +* project: Project + + """ Duplicated = Dict[str, Any] @@ -1128,7 +1213,7 @@ class AssigneeRuleOfResubmittedTask(Enum): """ -Error = Dict[str, Any] +ErrorItem = Dict[str, Any] """ @@ -1143,276 +1228,22 @@ class AssigneeRuleOfResubmittedTask(Enum): """ -ErrorAlreadyUpdated = Dict[str, Any] +Errors = Dict[str, Any] """ Kyes of Dict -* errors: List[Error] +* errors: List[ErrorItem] * context: __DictStrKeyAnyValue__ 内部補足情報 """ -ErrorExpiredToken = Dict[str, Any] +FullAnnotationData = Dict[str, Any] """ - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorForbiddenResource = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorInternalServerError = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorInvalidBody = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorInvalidPath = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorInvalidQueryParam = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorLoginFailed = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorMissingNecessaryQueryParam = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorMissingResource = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorPasswordResetRequired = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorRefreshTokenExpired = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorStateMismatch = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorTimeout = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorUnauthorizedApi = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -ErrorUnderMaintenance = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -Errors = Dict[str, Any] -""" - - -Kyes of Dict - -* errors: List[Error] - -* context: __DictStrKeyAnyValue__ - 内部補足情報 - -""" - -FullAnnotation = Dict[str, Any] -""" - - -Kyes of Dict - -* project_id: str - プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) -* task_id: str - タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) -* task_phase: TaskPhase - -* task_phase_stage: int - -* task_status: TaskStatus - -* input_data_id: str - 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) -* input_data_name: str - -* details: List[FullAnnotationDetail] - -* updated_datetime: str - -* annotation_format_version: str - アノテーションフォーマットのバージョンです。 アノテーションフォーマットとは、プロジェクト個別のアノテーション仕様ではなく、AnnoFabのアノテーション構造のことです。 したがって、アノテーション仕様を更新しても、このバージョンは変化しません。 バージョンの読み方と更新ルールは、業界慣習の[Semantic Versioning](https://semver.org/)にもとづきます。 JSONに出力されるアノテーションフォーマットのバージョンは、アノテーションZIPが作成される時点のものが使われます。 すなわち、`1.0.0`の時点のタスクで作成したアノテーションであっても、フォーマットが `1.0.1` に上がった次のZIP作成時では `1.0.1` となります。 バージョンを固定してZIPを残しておきたい場合は、プロジェクトが完了した時点でZIPをダウンロードして保管しておくか、またはプロジェクトを「停止中」にします。 - -""" - -FullAnnotationAdditionalData = Dict[str, Any] -""" - - -Kyes of Dict - -* additional_data_definition_id: str - -* additional_data_definition_name: InternationalizationMessage - -* type: AdditionalDataDefinitionType - -* value: AdditionalDataValue - - -""" - -FullAnnotationData = Dict[str, Any] -""" -アノテーションのデータが格納されます。 * `FullAnnotationDataClassification`: 入力データ全体に対するアノテーションデータです。 * `FullAnnotationDataSegmentation`: ピクセルレベルでの塗りつぶし(ラスター)のアノテーションデータです。 * `FullAnnotationDataSegmentationV2`: 塗りつぶしv2ののアノテーションデータです。塗りつぶしv2はSemantic Segmentationに特化しています。 * `FullAnnotationDataBoundingBox`: 矩形のアノテーションデータです。 * `FullAnnotationDataPoints`: ポリゴン(閉じた頂点集合)のアノテーションデータです。 * `FullAnnotationDataSegmentation`: 点のアノテーションデータです。 * `FullAnnotationDataRange`: 動画区間のアノテーションデータです。 +アノテーションのデータが格納されます。 * `FullAnnotationDataClassification`: 入力データ全体に対するアノテーションデータです。 * `FullAnnotationDataSegmentation`: ピクセルレベルでの塗りつぶし(ラスター)のアノテーションデータです。 * `FullAnnotationDataSegmentationV2`: 塗りつぶしv2ののアノテーションデータです。塗りつぶしv2はSemantic Segmentationに特化しています。 * `FullAnnotationDataBoundingBox`: 矩形のアノテーションデータです。 * `FullAnnotationDataPoints`: ポリゴン(閉じた頂点集合)のアノテーションデータです。 * `FullAnnotationDataSegmentation`: 点のアノテーションデータです。 * `FullAnnotationDataRange`: 動画区間のアノテーションデータです。 Kyes of Dict @@ -1543,31 +1374,6 @@ class AssigneeRuleOfResubmittedTask(Enum): """ -FullAnnotationDetail = Dict[str, Any] -""" - - -Kyes of Dict - -* annotation_id: str - アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
annotation_type が classification の場合は label_id と同じ値が格納されます。 -* user_id: str - -* label_id: str - -* label_name: InternationalizationMessage - -* annotation_type: AnnotationType - -* data_holding_type: AnnotationDataHoldingType - -* data: FullAnnotationData - -* additional_data_list: List[FullAnnotationAdditionalData] - - -""" - class GraphType(Enum): """ @@ -1595,220 +1401,8 @@ class GraphType(Enum): * end: float -* count: int - - -""" - -InlineResponse200 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[MyOrganization] - 現在のページ番号に含まれる0件以上の所属組織です。 -* page_no: float - 現在のページ番号です。 -* total_page_no: float - 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる所属組織が0件であっても、総ページ数は1となります。 -* total_count: float - 検索結果の総件数。 -* over_limit: bool - 検索結果が1万件を超えた場合にtrueとなる。 -* aggregations: List[AggregationResult] - Aggregationによる集約結果。 - -""" - -InlineResponse2001 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[Project] - 現在のページ番号に含まれる0件以上のプロジェクトです。 -* page_no: float - 現在のページ番号です。 -* total_page_no: float - 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 -* total_count: float - 検索結果の総件数。 -* over_limit: bool - 検索結果が1万件を超えた場合にtrueとなる。 -* aggregations: List[AggregationResult] - Aggregationによる集約結果。 - -""" - -InlineResponse20010 = Dict[str, Any] -""" - - -Kyes of Dict - -* url: str - 認証済み一時URL - -""" - -InlineResponse20011 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[InputData] - 現在のページ番号に含まれる0件以上の入力データです。 -* page_no: float - 現在のページ番号です。 -* total_page_no: float - 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる入力データが0件であっても、総ページ数は1となります。 -* total_count: float - 検索結果の総件数。 -* over_limit: bool - 検索結果が1万件を超えた場合にtrueとなる。 -* aggregations: List[AggregationResult] - Aggregationによる集約結果。 - -""" - -InlineResponse2002 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[OrganizationMember] - -* page_no: float - 現在のページ番号です。 -* total_page_no: float - 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる組織メンバーが0件であっても、総ページ数は1となります。 -* total_count: float - 検索結果の総件数。 -* over_limit: bool - 検索結果が1万件を超えた場合にtrueとなる。 -* aggregations: List[AggregationResult] - Aggregationによる集約結果。 - -""" - -InlineResponse2003 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[OrganizationPlugin] - -* page_no: float - 現在のページ番号です。 -* total_page_no: float - 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 -* total_count: float - 検索結果の総件数。 - -""" - -InlineResponse2004 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[Project] - -* has_next: bool - - -""" - -InlineResponse2005 = Dict[str, Any] -""" - - -Kyes of Dict - -* url: str - 認証済み一時URL - -""" - -InlineResponse2006 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[ProjectMember] - -* page_no: float - 現在のページ番号です。 -* total_page_no: float - 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトメンバーが0件であっても、総ページ数は1となります。 -* total_count: float - 検索結果の総件数。 -* over_limit: bool - 検索結果が1万件を超えた場合にtrueとなる。 -* aggregations: List[AggregationResult] - Aggregationによる集約結果。 - -""" - -InlineResponse2007 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[JobInfo] - -* has_next: bool - - -""" - -InlineResponse2008 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[Task] - 現在のページ番号に含まれる0件以上のタスクです。 -* page_no: float - 現在のページ番号です。 -* total_page_no: float - 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるタスク0件であっても、総ページ数は1となります。 -* total_count: float - 検索結果の総件数。 -* over_limit: bool - 検索結果が1万件を超えた場合にtrueとなる。 -* aggregations: List[AggregationResult] - Aggregationによる集約結果。 - -""" - -InlineResponse2009 = Dict[str, Any] -""" - - -Kyes of Dict - -* list: List[SingleAnnotation] - 現在のページ番号に含まれる0件以上のアノテーションです。 -* page_no: float - 現在のページ番号です。 -* total_page_no: float - 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるアノテーションが0件であっても、総ページ数は1となります。 -* total_count: float - 検索結果の総件数。 -* over_limit: bool - 検索結果が1万件を超えた場合にtrueとなる。 -* aggregations: List[AggregationResult] - Aggregationによる集約結果。 +* count: int + """ @@ -1844,6 +1438,29 @@ class GraphType(Enum): データがSigned Cookieによるクロスオリジン配信に対応しているか否かです。 * metadata: dict(str, str) ユーザーが自由に登録できるkey-value型のメタデータです。主にカスタムエディタで使われることを想定しています。 +* system_metadata: SystemMetadata + + +""" + +InputDataList = Dict[str, Any] +""" + + +Kyes of Dict + +* list: List[InputData] + 現在のページ番号に含まれる0件以上の入力データです。 +* page_no: float + 現在のページ番号です。 +* total_page_no: float + 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる入力データが0件であっても、総ページ数は1となります。 +* total_count: float + 検索結果の総件数。 +* over_limit: bool + 検索結果が1万件を超えた場合にtrueとなる。 +* aggregations: List[AggregationResult] + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 """ @@ -1895,11 +1512,12 @@ class InputDataOrder(Enum): class InputDataType(Enum): """ - アノテーションする入力データの種類。プロジェクトの作成時のみ指定可能(未指定の場合は `image`)です。更新時は無視されます。 * `image` - 画像 * `movie` - 動画 + アノテーションする入力データの種類。プロジェクトの作成時のみ指定可能(未指定の場合は `image`)です。更新時は無視されます。 * `image` - 画像 * `movie` - 動画 * `custom` - カスタム """ IMAGE = "image" MOVIE = "movie" + CUSTOM = "custom" Inspection = Dict[str, Any] @@ -1917,17 +1535,17 @@ class InputDataType(Enum): * inspection_id: str 検査ID。[値の制約についてはこちら。](#section/API-Convention/APIID) * phase: TaskPhase - 検査コメントを付与したときのタスクフェーズ。[詳細はこちら](#section/TaskPhase) + * phase_stage: int 検査コメントを付与したときのフェーズのステージ * commenter_account_id: str - 検査コメントを付与したユーザのアカウントID + * annotation_id: str - 検査コメントに紐づくアノテーションのID。アノテーションに紐付けられていない場合(アノテーションの付け忘れに対する指定など)は未指定。 [詳細はこちら](#section/AnnotationId)。 -* data: OneOfInspectionDataPointInspectionDataPolylineInspectionDataTime - 検査コメントの座標値や区間。 * `InspectionDataPoint`:点で検査コメントを付与したときの座標値 * `InspectionDataPolyline`:ポリラインで検査コメントを付与したときの座標値 * `InspectionDataTime`:検査コメントを付与した区間(動画プロジェクトの場合) + アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
annotation_type が classification の場合は label_id と同じ値が格納されます。 +* data: InspectionData + * parent_inspection_id: str - 返信先の検査コメントの検査ID。返信先の検査コメントは「スレッド内の直前のコメント」ではなく「スレッドの先頭のコメント」を指します。 + 検査ID。[値の制約についてはこちら。](#section/API-Convention/APIID) * phrases: List[str] 参照している定型指摘のID。 * comment: str @@ -1939,6 +1557,42 @@ class InputDataType(Enum): * updated_datetime: str +""" + +InspectionData = Dict[str, Any] +""" +検査コメントの座標値や区間。 * `InspectionDataPoint`:点で検査コメントを付与したときの座標値 * `InspectionDataPolyline`:ポリラインで検査コメントを付与したときの座標値 * `InspectionDataTime`:検査コメントを付与した区間(動画プロジェクトの場合) * `InspectionDataCustom`:カスタム + +Kyes of Dict + +* x: int + +* y: int + +* type: str + `Custom` [詳しくはこちら](#section/API-Convention/API-_type) +* coordinates: List[InspectionDataPolylineCoordinates] + ポリラインを構成する頂点の配列 +* start: float + 開始時間(ミリ秒)。小数点以下はミリ秒以下を表します。 +* end: float + 終了時間(ミリ秒)。小数点以下はミリ秒以下を表します。 +* data: str + + +""" + +InspectionDataCustom = Dict[str, Any] +""" + + +Kyes of Dict + +* data: str + +* type: str + `Custom` [詳しくはこちら](#section/API-Convention/API-_type) + """ InspectionDataPoint = Dict[str, Any] @@ -2245,6 +1899,19 @@ class InspectionSummary(Enum): * updated_datetime: str +""" + +JobInfoContainer = Dict[str, Any] +""" + + +Kyes of Dict + +* list: List[JobInfo] + +* has_next: bool + + """ @@ -2259,7 +1926,7 @@ class JobStatus(Enum): class JobType(Enum): """ - * `copy-project` - プロジェクトのコピー。[initiateProjectCopy](#operation/initiateProjectCopy) APIを実行したときに登録されるジョブ。 * `gen-inputs` - zipファイルから入力データの作成。[putInputData](#operation/putInputData) APIを実行して、zipファイルから入力データを作成したときに登録されるジョブ。 * `gen-tasks` - タスクの一括作成。[initiateTasksGeneration](#operation/initiateTasksGeneration) APIを実行したときに登録されるジョブ。 * `gen-annotation` - アノテーションZIPの更新。[postAnnotationArchiveUpdate](#operation/postAnnotationArchiveUpdate) APIを実行したときに登録されるジョブ。 * `gen-tasks-list` - タスク全件ファイルの更新。[postProjectTasksUpdate](#operation/postProjectTasksUpdate) APIを実行したときに登録されるジョブ。 * `gen-inputs-list` - 入力データ情報全件ファイルの更新。[postProjectInputsUpdate](#operation/postProjectInputsUpdate) APIを実行したときに登録されるジョブ。 * `delete-project` - プロジェクトの削除。[deleteProject](#operation/deleteProject) APIを実行したときに登録されるジョブ。 * `invoke-hook` - Webhookの起動。 + * `copy-project` - プロジェクトのコピー。[initiateProjectCopy](#operation/initiateProjectCopy) APIを実行したときに登録されるジョブ。 * `gen-inputs` - zipファイルから入力データの作成。[putInputData](#operation/putInputData) APIを実行して、zipファイルから入力データを作成したときに登録されるジョブ。 * `gen-tasks` - タスクの一括作成。[initiateTasksGeneration](#operation/initiateTasksGeneration) APIを実行したときに登録されるジョブ。 * `gen-annotation` - アノテーションZIPの更新。[postAnnotationArchiveUpdate](#operation/postAnnotationArchiveUpdate) APIを実行したときに登録されるジョブ。 * `gen-tasks-list` - タスク全件ファイルの更新。[postProjectTasksUpdate](#operation/postProjectTasksUpdate) APIを実行したときに登録されるジョブ。 * `gen-inputs-list` - 入力データ情報全件ファイルの更新。[postProjectInputsUpdate](#operation/postProjectInputsUpdate) APIを実行したときに登録されるジョブ。 * `delete-project` - プロジェクトの削除。[deleteProject](#operation/deleteProject) APIを実行したときに登録されるジョブ。 * `invoke-hook` - Webhookの起動。 * `move-project` - プロジェクトの組織移動。[putProject](#operation/putProject) API で組織を変更したときに登録されるジョブ。 """ COPY_PROJECT = "copy-project" @@ -2270,6 +1937,7 @@ class JobType(Enum): GEN_INPUTS_LIST = "gen-inputs-list" DELETE_PROJECT = "delete-project" INVOKE_HOOK = "invoke-hook" + MOVE_PROJECT = "move-project" Keybind = Dict[str, Any] @@ -2469,6 +2137,33 @@ class JobType(Enum): * message: str 多言語対応 +""" + +MessageOrJobInfo = Dict[str, Any] +""" + + +Kyes of Dict + +* message: str + 多言語対応 +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* job_type: JobType + +* job_id: str + +* job_status: JobStatus + +* job_execution: __DictStrKeyAnyValue__ + ジョブの内部情報 +* job_detail: __DictStrKeyAnyValue__ + ジョブ結果の内部情報 +* created_datetime: str + +* updated_datetime: str + + """ MyAccount = Dict[str, Any] @@ -2540,6 +2235,27 @@ class JobType(Enum): * my_status: OrganizationMemberStatus +""" + +MyOrganizationList = Dict[str, Any] +""" + + +Kyes of Dict + +* list: List[MyOrganization] + 現在のページ番号に含まれる0件以上の所属組織です。 +* page_no: float + 現在のページ番号です。 +* total_page_no: float + 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる所属組織が0件であっても、総ページ数は1となります。 +* total_count: float + 検索結果の総件数。 +* over_limit: bool + 検索結果が1万件を超えた場合にtrueとなる。 +* aggregations: List[AggregationResult] + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + """ Organization = Dict[str, Any] @@ -2578,23 +2294,6 @@ class JobType(Enum): * storage_usage_bytes: float -""" - -OrganizationCacheRecord = Dict[str, Any] -""" - - -Kyes of Dict - -* input: str - -* members: str - -* statistics: str - -* organization: str - - """ OrganizationMember = Dict[str, Any] @@ -2624,6 +2323,27 @@ class JobType(Enum): """ +OrganizationMemberList = Dict[str, Any] +""" + + +Kyes of Dict + +* list: List[OrganizationMember] + +* page_no: float + 現在のページ番号です。 +* total_page_no: float + 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる組織メンバーが0件であっても、総ページ数は1となります。 +* total_count: float + 検索結果の総件数。 +* over_limit: bool + 検索結果が1万件を超えた場合にtrueとなる。 +* aggregations: List[AggregationResult] + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + +""" + class OrganizationMemberRole(Enum): """ @@ -2660,11 +2380,30 @@ class OrganizationMemberStatus(Enum): プラグインの説明です。 プラグイン一覧や、プロジェクトで使うプラグインを選ぶときなどに表示されます。 * annotation_editor_url: str カスタムアノテーションエディタでタスクを開くための URL です。 プラグインを使用するプロジェクトのタスク一覧などで使用されます。 この URL には、タスクを特定するための以下のパラメータを必ず埋め込んでください。 * `{projectId}` * `{taskId}` 以下のパラメーターは任意で指定します。 * `{inputDataId}`: アノテーション一覧などから、特定の入力データにフォーカスした状態でタスクを開くときなどに指定します。 * `{annotationId}`: アノテーション一覧などから、特定のアノテーションにフォーカスした状態でタスクを開くときなどに指定します。 +* compatible_input_data_types: List[InputDataType] + プラグインが対応している入力データです。 * created_datetime: str * updated_datetime: str +""" + +OrganizationPluginList = Dict[str, Any] +""" + + +Kyes of Dict + +* list: List[OrganizationPlugin] + +* page_no: float + 現在のページ番号です。 +* total_page_no: float + 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 +* total_count: float + 検索結果の総件数。 + """ OrganizationRegistrationRequest = Dict[str, Any] @@ -2756,6 +2495,19 @@ class OrganizationMemberStatus(Enum): * job: JobInfo +""" + +PostAnnotationArchiveUpdateResponseWrapper = Dict[str, Any] +""" + + +Kyes of Dict + +* message: str + 多言語対応 +* job: JobInfo + + """ PostProjectTasksUpdateResponse = Dict[str, Any] @@ -2767,6 +2519,19 @@ class OrganizationMemberStatus(Enum): * job: JobInfo +""" + +PostProjectTasksUpdateResponseWrapper = Dict[str, Any] +""" + + +Kyes of Dict + +* message: str + 多言語対応 +* job: JobInfo + + """ @@ -2835,31 +2600,6 @@ class PricePlan(Enum): * worktime: str 作業時間(ISO 8601 duration) -""" - -ProjectCacheRecord = Dict[str, Any] -""" - - -Kyes of Dict - -* input: str - -* members: str - -* project: str - -* instruction: str - -* specs: str - -* statistics: str - -* organization: str - -* supplementary: str - - """ ProjectConfiguration = Dict[str, Any] @@ -2889,6 +2629,19 @@ class PricePlan(Enum): * private_storage_aws_iam_role_arn: str AWS IAMロール。ビジネスプランでのS3プライベートストレージの認可で使います。 [S3プライベートストレージの認可の設定についてはこちら](/docs/faq/#m0b240)をご覧ください。 +""" + +ProjectContainer = Dict[str, Any] +""" + + +Kyes of Dict + +* list: List[Project] + +* has_next: bool + + """ ProjectCopyRequest = Dict[str, Any] @@ -2929,6 +2682,39 @@ class PricePlan(Enum): * dest_project: Project +""" + +ProjectCopyResponseWrapper = Dict[str, Any] +""" + + +Kyes of Dict + +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* organization_id: str + 組織ID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* title: str + プロジェクトのタイトル +* overview: str + プロジェクトの概要 +* project_status: ProjectStatus + +* input_data_type: InputDataType + +* configuration: ProjectConfiguration + +* created_datetime: str + +* updated_datetime: str + +* summary: ProjectSummary + +* job: JobInfo + +* dest_project: Project + + """ ProjectInputsUpdateResponse = Dict[str, Any] @@ -2940,6 +2726,27 @@ class PricePlan(Enum): * job: JobInfo +""" + +ProjectList = Dict[str, Any] +""" + + +Kyes of Dict + +* list: List[Project] + 現在のページ番号に含まれる0件以上のプロジェクトです。 +* page_no: float + 現在のページ番号です。 +* total_page_no: float + 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 +* total_count: float + 検索結果の総件数。 +* over_limit: bool + 検索結果が1万件を超えた場合にtrueとなる。 +* aggregations: List[AggregationResult] + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + """ ProjectMember = Dict[str, Any] @@ -2973,6 +2780,27 @@ class PricePlan(Enum): """ +ProjectMemberList = Dict[str, Any] +""" + + +Kyes of Dict + +* list: List[ProjectMember] + +* page_no: float + 現在のページ番号です。 +* total_page_no: float + 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトメンバーが0件であっても、総ページ数は1となります。 +* total_count: float + 検索結果の総件数。 +* over_limit: bool + 検索結果が1万件を超えた場合にtrueとなる。 +* aggregations: List[AggregationResult] + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + +""" + ProjectMemberRequest = Dict[str, Any] """ @@ -3032,32 +2860,6 @@ class ProjectStatus(Enum): """ -ProjectTaskCounts = Dict[str, Any] -""" - - -Kyes of Dict - -* task_counts: List[ProjectTaskCountsTaskCounts] - - -""" - -ProjectTaskCountsTaskCounts = Dict[str, Any] -""" - - -Kyes of Dict - -* phase: TaskPhase - -* status: TaskStatus - -* count: float - 該当するタスクの数 - -""" - ProjectTaskStatistics = Dict[str, Any] """ @@ -3162,6 +2964,8 @@ class ProjectStatus(Enum): プラグインの説明です。 プラグイン一覧や、プロジェクトで使うプラグインを選ぶときなどに表示されます。 * annotation_editor_url: str カスタムアノテーションエディタでタスクを開くための URL です。 プラグインを使用するプロジェクトのタスク一覧などで使用されます。 この URL には、タスクを特定するための以下のパラメータを必ず埋め込んでください。 * `{projectId}` * `{taskId}` 以下のパラメーターは任意で指定します。 * `{inputDataId}`: アノテーション一覧などから、特定の入力データにフォーカスした状態でタスクを開くときなどに指定します。 * `{annotationId}`: アノテーション一覧などから、特定のアノテーションにフォーカスした状態でタスクを開くときなどに指定します。 +* compatible_input_data_types: List[InputDataType] + プラグインが対応している入力データです。 * last_updated_datetime: str 新規作成時は未指定、更新時は必須(更新前の日時) @@ -3190,6 +2994,52 @@ class ProjectStatus(Enum): * force_suspend: bool 作業中タスクがあるプロジェクトを停止する時trueにして下さい +""" + +PutProjectResponse = Dict[str, Any] +""" + + +Kyes of Dict + +* job: JobInfo + +* project: Project + + +""" + +PutProjectResponseWrapper = Dict[str, Any] +""" + + +Kyes of Dict + +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* organization_id: str + 組織ID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* title: str + プロジェクトのタイトル +* overview: str + プロジェクトの概要 +* project_status: ProjectStatus + +* input_data_type: InputDataType + +* configuration: ProjectConfiguration + +* created_datetime: str + +* updated_datetime: str + +* summary: ProjectSummary + +* job: JobInfo + +* project: Project + + """ RefreshTokenRequest = Dict[str, Any] @@ -3387,7 +3237,64 @@ class SupplementaryDataType(Enum): IMAGE = "image" TEXT = "text" + CUSTOM = "custom" + + +SystemMetadata = Dict[str, Any] +""" +* `SystemMetadataImage`: 画像プロジェクトの場合。画像データ固有のメタデータが保存されます。 * `SystemMetadataMovie`: 動画プロジェクトの場合。動画データ固有のメタデータが保存されます。 * `SystemMetadataCustom`: カスタムプロジェクトの場合。カスタムデータ固有のメタデータが保存されます。 `metadata` プロパティとは違い、ユーザー側では値を編集できない読取専用のプロパティです。 + +Kyes of Dict + +* original_resolution: Resolution + +* resized_resolution: Resolution + +* type: str + `Custom` +* input_duration: float + 入力データが動画の場合、動画の長さ(秒)。小数点以下はミリ秒以下を表します。 動画の長さが取得できなかった場合は値なし。 + +""" + +SystemMetadataCustom = Dict[str, Any] +""" +カスタムデータ用システムメタデータ。 現行はプロパティがない形式的なオブジェクトです。 + +Kyes of Dict + +* type: str + `Custom` + +""" + +SystemMetadataImage = Dict[str, Any] +""" +画像データ用システムメタデータ。 + +Kyes of Dict + +* original_resolution: Resolution + +* resized_resolution: Resolution + +* type: str + `Image` + +""" + +SystemMetadataMovie = Dict[str, Any] +""" +動画データ用システムメタデータ。 + +Kyes of Dict + +* input_duration: float + 入力データが動画の場合、動画の長さ(秒)。小数点以下はミリ秒以下を表します。 動画の長さが取得できなかった場合は値なし。 +* type: str + `Movie` +""" Task = Dict[str, Any] """ @@ -3430,8 +3337,25 @@ class SupplementaryDataType(Enum): Kyes of Dict -* request_type: OneOfTaskAssignRequestTypeRandomTaskAssignRequestTypeSelection - * `TaskAssignRequestTypeRandom`: タスクフェーズのみを指定してランダムにタスクを自身に割当します。プロジェクト設定でタスクのランダム割当を有効にした場合のみ利用できます。 * `TaskAssignRequestTypeSelection`: 担当者とタスクを明示的に指定してタスクを割当します。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。プロジェクト設定でタスクの選択割当を有効にした場合のみ利用できます。 +* request_type: TaskAssignRequestType + + +""" + +TaskAssignRequestType = Dict[str, Any] +""" +* `TaskAssignRequestTypeRandom`: タスクフェーズのみを指定してランダムにタスクを自身に割当します。プロジェクト設定でタスクのランダム割当を有効にした場合のみ利用できます。 * `TaskAssignRequestTypeSelection`: 担当者とタスクを明示的に指定してタスクを割当します。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。プロジェクト設定でタスクの選択割当を有効にした場合のみ利用できます。 + +Kyes of Dict + +* phase: TaskPhase + +* type: str + Selection +* user_id: str + +* task_ids: List[str] + 割当するタスクのID """ @@ -3442,7 +3366,7 @@ class SupplementaryDataType(Enum): Kyes of Dict * phase: TaskPhase - 割当するタスクフェーズ。[詳細はこちら](#section/TaskPhase) + * type: str Random @@ -3455,7 +3379,7 @@ class SupplementaryDataType(Enum): Kyes of Dict * user_id: str - タスクを誰に割当するか + * task_ids: List[str] 割当するタスクのID * type: str @@ -3480,8 +3404,8 @@ class TaskAssignmentType(Enum): Kyes of Dict -* task_generate_rule: OneOfTaskGenerateRuleByCountTaskGenerateRuleByDirectoryTaskGenerateRuleByInputDataCsv - * `TaskGenerateRuleByCount`: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 * `TaskGenerateRuleByDirectory`: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。 * `TaskGenerateRuleByInputDataCsv`: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 +* task_generate_rule: TaskGenerateRule + * project_last_updated_datetime: str プロジェクトの最終更新日時([getProject](#operation/getProject) APIのレスポンス `updated_datetime`)。タスク生成の排他制御に使用。 @@ -3498,6 +3422,62 @@ class TaskAssignmentType(Enum): * project: Project +""" + +TaskGenerateResponseWrapper = Dict[str, Any] +""" + + +Kyes of Dict + +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* organization_id: str + 組織ID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* title: str + プロジェクトのタイトル +* overview: str + プロジェクトの概要 +* project_status: ProjectStatus + +* input_data_type: InputDataType + +* configuration: ProjectConfiguration + +* created_datetime: str + +* updated_datetime: str + +* summary: ProjectSummary + +* job: JobInfo + +* project: Project + + +""" + +TaskGenerateRule = Dict[str, Any] +""" +* `TaskGenerateRuleByCount`: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 * `TaskGenerateRuleByDirectory`: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。 * `TaskGenerateRuleByInputDataCsv`: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 + +Kyes of Dict + +* task_id_prefix: str + 生成するタスクIDのプレフィックス。[値の制約についてはこちら。](#section/API-Convention/APIID) +* allow_duplicate_input_data: bool + falseのときは、既にタスクに使われている入力データを除外し、まだタスクに使われていない入力データだけを新しいタスクに割り当てます。trueのときは、既にタスクに使われている入力データを除外しません。 +* input_data_count: int + 1つのタスクに割り当てる入力データの個数 +* input_data_order: InputDataOrder + +* type: str + `ByInputDataCsv` [詳しくはこちら](#section/API-Convention/API-_type) +* input_data_name_prefix: str + タスク生成対象の入力データ名プレフィックス +* csv_data_path: str + 各タスクへの入力データへの割当を記入したCSVへのS3上のパス + """ TaskGenerateRuleByCount = Dict[str, Any] @@ -3574,47 +3554,41 @@ class TaskAssignmentType(Enum): """ -TaskHistoryEvent = Dict[str, Any] +TaskHistoryShort = Dict[str, Any] """ -タスク履歴イベントは、タスクの状態が変化した1時点を表します。作業時間は、複数のこれらイベントを集約して計算するものなので、このオブジェクトには含まれません。 +タスクのあるフェーズを誰が担当したかを表します。 Kyes of Dict -* project_id: str - プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) -* task_id: str - タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) -* task_history_id: str - -* created_datetime: str - * phase: TaskPhase * phase_stage: int -* status: TaskStatus - * account_id: str -* request: TaskOperation - +* worked: bool + そのフェーズでタスクの作業を行ったかどうか(行った場合はtrue) """ -TaskHistoryShort = Dict[str, Any] +TaskList = Dict[str, Any] """ -タスクのあるフェーズを誰が担当したかを表します。 + Kyes of Dict -* phase: TaskPhase - -* phase_stage: int - -* account_id: str - -* worked: bool - そのフェーズでタスクの作業を行ったかどうか(行った場合はtrue) +* list: List[Task] + 現在のページ番号に含まれる0件以上のタスクです。 +* page_no: float + 現在のページ番号です。 +* total_page_no: float + 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるタスク0件であっても、総ページ数は1となります。 +* total_count: float + 検索結果の総件数。 +* over_limit: bool + 検索結果が1万件を超えた場合にtrueとなる。 +* aggregations: List[AggregationResult] + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 """ @@ -3625,11 +3599,11 @@ class TaskAssignmentType(Enum): Kyes of Dict * status: TaskStatus - 次に遷移させるタスクの状態。[詳細はこちら](#section/TaskStatus)。 + * last_updated_datetime: str - タスクの最終更新日時 + 新規作成時は未指定、更新時は必須(更新前の日時) * account_id: str - 変更後の担当者のアカウントID。担当者を未割り当てにする場合は未指定。 + * force: bool タスクの強制操作を行う場合に立てるフラグ。現在、強制操作は強制差戻しのみがサポートされています。 @@ -3711,6 +3685,17 @@ class TaskStatus(Enum): * inputs: List[InputDataSummary] +""" + +TemporaryUrl = Dict[str, Any] +""" +認証済み一時URL + +Kyes of Dict + +* url: str + 認証済み一時URL + """ Token = Dict[str, Any] diff --git a/annofabapi/wrapper.py b/annofabapi/wrapper.py index 64045b69..235f3d81 100644 --- a/annofabapi/wrapper.py +++ b/annofabapi/wrapper.py @@ -60,6 +60,7 @@ class AnnotationQuery: """ 削除対象のアノテーションを指定するクエリ """ + label_id: str @@ -366,7 +367,7 @@ def copy_annotation( return True @staticmethod - def __match_query_for_annotation(annotation_detail: Dict[str, Any], query:AnnotationQuery) -> bool: + def __match_query_for_annotation(annotation_detail: Dict[str, Any], query: AnnotationQuery) -> bool: return annotation_detail["label_id"] == query.label_id @staticmethod @@ -377,7 +378,9 @@ def __to_put_annotation_detail(annotation_detail: Dict[str, Any]) -> Dict[str, A annotation_detail["url"] = None return annotation_detail - def delete_annotation(self, project_id: str, task_id: str, input_data_id: str, query:Optional[AnnotationQuery]=None) -> Optional[Dict[str, Any]]: + def delete_annotation( + self, project_id: str, task_id: str, input_data_id: str, query: Optional[AnnotationQuery] = None + ) -> Optional[Dict[str, Any]]: """ 特定のアノテーションを削除する @@ -398,7 +401,11 @@ def delete_annotation(self, project_id: str, task_id: str, input_data_id: str, q if query is None: new_details = [] else: - new_details = [self.__to_put_annotation_detail(d) for d in old_details if not self.__match_query_for_annotation(d, query)] + new_details = [ + self.__to_put_annotation_detail(d) + for d in old_details + if not self.__match_query_for_annotation(d, query) + ] updated_datetime = old_annotation["updated_datetime"] request_body = { @@ -410,8 +417,6 @@ def delete_annotation(self, project_id: str, task_id: str, input_data_id: str, q } return self.api.put_annotation(project_id, task_id, input_data_id, request_body=request_body)[0] - - ######################################### # Public Method : AnnotationSpecs ######################################### From 5624ebc75cdb30db13989ede66c8067596484961 Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 00:53:08 +0900 Subject: [PATCH 08/15] update --- annofabapi/dataclass/annotation.py | 2 +- annofabapi/dataclass/annotation_specs.py | 2 +- annofabapi/dataclass/input.py | 1 + annofabapi/dataclass/inspection.py | 2 +- generate/partial-header/dataclass/annotation.py | 2 +- generate/partial-header/dataclass/annotation_specs.py | 3 ++- generate/partial-header/dataclass/input.py | 1 + generate/partial-header/dataclass/inspection.py | 2 +- 8 files changed, 9 insertions(+), 6 deletions(-) diff --git a/annofabapi/dataclass/annotation.py b/annofabapi/dataclass/annotation.py index 7452a734..9b9edce3 100644 --- a/annofabapi/dataclass/annotation.py +++ b/annofabapi/dataclass/annotation.py @@ -24,7 +24,7 @@ TaskStatus, ) -OneOfstringFullAnnotationData = Union[str, Dict[str, Any]] +AnnotationData = Union[str, Dict[str, Any]] FullAnnotationData = Dict[str, Any] AdditionalDataValue = Dict[str, Any] diff --git a/annofabapi/dataclass/annotation_specs.py b/annofabapi/dataclass/annotation_specs.py index 9fe1e0ca..b7d0ce92 100644 --- a/annofabapi/dataclass/annotation_specs.py +++ b/annofabapi/dataclass/annotation_specs.py @@ -17,7 +17,7 @@ from annofabapi.models import AdditionalDataDefinitionType, AnnotationType -OneOfbooleanintegerstring = Union[bool, int, str] +AdditionalDataDefaultType = Union[bool, int, str] AdditionalDataRestrictionCondition = Dict[str, Any] diff --git a/annofabapi/dataclass/input.py b/annofabapi/dataclass/input.py index 10236a39..2cfff15b 100644 --- a/annofabapi/dataclass/input.py +++ b/annofabapi/dataclass/input.py @@ -15,6 +15,7 @@ from dataclasses_json import dataclass_json +SystemMetadata = Dict[str, Any] @dataclass_json @dataclass diff --git a/annofabapi/dataclass/inspection.py b/annofabapi/dataclass/inspection.py index 7ab3f6aa..e2a7d67e 100644 --- a/annofabapi/dataclass/inspection.py +++ b/annofabapi/dataclass/inspection.py @@ -17,7 +17,7 @@ from annofabapi.models import InspectionStatus, TaskPhase -OneOfInspectionDataPointInspectionDataPolylineInspectionDataTime = Dict[str, Any] +InspectionData = Dict[str, Any] @dataclass_json diff --git a/generate/partial-header/dataclass/annotation.py b/generate/partial-header/dataclass/annotation.py index 9ceee2c4..e4470433 100644 --- a/generate/partial-header/dataclass/annotation.py +++ b/generate/partial-header/dataclass/annotation.py @@ -7,6 +7,6 @@ TaskStatus, ) -OneOfstringFullAnnotationData = Union[str, Dict[str, Any]] +AdditionalDataValue = Union[str, Dict[str, Any]] FullAnnotationData = Dict[str, Any] AdditionalDataValue = Dict[str, Any] diff --git a/generate/partial-header/dataclass/annotation_specs.py b/generate/partial-header/dataclass/annotation_specs.py index a0e49f01..75ce000f 100644 --- a/generate/partial-header/dataclass/annotation_specs.py +++ b/generate/partial-header/dataclass/annotation_specs.py @@ -1,5 +1,6 @@ from annofabapi.models import AdditionalDataDefinitionType, AnnotationType -OneOfbooleanintegerstring = Union[bool, int, str] +AdditionalDataDefaultType = Union[bool, int, str] AdditionalDataRestrictionCondition = Dict[str, Any] + diff --git a/generate/partial-header/dataclass/input.py b/generate/partial-header/dataclass/input.py index e69de29b..c1475b0b 100644 --- a/generate/partial-header/dataclass/input.py +++ b/generate/partial-header/dataclass/input.py @@ -0,0 +1 @@ +SystemMetadata = Dict[str, Any] \ No newline at end of file diff --git a/generate/partial-header/dataclass/inspection.py b/generate/partial-header/dataclass/inspection.py index 59ceaabc..49f8b8bd 100644 --- a/generate/partial-header/dataclass/inspection.py +++ b/generate/partial-header/dataclass/inspection.py @@ -1,4 +1,4 @@ from annofabapi.models import InspectionStatus, TaskPhase -OneOfInspectionDataPointInspectionDataPolylineInspectionDataTime = Dict[str, Any] +InspectionData = Dict[str, Any] From c98faf49b0e238ca584ba1cd4e22392af26b59e4 Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 09:50:53 +0900 Subject: [PATCH 09/15] update generate.sh --- generate/generate.sh | 22 +++++++++++++++++--- generate/swagger/swagger-partial-header.yaml | 10 +++++++++ 2 files changed, 29 insertions(+), 3 deletions(-) create mode 100644 generate/swagger/swagger-partial-header.yaml diff --git a/generate/generate.sh b/generate/generate.sh index 082f555a..bdc84fc6 100755 --- a/generate/generate.sh +++ b/generate/generate.sh @@ -58,6 +58,9 @@ if "${FLAG_DOWNLOAD}"; then # cat swagger/swagger-tmp.v2.yaml swagger/swagger-api-components.yaml > swagger/swagger.v2.yaml # # rm swagger/swagger-tmp.yaml swagger/swagger-tmp.v2.yaml + + cat swagger/swagger-partial-header.yaml swagger/swagger-api-components.yaml > swagger/swagger-models.yaml + fi @@ -72,7 +75,7 @@ docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=$ --input-spec swagger/swagger.yaml \ ${OPENAPI_GENERATOR_CLI_COMMON_OPTION} \ --template-dir /local/template \ - --global-property=apis,apiTests=false,apiDocs=false,models,modelTests=false,modelDocs=false \ + --global-property apis,apiTests=false,apiDocs=false \ --ignore-file-override=/local/.openapi-generator-ignore_v1 cat partial-header/generated_api_partial_header_v1.py out/openapi_client/api/*_api.py > ../annofabapi/generated_api.py @@ -87,20 +90,30 @@ docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=${ --input-spec swagger/swagger.v2.yaml \ ${OPENAPI_GENERATOR_CLI_COMMON_OPTION} \ --template-dir /local/template \ - --global-property=apis,apiTests=false,apiDocs=false \ + --global-property apis,apiTests=false,apiDocs=false \ --ignore-file-override=/local/.openapi-generator-ignore_v2 cat partial-header/generated_api_partial_header_v2.py out/openapi_client/api/*_api.py > ../annofabapi/generated_api2.py rm -Rf out/openapi_client + +# modelsを生成 +docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=${JAVA_OPTS} ${DOCKER_IMAGE} generate \ + --input-spec swagger/swagger-models.yaml \ + ${OPENAPI_GENERATOR_CLI_COMMON_OPTION} \ + --template-dir /local/template \ + --global-property ,models,modelTests=false,modelDocs=false \ + --ignore-file-override=/local/.openapi-generator-ignore_v1 + + # v1 apiのmodelからDataClass用のpythonファイルを生成する。 docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=${JAVA_OPTS} \ ${DOCKER_IMAGE} generate \ --input-spec swagger/swagger.yaml \ ${OPENAPI_GENERATOR_CLI_COMMON_OPTION} \ --template-dir /local/template_dataclass \ - --global-property=models,modelTests=false,modelDocs=false \ + --global-property models,modelTests=false,modelDocs=false \ MODELS_DIR=out/openapi_client/models @@ -119,6 +132,9 @@ declare -a model_files=(${MODELS_DIR}/point.py \ ${MODELS_DIR}/full_annotation_data_single_point.py \ ${MODELS_DIR}/full_annotation_data_range.py \ ${MODELS_DIR}/additional_data.py \ + ${MODELS_DIR}/full_annotation_additional_data.py \ + ${MODELS_DIR}/full_annotation_detail.py \ + ${MODELS_DIR}/full_annotation.py \ ${MODELS_DIR}/simple_annotation_detail.py \ ${MODELS_DIR}/simple_annotation.py \ ${MODELS_DIR}/single_annotation_detail.py \ diff --git a/generate/swagger/swagger-partial-header.yaml b/generate/swagger/swagger-partial-header.yaml new file mode 100644 index 00000000..1b8eacd4 --- /dev/null +++ b/generate/swagger/swagger-partial-header.yaml @@ -0,0 +1,10 @@ +openapi: "3.0.0" +info: + version: 1.0.0 + title: swagger-api-components.yaml に記載されたschemaを出力するためのヘッダ部分 +paths: + /none: + get: + responses: + '200': + description: none From c86ae35cd4ea3925948ac3b7e7a6b062844728f8 Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 09:51:05 +0900 Subject: [PATCH 10/15] update generate.sh --- generate/swagger/swagger-models.yaml | 4418 ++++++++++++++++++++++++++ 1 file changed, 4418 insertions(+) create mode 100644 generate/swagger/swagger-models.yaml diff --git a/generate/swagger/swagger-models.yaml b/generate/swagger/swagger-models.yaml new file mode 100644 index 00000000..f714c92b --- /dev/null +++ b/generate/swagger/swagger-models.yaml @@ -0,0 +1,4418 @@ +openapi: "3.0.0" +info: + version: 1.0.0 + title: swagger-api-components.yaml に記載されたschemaを出力するためのヘッダ部分 +paths: + /none: + get: + responses: + '200': + description: none +components: + securitySchemes: + SignedCookieKeyPairId: + description: | + 認証/認可には、[sign-url](#operation/getSignedAccessV2) APIで取得した署名付きCookieを使います。 + type: "apiKey" + in: "cookie" + name: "CloudFront-Key-Pair-Id" + SignedCookiePolicy: + description: | + 認証/認可には、[sign-url](#operation/getSignedAccessV2) APIで取得した署名付きCookieを使います。 + type: "apiKey" + in: "cookie" + name: "CloudFront-Policy" + SignedCookieSignature: + description: | + 認証/認可には、[sign-url](#operation/getSignedAccessV2) APIで取得した署名付きCookieを使います。 + type: "apiKey" + in: "cookie" + name: "CloudFront-Signature" + EveryoneRequestBody: + description: | + AnnoFabのユーザーなら誰でも利用できます。 + + 認証/認可には、リクエストボディに含まれるパスワード、トークン、または何らかの検証コードを用います。 + 詳しくは個別のAPIの説明を確認してください。 + type: "http" + scheme: "requestBody" + EveryoneQueryParameter: + description: | + AnnoFabのユーザーなら誰でも利用できます。 + + 認証/認可には、クエリパラメータに含まれるトークンまたは何らかの検証コードを用います。 + 詳しくは個別のAPIの説明を確認してください。 + type: "http" + scheme: "requestBody" + Everyone: + description: | + AnnoFabのユーザーなら誰でも利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + AnnoFabAdminOnly: + description: | + AnnoFabのシステム管理者のみ利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + AllProjectMember: + description: | + プロジェクトに所属するユーザーなら誰でも利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + ProjectAccepter: + description: | + プロジェクトのオーナーまたはプロジェクトのチェッカーのみ利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + ProjectDataUser: + description: | + プロジェクトのオーナーまたはプロジェクトのアノテーションユーザーのみ利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + ProjectAccepterOrDataUser: + description: | + プロジェクトのオーナー/チェッカー/アノテーションユーザーのいずれかのみ利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + ProjectOwner: + description: | + プロジェクトのオーナーのみ利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + AllOrganizationMember: + description: | + 組織に所属するユーザーなら誰でも利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + OrganizationAdministrator: + description: | + 組織のオーナーまたは組織の管理者のみ利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + OrganizationOwner: + description: | + 組織のオーナーのみ利用できます。 + + 認証/認可には、HTTPリクエストの `Authorization` ヘッダーに格納されたIDトークンを用います。 + IDトークンは [login](#operation/login) または [refreshToken](#operation/refreshToken) API で取得できます。 + type: "apiKey" + name: "Authorization" + in: "header" + responses: + SuccessMessage: + description: 成功時のメッセージ + content: + application/json: + schema: + $ref: "#/components/schemas/Message" + ErrorForbiddenResource: + description: 権限エラー + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorForbiddenResource" + ErrorMissingResource: + description: 存在しないリソースを指定された + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorMissingResource" + ErrorUnauthorizedApi: + description: 認証エラー + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorUnauthorizedApi" + ErrorInvalidRequest: + description: リクエスト形式が正しくない。必要な属性が足りなかったり、属性が特定の値 + content: + application/json: + schema: + # TODO このエラー定義には複数のschemaのエラーが該当しうる。それを記述する(KRSANNOFAC-1502) + $ref: "#/components/schemas/Errors" + ErrorUnderMaintenance: + description: システムメンテナンス中 + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorUnderMaintenance" + ErrorRefreshTokenExpired: + description: リフレッシュトークン有効期限切れのため、明示的にログインする必要があります + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorRefreshTokenExpired" + schemas: + ProjectCacheRecord: + type: object + properties: + input: + type: string + members: + type: string + project: + type: string + instruction: + type: string + specs: + type: string + statistics: + type: string + organization: + type: string + supplementary: + type: string + Errors: + type: object + properties: + errors: + type: array + items: + $ref: "#/components/schemas/ErrorItem" + context: + type: object + description: 内部補足情報 + ErrorItem: + type: object + properties: + error_code: + type: string + message: + type: string + description: エラーの概要 + ext: + type: object + description: 補足情報 + ErrorInvalidBody: + $ref: '#/components/schemas/Errors' + ErrorInvalidQueryParam: + $ref: '#/components/schemas/Errors' + ErrorMissingNecessaryQueryParam: + $ref: '#/components/schemas/Errors' + ErrorInvalidPath: + $ref: '#/components/schemas/Errors' + ErrorUnauthorizedApi: + $ref: '#/components/schemas/Errors' + ErrorLoginFailed: + $ref: '#/components/schemas/Errors' + ErrorPasswordResetRequired: + $ref: '#/components/schemas/Errors' + ErrorExpiredToken: + $ref: '#/components/schemas/Errors' + ErrorRefreshTokenExpired: + $ref: '#/components/schemas/Errors' + ErrorForbiddenResource: + $ref: '#/components/schemas/Errors' + ErrorMissingResource: + $ref: '#/components/schemas/Errors' + ErrorTimeout: + $ref: '#/components/schemas/Errors' + ErrorAlreadyUpdated: + $ref: '#/components/schemas/Errors' + ErrorStateMismatch: + $ref: '#/components/schemas/Errors' + ErrorInternalServerError: + $ref: '#/components/schemas/Errors' + ErrorUnderMaintenance: + $ref: '#/components/schemas/Errors' + Message: + type: object + properties: + message: + type: string + description: 多言語対応 + InternationalizationMessage: + type: object + properties: + messages: + type: array + items: + type: object + properties: + lang: + type: string + message: + type: string + default_lang: + type: string + SignUpRequest: + type: object + required: + - email + properties: + email: + type: string + format: email + ConfirmSignUpRequest: + type: object + required: + - account_id + - user_id + - password + - username + - lang + - keylayout + - confirmation_code + properties: + account_id: + $ref: "#/components/schemas/AccountId" + user_id: + $ref: "#/components/schemas/UserId" + password: + type: string + username: + type: string + lang: + type: string + keylayout: + type: string + confirmation_code: + type: string + LoginRequest: + type: object + required: + - user_id + - password + properties: + user_id: + $ref: "#/components/schemas/UserId" + password: + type: string + LoginResponse: + type: object + properties: + token: + $ref: "#/components/schemas/Token" + Token: + type: object + properties: + id_token: + type: string + description: 形式は[JWT](https://jwt.io/)。 + access_token: + type: string + description: 形式は[JWT](https://jwt.io/)。 + refresh_token: + type: string + description: 形式は[JWT](https://jwt.io/)。 + RefreshTokenRequest: + type: object + required: + - refresh_token + properties: + refresh_token: + type: string + ChangePasswordRequest: + type: object + required: + - user_id + - old_password + - new_password + properties: + user_id: + $ref: "#/components/schemas/UserId" + old_password: + type: string + new_password: + type: string + PasswordResetRequest: + type: object + required: + - email + properties: + email: + type: string + format: email + ConfirmResetPasswordRequest: + type: object + required: + - user_id + - confirmation_code + - new_password + properties: + user_id: + $ref: "#/components/schemas/UserId" + confirmation_code: + type: string + new_password: + type: string + ResetEmailRequest: + type: object + required: + - email + properties: + email: + type: string + format: email + ConfirmResetEmailRequest: + type: object + required: + - token + properties: + token: + type: string + VerifyEmailRequest: + type: object + required: + - token + properties: + token: + $ref: "#/components/schemas/Token" + ConfirmVerifyEmailRequest: + type: object + required: + - token + - confirmation_code + properties: + token: + $ref: "#/components/schemas/Token" + confirmation_code: + type: string + ConfirmAccountDeleteRequest: + type: object + required: + - token + properties: + token: + type: string + Account: + type: object + required: + - account_id + - user_id + - username + - email + - lang + - keylayout + - authority + properties: + account_id: + $ref: "#/components/schemas/AccountId" + user_id: + $ref: "#/components/schemas/UserId" + username: + type: string + email: + type: string + format: email + lang: + type: string + biography: + $ref: "#/components/schemas/UserBiography" + keylayout: + type: string + authority: + $ref: "#/components/schemas/AccountAuthority" + updated_datetime: + type: string + format: date-time + AccountAuthority: + type: string + enum: + - user + - admin + MyAccount: + allOf: + - $ref: "#/components/schemas/Account" + - type: object + required: + - errors + properties: + reset_requested_email: + type: string + format: email + errors: + type: array + items: + type: string + PutMyAccountRequest: + type: object + required: + - user_id + - username + - lang + - keylayout + properties: + user_id: + $ref: "#/components/schemas/UserId" + username: + type: string + lang: + type: string + keylayout: + type: string + biography: + $ref: "#/components/schemas/UserBiography" + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + LastUpdatedDatetime: + type: string + format: date-time + description: | + 新規作成時は未指定、更新時は必須(更新前の日時) + AcceptOrganizationInvitationRequest: + type: object + properties: + token: + type: string + OrganizationActivity: + type: object + required: + - organization_id + - created_datetime + - storage_usage_bytes + properties: + organization_id: + $ref: "#/components/schemas/OrganizationId" + created_datetime: + type: string + format: date-time + storage_usage_bytes: + type: number + Organization: + type: object + required: + - organization_id + - organization_name + - email + - price_plan + - summary + - created_datetime + - updated_datetime + properties: + organization_id: + $ref: "#/components/schemas/OrganizationId" + organization_name: + type: string + email: + type: string + format: email + price_plan: + $ref: "#/components/schemas/PricePlan" + summary: + $ref: "#/components/schemas/OrganizationSummary" + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + OrganizationCacheRecord: + type: object + properties: + input: + type: string + members: + type: string + statistics: + type: string + organization: + type: string + OrganizationSummary: + type: object + properties: {} + PricePlan: + type: string + enum: + - free + - business + OrganizationMember: + type: object + required: + - organization_id + - account_id + - user_id + - username + - role + - status + properties: + organization_id: + $ref: "#/components/schemas/OrganizationId" + account_id: + $ref: "#/components/schemas/AccountId" + user_id: + $ref: "#/components/schemas/UserId" + username: + type: string + role: + $ref: "#/components/schemas/OrganizationMemberRole" + status: + $ref: "#/components/schemas/OrganizationMemberStatus" + biography: + $ref: "#/components/schemas/UserBiography" + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + OrganizationMemberRole: + type: string + enum: + - owner + - administrator + - contributor + OrganizationMemberStatus: + type: string + enum: + - active + - waiting_response + - inactive + description: | + * `active` - 組織メンバーとして有効で、組織を閲覧したり、権限があれば編集できます。 + * `waiting_response` - 組織に招待され、まだ加入/脱退を返答していません。組織の一部を閲覧のみできます。 + * `inactive` - 脱退したメンバーを表します。組織を閲覧できません。 + OrganizationPlugin: + type: object + required: + - organization_id + - plugin_id + - compatible_input_data_types + - created_datetime + - updated_datetime + properties: + organization_id: + $ref: "#/components/schemas/OrganizationId" + plugin_id: + $ref: "#/components/schemas/PluginId" + plugin_name: + $ref: "#/components/schemas/PluginName" + description: + $ref: "#/components/schemas/PluginDescription" + annotation_editor_url: + $ref: "#/components/schemas/AnnotationEditorUrl" + compatible_input_data_types: + $ref: "#/components/schemas/PluginCompatibleInputDataTypes" + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + PutOrganizationPluginRequest: + type: object + required: + - compatible_input_data_types + properties: + plugin_name: + $ref: "#/components/schemas/PluginName" + description: + $ref: "#/components/schemas/PluginDescription" + annotation_editor_url: + $ref: "#/components/schemas/AnnotationEditorUrl" + compatible_input_data_types: + $ref: "#/components/schemas/PluginCompatibleInputDataTypes" + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + PluginId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + プラグインID。[値の制約についてはこちら。](#section/API-Convention/APIID) + PluginName: + type: string + example: "foo-bar" + description: | + プラグインの名前です。 + プラグイン一覧や、プロジェクトで使うプラグインを選ぶときなどに表示されます。 + PluginDescription: + type: string + example: "desc" + description: | + プラグインの説明です。 + プラグイン一覧や、プロジェクトで使うプラグインを選ぶときなどに表示されます。 + PluginCompatibleInputDataTypes: + type: array + items: + $ref: "#/components/schemas/InputDataType" + example: ["custom"] + description: | + プラグインが対応している入力データです。 + AnnotationEditorUrl: + type: string + example: "https://example.com/my/editors?p={projectId}&t={taskId}" + description: | + カスタムアノテーションエディタでタスクを開くための URL です。 + プラグインを使用するプロジェクトのタスク一覧などで使用されます。 + + この URL には、タスクを特定するための以下のパラメータを必ず埋め込んでください。 + + * `{projectId}` + * `{taskId}` + + 以下のパラメーターは任意で指定します。 + + * `{inputDataId}`: アノテーション一覧などから、特定の入力データにフォーカスした状態でタスクを開くときなどに指定します。 + * `{annotationId}`: アノテーション一覧などから、特定のアノテーションにフォーカスした状態でタスクを開くときなどに指定します。 + + MyOrganization: + type: object + properties: + organization_id: + $ref: "#/components/schemas/OrganizationId" + name: + type: string + email: + type: string + format: email + price_plan: + $ref: "#/components/schemas/PricePlan" + summary: + $ref: "#/components/schemas/OrganizationSummary" + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + my_role: + $ref: "#/components/schemas/OrganizationMemberRole" + my_status: + $ref: "#/components/schemas/OrganizationMemberStatus" + OrganizationRegistrationRequest: + type: object + required: + - organization_name + - organization_email + - price_plan + properties: + organization_name: + $ref: "#/components/schemas/OrganizationName" + organization_email: + type: string + format: email + price_plan: + $ref: "#/components/schemas/PricePlan" + PutOrganizationNameRequest: + type: object + required: + - organization_id + - organization_name + - last_updated_datetime + properties: + organization_id: + type: string + organization_name: + $ref: "#/components/schemas/OrganizationName" + last_updated_datetime: + type: string + format: date-time + PutOrganizationMemberRoleRequest: + type: object + required: + - role + properties: + role: + $ref: "#/components/schemas/OrganizationMemberRole" + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + InviteOrganizationMemberRequest: + type: object + properties: + role: + $ref: "#/components/schemas/OrganizationMemberRole" + AccountId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + UserId: + type: string + example: "john_doe" + UserCacheRecord: + type: object + properties: + account: + type: string + members: + type: string + projects: + type: string + organizations: + type: string + OrganizationId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + 組織ID。[値の制約についてはこちら。](#section/API-Convention/APIID) + OrganizationName: + type: string + example: "sample-organization" + description: | + 組織名。[値の制約についてはこちら。](#section/API-Convention/APIID) + ProjectId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) + LabelId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + AdditionalDataDefinitionId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + ChoiceId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + PhraseId: + type: string + example: "my_phrase_id" + TaskId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) + InputDataId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) + InputDataSetId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + 入力データセットID。[値の制約についてはこちら。](#section/API-Convention/APIID) + SupplementaryDataId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + TaskHistoryId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + AnnotationId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
+ annotation_type が classification の場合は label_id と同じ値が格納されます。 + InspectionId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + 検査ID。[値の制約についてはこちら。](#section/API-Convention/APIID) + MarkerId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + マーカーID。[値の制約についてはこちら。](#section/API-Convention/APIID) + JobId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + WebhookId: + type: string + example: "12345678-abcd-1234-abcd-1234abcd5678" + description: | + WebhookID。[値の制約についてはこちら。](#section/API-Convention/APIID) + Duration: + type: string + example: "PT34H17M36.789S" + UserBiography: + type: string + description: | + 人物紹介、略歴。 + + この属性は、AnnoFab外の所属先や肩書などを表すために用います。 + AnnoFab上の「複数の組織」で活動する場合、本籍を示すのに便利です。 + minLength: 0 + maxLength: 100 + example: "Annotation Manager, ABC Company" + AnnotationFormatVersion: + type: string + example: "1.0.0" + description: | + アノテーションフォーマットのバージョンです。 + アノテーションフォーマットとは、プロジェクト個別のアノテーション仕様ではなく、AnnoFabのアノテーション構造のことです。 + したがって、アノテーション仕様を更新しても、このバージョンは変化しません。 + + バージョンの読み方と更新ルールは、業界慣習の[Semantic Versioning](https://semver.org/)にもとづきます。 + + JSONに出力されるアノテーションフォーマットのバージョンは、アノテーションZIPが作成される時点のものが使われます。 + すなわち、`1.0.0`の時点のタスクで作成したアノテーションであっても、フォーマットが `1.0.1` に上がった次のZIP作成時では `1.0.1` となります。 + バージョンを固定してZIPを残しておきたい場合は、プロジェクトが完了した時点でZIPをダウンロードして保管しておくか、またはプロジェクトを「停止中」にします。 + Project: + type: object + required: + - project_id + - organization_id + - title + - project_status + - input_data_type + - created_datetime + - updated_datetime + - configuration + - summary + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + organization_id: + $ref: "#/components/schemas/OrganizationId" + title: + type: string + description: プロジェクトのタイトル + overview: + type: string + description: プロジェクトの概要 + project_status: + $ref: "#/components/schemas/ProjectStatus" + input_data_type: + $ref: "#/components/schemas/InputDataType" + configuration: + $ref: "#/components/schemas/ProjectConfiguration" + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + summary: + $ref: "#/components/schemas/ProjectSummary" + ProjectStatus: + type: string + enum: + - active + - suspended + description: | + プロジェクトの状態 + * `active` - プロジェクトが進行中 + * `suspended` - プロジェクトが停止中 + AssigneeRuleOfResubmittedTask: + type: string + enum: + - no_assignee + - fixed + description: | + 再提出されたタスクの検査/受入担当者の割当方法 + * `no_assignee` - 以前の担当者で固定せず、未割当てにします。 + * `fixed` - 以前の担当者が再度担当します。以前の担当者がいない(1回目の検査/受入)場合は未割当てになります。 + InputDataType: + type: string + description: | + アノテーションする入力データの種類。プロジェクトの作成時のみ指定可能(未指定の場合は `image`)です。更新時は無視されます。 + * `image` - 画像 + * `movie` - 動画 + * `custom` - カスタム + enum: + - image + - movie + - custom + ProjectConfiguration: + type: object + properties: + number_of_inspections: + description: | + 検査回数。 + * 0回:教師付け -> 受入 + * 1回:教師付け -> 検査 -> 受入 + * n回(n >= 2):教師付け -> 検査1 -> ... -> 検査n -> 受入 + type: integer + default: 0 + minimum: 0 + assignee_rule_of_resubmitted_task: + description: 再提出されたタスクの検査/受入担当者ルール。 + $ref: "#/components/schemas/AssigneeRuleOfResubmittedTask" + default: no_assignee + task_assignment_type: + $ref: "#/components/schemas/TaskAssignmentType" + max_tasks_per_member: + description: 保留中のタスクを除き、1人(オーナー以外)に割り当てられるタスク数上限。未指定の場合は10件として扱う。 + type: integer + default: 10 + minimum: 1 + maximum: 100 + max_tasks_per_member_including_hold: + description: 保留中のタスクを含めて、1人(オーナー以外)に割り当てられるタスク数上限。未指定の場合は20件として扱う。 + type: integer + default: 20 + minimum: 1 + maximum: 100 + input_data_set_id_list: + description: このフィールドは内部用でまだ何も意味を成しません。今は空配列を指定してください。 + type: array + items: + $ref: "#/components/schemas/InputDataSetId" + example: [] + input_data_max_long_side_length: + description: | + 入力データ画像の長辺の最大値(未指定時は4096px)。 + + 画像をアップロードすると、長辺がこの値になるように画像が自動で圧縮されます。 + アノテーションの座標は、もとの解像度の画像でつけたものに復元されます。 + + 大きな数値を設定すると入力データ画像のサイズが大きくなり、生産性低下やブラウザで画像を表示できない懸念があります。注意して設定してください。 + type: integer + default: 4096 + minimum: 0 + sampling_inspection_rate: + description: 抜取検査率。0-100のパーセント値で指定し、未指定の場合は100%として扱う。 + type: integer + sampling_acceptance_rate: + description: 抜取受入率。0-100のパーセント値で指定し、未指定の場合は100%として扱う。 + type: integer + private_storage_aws_iam_role_arn: + type: string + description: | + AWS IAMロール。ビジネスプランでのS3プライベートストレージの認可で使います。 + [S3プライベートストレージの認可の設定についてはこちら](/docs/faq/#m0b240)をご覧ください。 + example: "arn:aws:iam::123456789012:role/AnnoFabPrivateStorageAccessor" + ProjectSummary: + type: object + properties: + last_tasks_updated_datetime: + type: string + format: date-time + description: タスクの最終更新日時 + TaskAssignmentType: + type: string + default: random + enum: + - random + - selection + - random_and_selection + description: | + プロジェクトで使用するタスクの割当方式。 + + * `random` - タスクフェーズのみを指定してランダムにタスクを自身に割当する方式です。 + * `selection` - 担当者とタスクを明示的に指定してタスクを割当する方式です。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。 + * `random_and_selection` - ランダム割当と選択割当の両機能を使用する方式です。 + JobInfo: + type: object + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + job_type: + $ref: "#/components/schemas/JobType" + job_id: + $ref: "#/components/schemas/JobId" + job_status: + $ref: "#/components/schemas/JobStatus" + job_execution: + type: object + description: ジョブの内部情報 + job_detail: + type: object + description: ジョブ結果の内部情報 + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + JobType: + type: string + enum: + - copy-project + - gen-inputs + - gen-tasks + - gen-annotation + - gen-tasks-list + - gen-inputs-list + - delete-project + - invoke-hook + - move-project + description: | + * `copy-project` - プロジェクトのコピー。[initiateProjectCopy](#operation/initiateProjectCopy) APIを実行したときに登録されるジョブ。 + * `gen-inputs` - zipファイルから入力データの作成。[putInputData](#operation/putInputData) APIを実行して、zipファイルから入力データを作成したときに登録されるジョブ。 + * `gen-tasks` - タスクの一括作成。[initiateTasksGeneration](#operation/initiateTasksGeneration) APIを実行したときに登録されるジョブ。 + * `gen-annotation` - アノテーションZIPの更新。[postAnnotationArchiveUpdate](#operation/postAnnotationArchiveUpdate) APIを実行したときに登録されるジョブ。 + * `gen-tasks-list` - タスク全件ファイルの更新。[postProjectTasksUpdate](#operation/postProjectTasksUpdate) APIを実行したときに登録されるジョブ。 + * `gen-inputs-list` - 入力データ情報全件ファイルの更新。[postProjectInputsUpdate](#operation/postProjectInputsUpdate) APIを実行したときに登録されるジョブ。 + * `delete-project` - プロジェクトの削除。[deleteProject](#operation/deleteProject) APIを実行したときに登録されるジョブ。 + * `invoke-hook` - Webhookの起動。 + * `move-project` - プロジェクトの組織移動。[putProject](#operation/putProject) API で組織を変更したときに登録されるジョブ。 + JobStatus: + type: string + enum: + - progress + - succeeded + - failed + PostAnnotationArchiveUpdateResponse: + type: object + properties: + job: + $ref: "#/components/schemas/JobInfo" + PostProjectTasksUpdateResponse: + type: object + properties: + job: + $ref: "#/components/schemas/JobInfo" + ProjectCopyResponse: + type: object + properties: + job: + $ref: "#/components/schemas/JobInfo" + dest_project: + $ref: "#/components/schemas/Project" + DeleteProjectResponse: + type: object + properties: + job: + $ref: "#/components/schemas/JobInfo" + project: + $ref: "#/components/schemas/Project" + PutProjectResponse: + type: object + properties: + job: + $ref: "#/components/schemas/JobInfo" + project: + $ref: "#/components/schemas/Project" + TaskGenerateResponse: + type: object + properties: + job: + $ref: "#/components/schemas/JobInfo" + project: + $ref: "#/components/schemas/Project" + ProjectInputsUpdateResponse: + type: object + properties: + job: + $ref: "#/components/schemas/JobInfo" + Webhook: + type: object + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + event_type: + $ref: "#/components/schemas/WebhookEventType" + webhook_id: + $ref: "#/components/schemas/WebhookId" + webhook_status: + $ref: "#/components/schemas/WebhookStatus" + method: + $ref: "#/components/schemas/WebhookHttpMethod" + headers: + type: array + items: + $ref: "#/components/schemas/WebhookHeader" + body: + type: string + example: '{\"message\": \"{{PROJECT_ID}} is updated at {{COMPLETE_DATETIME}}\"}' + url: + type: string + format: uri + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + WebhookHeader: + type: object + properties: + name: + type: string + value: + type: string + WebhookStatus: + type: string + enum: + - active + - inactive + WebhookHttpMethod: + type: string + enum: + - POST + - PUT + - DELETE + - PATCH + - GET + - HEAD + WebhookEventType: + type: string + enum: + - task-completed + - annotation-archive-updated + - input-data-zip-registered + - project-copy-completed + description: | + * `task-completed` - タスク受入完了 + * `annotation-archive-updated` - アノテーションZIP作成完了 + * `input-data-zip-registered` - 入力データZIP登録完了 + * `project-copy-completed` - プロジェクトコピー完了 + PutProjectRequest: + type: object + required: + - title + - status + - organization_name + - configuration + properties: + title: + type: string + description: プロジェクトのタイトル + overview: + type: string + description: プロジェクトの概要 + status: + $ref: "#/components/schemas/ProjectStatus" + input_data_type: + $ref: "#/components/schemas/InputDataType" + organization_name: + type: string + description: | + プロジェクトの所属組織を変更する場合は、ここに変更先の組織名を指定します。 + + * 所属組織を変更する前にプロジェクトを停止する必要があります。 + * APIを呼び出すアカウントは、変更先組織の管理者またはオーナーである必要があります。 + * 変更後の組織に所属していないプロジェクトメンバーも残りますが、作業はできません。あらためて組織に招待してください。 + configuration: + $ref: "#/components/schemas/ProjectConfiguration" + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + force_suspend: + type: boolean + description: 作業中タスクがあるプロジェクトを停止する時trueにして下さい + default: false + ProjectCopyRequest: + type: object + required: + - dest_project_id + - dest_title + properties: + dest_project_id: + $ref: "#/components/schemas/ProjectId" + dest_title: + type: string + description: コピー先プロジェクトのタイトル + dest_overview: + type: string + description: コピー先プロジェクトの概要 + copy_inputs: + type: boolean + description: | + 「入力データ」をコピーするかどうかを指定します。 + default: false + copy_tasks: + type: boolean + description: | + 「タスク」をコピーするかどうかを指定します。 + + この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 + + * copy_inputs の値を true とする + default: false + copy_annotations: + type: boolean + description: | + 「アノテーション」をコピーするかどうかを指定します。 + + この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 + + * copy_inputs の値を true とする + * copy_tasks の値を true とする + default: false + copy_webhooks: + type: boolean + description: | + 「Webhook」をコピーするかどうかを指定します。 + default: false + copy_supplementaly_data: + type: boolean + description: | + 「補助情報」をコピーするかどうかを指定します。 + + この属性の値を true とする場合、他の属性の値を必ず次のように指定してください。 + + * copy_inputs の値を true とする + default: false + copy_instructions: + type: boolean + description: | + 「作業ガイド」をコピーするかどうかを指定します。 + default: false + ProjectMember: + type: object + required: + - project_id + - account_id + - user_id + - username + - member_status + - member_role + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + account_id: + $ref: "#/components/schemas/AccountId" + user_id: + $ref: "#/components/schemas/UserId" + username: + type: string + member_status: + $ref: "#/components/schemas/ProjectMemberStatus" + member_role: + $ref: "#/components/schemas/ProjectMemberRole" + biography: + $ref: "#/components/schemas/UserBiography" + updated_datetime: + type: string + format: date-time + created_datetime: + type: string + format: date-time + sampling_inspection_rate: + description: メンバー固有の抜取検査率(0-100のパーセント値)。 + type: integer + sampling_acceptance_rate: + description: メンバー固有の抜取受入率(0-100のパーセント値)。 + type: integer + ProjectMemberStatus: + type: string + enum: + - active + - inactive + description: | + * `active` - プロジェクトメンバーとして有効で、プロジェクトを閲覧したり、権限があれば編集できます。 + * `inactive` - 脱退したプロジェクトメンバーを表します。プロジェクトを閲覧できません。 + ProjectMemberRole: + type: string + enum: + - owner + - worker + - accepter + - training_data_user + ProjectMemberRequest: + type: object + properties: + member_status: + $ref: "#/components/schemas/ProjectMemberStatus" + member_role: + $ref: "#/components/schemas/ProjectMemberRole" + sampling_inspection_rate: + description: メンバー固有の抜取検査率。0-100のパーセント値で指定する。値が指定された場合、プロジェクトの抜取検査率を指定の値で上書きする。 + type: integer + sampling_acceptance_rate: + description: メンバー固有の抜取受入率。0-100のパーセント値で指定する。値が指定された場合、プロジェクトの抜取受入率を指定の値で上書きする。 + type: integer + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + ProjectTaskStatisticsHistory: + type: object + properties: + date: + type: string + format: date + tasks: + type: array + items: + $ref: "#/components/schemas/ProjectTaskStatistics" + ProjectTaskStatistics: + type: object + required: + - phase + - status + - count + - work_timespan + properties: + phase: + $ref: "#/components/schemas/TaskPhase" + status: + $ref: "#/components/schemas/TaskStatus" + count: + type: integer + minimum: 0 + description: タスク数 + work_timespan: + type: integer + description: 累計実作業時間(ミリ秒) + ProjectAccountStatistics: + type: object + required: + - account_id + - histories + properties: + account_id: + $ref: "#/components/schemas/AccountId" + histories: + type: array + items: + $ref: "#/components/schemas/ProjectAccountStatisticsHistory" + ProjectAccountStatisticsHistory: + type: object + required: + - date + - tasks_completed + - tasks_rejected + - worktime + properties: + date: + type: string + format: date + tasks_completed: + type: integer + description: 教師付を担当したタスクが完了状態になった回数 + tasks_rejected: + type: integer + description: 教師付を担当したタスクが差し戻された回数 + worktime: + type: string + example: "PT34H17M36.789S" + description: 作業時間(ISO 8601 duration) + InspectionStatistics: + type: object + required: + - project_id + - date + - breakdown + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + date: + description: 集計日 + type: string + format: date + breakdown: + $ref: "#/components/schemas/InspectionStatisticsBreakdown" + InspectionStatisticsBreakdown: + type: object + description: 検査コメント数の集計結果 + required: + - labels + - no_label + properties: + labels: + description: ラベルごとの指摘集計結果。キーは`label_id` + type: object + additionalProperties: { + $ref: "#/components/schemas/InspectionStatisticsPhrases" + } + no_label: + $ref: "#/components/schemas/InspectionStatisticsPhrases" + InspectionStatisticsPhrases: + type: object + description: ラベル外指摘の集計結果 + required: + - phrases + - no_phrase + properties: + phrases: + description: 定型指摘ごとの合計数。キーは定型指摘ID、値は指摘数 + type: object + additionalProperties: { + type: integer + } + no_phrase: + description: 非定型指摘の合計数 + type: integer + TaskPhaseStatistics: + type: object + required: + - project_id + - date + - phases + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + date: + type: string + format: date + phases: + description: タスクのフェーズごとの集計結果 + type: array + items: + $ref: "#/components/schemas/PhaseStatistics" + PhaseStatistics: + type: object + required: + - phase + - worktime + properties: + phase: + $ref: "#/components/schemas/TaskPhase" + worktime: + description: 累積作業時間(ISO 8601 duration) + type: string + example: "PT34H17M36.789S" + LabelStatistics: + type: object + required: + - label_id + - completed + - wip + properties: + label_id: + $ref: "#/components/schemas/LabelId" + completed: + type: integer + minimum: 0 + description: ラベルごとの受入が完了したアノテーション数 + wip: + type: integer + minimum: 0 + description: ラベルごとの受入が完了していないアノテーション数 + WorktimeStatistics: + type: object + required: + - project_id + - date + - by_tasks + - by_inputs + - by_minutes + - accounts + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + date: + type: string + format: date + by_tasks: + type: array + description: タスク1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) + items: + $ref: "#/components/schemas/WorktimeStatisticsItem" + by_inputs: + type: array + description: 画像1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) + items: + $ref: "#/components/schemas/WorktimeStatisticsItem" + by_minutes: + type: array + description: 動画1分当たりの作業時間情報(画像プロジェクトの場合は空リスト) + items: + $ref: "#/components/schemas/WorktimeStatisticsItem" + accounts: + type: array + description: ユーザごとの作業時間情報 + items: + $ref: "#/components/schemas/AccountWorktimeStatistics" + WorktimeStatisticsItem: + type: object + required: + - phase + - histogram + - average + - standard_deviation + properties: + phase: + $ref: "#/components/schemas/TaskPhase" + histogram: + type: array + items: + $ref: "#/components/schemas/HistogramItem" + average: + description: 作業時間の平均(ISO 8601 duration) + type: string + example: "PT34H17M36.789S" + standard_deviation: + description: 作業時間の標準偏差(ISO 8601 duration) + type: string + example: "PT34H17M36.789S" + HistogramItem: + type: object + required: + - begin + - end + - count + properties: + begin: + type: number + end: + type: number + count: + type: integer + AccountWorktimeStatistics: + type: object + required: + - account_id + - by_tasks + - by_inputs + - by_minutes + properties: + account_id: + $ref: "#/components/schemas/AccountId" + by_tasks: + description: ユーザごとのタスク1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) + type: array + items: + $ref: "#/components/schemas/WorktimeStatisticsItem" + by_inputs: + description: ユーザごとの画像1個当たりの作業時間情報(動画プロジェクトの場合は空リスト) + type: array + items: + $ref: "#/components/schemas/WorktimeStatisticsItem" + by_minutes: + description: ユーザごとの動画1分当たりの作業時間情報(画像プロジェクトの場合は空リスト) + type: array + items: + $ref: "#/components/schemas/WorktimeStatisticsItem" + Marker: + type: object + properties: + marker_id: + $ref: "#/components/schemas/MarkerId" + title: + type: string + graph_type: + description: マーカーの配置先グラフ + $ref: "#/components/schemas/GraphType" + marked_at: + description: グラフ上のマーカー位置(x軸) + type: string + format: date + Markers: + type: object + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + markers: + type: array + items: + $ref: "#/components/schemas/Marker" + updated_datetime: + type: string + format: date + GraphType: + type: string + enum: + - task_progress + - cumulative_labor_time_By_task_phase + - number_of_inspections_per_inspection_phrase + - number_of_task_rejections_by_member + - labor_time_per_member + - mean_labor_time_per_image + - mean_labor_time_per_minute_of_movie + - mean_labor_time_per_image_by_member + - mean_labor_time_per_minute_of_movie_by_member + description: | + * `task_progress` - タスク進捗状況 + * `cumulative_labor_time_by_task_phase` - タスクフェーズ別累積作業時間 + * `number_of_inspections_per_inspection_phrase` - 検査コメント内容別指摘回数 + * `number_of_task_rejections_by_member` - メンバー別タスクが差戻された回数 + * `labor_time_per_member` - メンバー別作業時間 + * `mean_labor_time_per_image` - 画像一枚当たりの作業時間平均 + * `mean_labor_time_per_minute_of_movie` - 動画一分当たりの作業時間平均 + * `mean_labor_time_per_image_by_member` - メンバー別画像一枚当たりの作業時間平均 + * `mean_labor_time_per_minute_of_movie_by_member` - メンバー別動画一分当たりの作業時間平均 + PutMarkersRequest: + type: object + properties: + markers: + type: array + items: + $ref: "#/components/schemas/Marker" + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + AnnotationSpecsV1: + type: object + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + labels: + type: array + items: + $ref: "#/components/schemas/LabelV1" + inspection_phrases: + type: array + items: + $ref: "#/components/schemas/InspectionPhrase" + updated_datetime: + type: string + format: date-time + description: | + アノテーション仕様の最終更新時刻 + AnnotationSpecsV2: + type: object + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + labels: + type: array + items: + $ref: "#/components/schemas/LabelV2" + additionals: + type: array + items: + $ref: "#/components/schemas/AdditionalDataDefinitionV2" + restrictions: + type: array + items: + $ref: "#/components/schemas/AdditionalDataRestriction" + inspection_phrases: + type: array + items: + $ref: "#/components/schemas/InspectionPhrase" + format_version: + type: string + default: "2.1.0" + updated_datetime: + type: string + format: date-time + description: | + アノテーション仕様の最終更新時刻 + AnnotationSpecsRequestV1: + type: object + required: + - labels + - inspection_phrases + - comment + - auto_marking + properties: + labels: + type: array + items: + $ref: "#/components/schemas/LabelV1" + inspection_phrases: + type: array + items: + $ref: "#/components/schemas/InspectionPhrase" + comment: + type: string + auto_marking: + type: boolean + default: false + description: | + trueが指定された場合、各統計グラフにマーカーを自動追加します。 + マーカーのタイトルには `comment` に指定された文字列が設定されます。 + `comment` が指定されていなかった場合は "アノテーション仕様の変更" という文字列が設定されます。 + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + description: | + 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 + 新規作成時は未指定。 + AnnotationSpecsRequestV2: + type: object + required: + - labels + - additionals + - restrictions + - inspection_phrases + - comment + - auto_marking + - format_version + properties: + labels: + type: array + items: + $ref: "#/components/schemas/LabelV2" + additionals: + type: array + items: + $ref: "#/components/schemas/AdditionalDataDefinitionV2" + restrictions: + type: array + items: + $ref: "#/components/schemas/AdditionalDataRestriction" + inspection_phrases: + type: array + items: + $ref: "#/components/schemas/InspectionPhrase" + comment: + type: string + auto_marking: + type: boolean + default: false + description: | + trueが指定された場合、各統計グラフにマーカーを自動追加します。 + マーカーのタイトルには `comment` に指定された文字列が設定されます。 + `comment` が指定されていなかった場合は "アノテーション仕様の変更" という文字列が設定されます。 + format_version: + type: string + default: "2.1.0" + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + description: | + 更新前アノテーション仕様の時刻( `updated_datetime` )を指定する。 + 新規作成時は未指定。 + AnnotationSpecsHistory: + type: object + properties: + history_id: + type: string + project_id: + $ref: "#/components/schemas/ProjectId" + updated_datetime: + type: string + format: date-time + url: + type: string + account_id: + $ref: "#/components/schemas/AccountId" + comment: + type: string + InspectionPhrase: + type: object + properties: + id: + type: string + text: + $ref: "#/components/schemas/InternationalizationMessage" + AnnotationType: + type: string + enum: + - bounding_box + - segmentation + - segmentation_v2 + - polygon + - polyline + - point + - classification + - range + - custom + description: | + * `bounding_box` - 矩形を表します。 + * `segmentation` - ピクセルレベルでの塗りつぶし(ラスター)を表します。 + * `segmentation_v2` - 塗りつぶしv2を表します。v2はSemantic Segmentationに特化しています。 + * `polygon` - ポリゴン(閉じた頂点集合)を表します。 + * `polyline` - ポリライン(開いた頂点集合)を表します。 + * `point` - 点を表します。 + * `classification` - 入力データ全体に対するアノテーションを表します。 + * `range` - 動画の区間を表します。 + * `custom` - カスタム + AdditionalDataDefinitionType: + type: string + enum: + - flag + - integer + - text + - comment + - choice + - select + - tracking + - link + description: | + * `flag` - 真偽値 + * `integer` - 整数値 + * `text` - 自由記述(1行) + * `comment` - 自由記述(複数行) + * `choice` - 選択肢(ラジオボタン式) + * `select` - 選択肢(ドロップダウン式) + * `tracking` - 自由記述 (トラッキングID自動挿入) + * `link` - アノテーションリンク + PositionForMinimumBoundingBoxInsertion: + type: object + description: | + `annotation_type` が `bounding_box` かつ `min_warn_rule` が `and` または `or` の場合のみ、挿入する最小矩形アノテーションの原点を指定できます。 + 画像左上の座標が「x=0, y=0」です。 + 未指定、もしくは「画像外に飛び出たアノテーション」を許可していないにも関わらず飛び出してしまう場合は、表示範囲の中央に挿入されます。 + 「スキャンした帳票の記入欄」や「定点カメラで撮影した製品ラベル」など、アノテーションしたい位置やサイズが多くの画像で共通している場合に便利です。 + + `annotation_type` が `bounding_box` 以外の場合は必ず未指定となります。 + required: + - x + - y + properties: + x: + type: integer + y: + type: integer + LabelV1: + type: object + properties: + label_id: + $ref: "#/components/schemas/LabelId" + label_name: + $ref: "#/components/schemas/InternationalizationMessage" + keybind: + type: array + items: + $ref: "#/components/schemas/Keybind" + annotation_type: + $ref: "#/components/schemas/AnnotationType" + bounding_box_metadata: + type: object + properties: + min_width: + type: integer + min_height: + type: integer + min_warn_rule: + type: string + default: or + min_area: + type: integer + minimum: 1 + maximum: 1000000 + max_vertices: + type: integer + min_vertices: + type: integer + position_for_minimum_bounding_box_insertion: + $ref: "#/components/schemas/PositionForMinimumBoundingBoxInsertion" + tolerance: + type: integer + segmentation_metadata: + type: object + properties: + min_width: + type: integer + min_height: + type: integer + min_warn_rule: + type: string + default: or + tolerance: + type: integer + additional_data_definitions: + type: array + items: + $ref: "#/components/schemas/AdditionalDataDefinitionV1" + color: + $ref: "#/components/schemas/Color" + annotation_editor_feature: + $ref: "#/components/schemas/AnnotationEditorFeature" + allow_out_of_image_bounds: + type: boolean + default: false + LabelV2: + type: object + properties: + label_id: + $ref: "#/components/schemas/LabelId" + label_name: + $ref: "#/components/schemas/InternationalizationMessage" + keybind: + type: array + items: + $ref: "#/components/schemas/Keybind" + annotation_type: + $ref: "#/components/schemas/AnnotationType" + bounding_box_metadata: + type: object + properties: + min_width: + type: integer + min_height: + type: integer + min_warn_rule: + type: string + default: or + min_area: + type: integer + minimum: 1 + maximum: 1000000 + max_vertices: + type: integer + min_vertices: + type: integer + position_for_minimum_bounding_box_insertion: + $ref: "#/components/schemas/PositionForMinimumBoundingBoxInsertion" + tolerance: + type: integer + segmentation_metadata: + type: object + properties: + min_width: + type: integer + min_height: + type: integer + min_warn_rule: + type: string + default: or + tolerance: + type: integer + additional_data_definitions: + type: array + items: + $ref: "#/components/schemas/AdditionalDataDefinitionId" + color: + $ref: "#/components/schemas/Color" + annotation_editor_feature: + $ref: "#/components/schemas/AnnotationEditorFeature" + allow_out_of_image_bounds: + type: boolean + default: false + Color: + type: object + properties: + red: + type: integer + minimum: 0 + maximum: 255 + green: + type: integer + minimum: 0 + maximum: 255 + blue: + type: integer + minimum: 0 + maximum: 255 + AnnotationEditorFeature: + type: object + properties: + append: + type: boolean + erase: + type: boolean + freehand: + type: boolean + rectangle_fill: + type: boolean + polygon_fill: + type: boolean + fill_near: + type: boolean + AdditionalDataDefinitionV1: + type: object + properties: + additional_data_definition_id: + $ref: "#/components/schemas/AdditionalDataDefinitionId" + read_only: + type: boolean + default: false + name: + $ref: "#/components/schemas/InternationalizationMessage" + default: + $ref: "#/components/schemas/AdditionalDataDefaultType" + keybind: + type: array + items: + $ref: "#/components/schemas/Keybind" + type: + $ref: "#/components/schemas/AdditionalDataDefinitionType" + choices: + type: array + items: + type: object + properties: + choice_id: + $ref: "#/components/schemas/ChoiceId" + name: + $ref: "#/components/schemas/InternationalizationMessage" + keybind: + type: array + items: + $ref: "#/components/schemas/Keybind" + regex: + type: string + label_ids: + type: array + description: リンク属性において、リンク先として指定可能なラベルID(空の場合制限なし) + items: + type: string + required: + type: boolean + description: リンク属性において、入力を必須とするかどうか + AdditionalDataDefinitionV2: + type: object + properties: + additional_data_definition_id: + $ref: "#/components/schemas/AdditionalDataDefinitionId" + read_only: + type: boolean + default: false + name: + $ref: "#/components/schemas/InternationalizationMessage" + default: + $ref: "#/components/schemas/AdditionalDataDefaultType" + keybind: + type: array + items: + $ref: "#/components/schemas/Keybind" + type: + $ref: "#/components/schemas/AdditionalDataDefinitionType" + choices: + type: array + items: + type: object + properties: + choice_id: + $ref: "#/components/schemas/ChoiceId" + name: + $ref: "#/components/schemas/InternationalizationMessage" + keybind: + type: array + items: + $ref: "#/components/schemas/Keybind" + AdditionalDataRestriction: + type: object + properties: + additional_data_definition_id: + $ref: "#/components/schemas/AdditionalDataDefinitionId" + condition: + $ref: "#/components/schemas/AdditionalDataRestrictionCondition" + AdditionalDataRestrictionCondition: + oneOf: + - $ref: "#/components/schemas/AdditionalDataRestrictionConditionCanInput" + - $ref: "#/components/schemas/AdditionalDataRestrictionConditionEquals" + - $ref: "#/components/schemas/AdditionalDataRestrictionConditionNotEquals" + - $ref: "#/components/schemas/AdditionalDataRestrictionConditionMatches" + - $ref: "#/components/schemas/AdditionalDataRestrictionConditionNotMatches" + - $ref: "#/components/schemas/AdditionalDataRestrictionConditionHasLabel" + - $ref: "#/components/schemas/AdditionalDataRestrictionConditionImply" + discriminator: + propertyName: "_type" + mapping: + CanInput: "#/components/schemas/AdditionalDataRestrictionConditionCanInput" + Equals: "#/components/schemas/AdditionalDataRestrictionConditionEquals" + NotEquals: "#/components/schemas/AdditionalDataRestrictionConditionNotEquals" + Matches: "#/components/schemas/AdditionalDataRestrictionConditionMatches" + NotMatches: "#/components/schemas/AdditionalDataRestrictionConditionNotMatches" + HasLabel: "#/components/schemas/AdditionalDataRestrictionConditionHasLabel" + Imply: "#/components/schemas/AdditionalDataRestrictionConditionImply" + AdditionalDataRestrictionConditionCanInput: + type: object + description: | + enable=false とすることで、入力を許可しないようにできます。 + Imply との組み合わせで、特定条件下のみ入力を許すといった制限ができます。 + properties: + _type: + type: string + example: "CanInput" + enable: + type: boolean + AdditionalDataRestrictionConditionEquals: + type: object + description: 指定された値と等しいことを要求します。 + properties: + _type: + type: string + example: "Equals" + value: + type: string + AdditionalDataRestrictionConditionNotEquals: + type: object + description: | + 指定された値と異なることを要求します。 + value に "" を指定することで、入力を必須とすることができます。 + properties: + _type: + type: string + example: "NotEquals" + value: + type: string + AdditionalDataRestrictionConditionMatches: + type: object + description: 指定された正規表現に合致することを要求します。 + properties: + _type: + type: string + example: "Matches" + value: + type: string + AdditionalDataRestrictionConditionNotMatches: + type: object + description: 指定された正規表現に合致しないことを要求します。 + properties: + _type: + type: string + example: "NotMatches" + value: + type: string + AdditionalDataRestrictionConditionHasLabel: + type: object + description: リンク属性において、リンク先として指定可能なラベルIDを制限します。 + properties: + _type: + type: string + example: "HasLabel" + values: + type: string + AdditionalDataRestrictionConditionImply: + type: object + description: | + premise で指定された条件を満たすとき、condition で指定された条件を満たすことを要求します。 + properties: + _type: + type: string + example: "Imply" + premise: + $ref: "#/components/schemas/AdditionalDataRestriction" + condition: + $ref: "#/components/schemas/AdditionalDataRestrictionCondition" + Keybind: + type: object + properties: + code: + type: string + shift: + type: boolean + ctrl: + type: boolean + alt: + type: boolean + Task: + type: object + required: + - project_id + - task_id + - phase + - phase_stage + - status + - input_data_id_list + - work_time_span + - updated_datetime + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + phase: + $ref: "#/components/schemas/TaskPhase" + phase_stage: + $ref: "#/components/schemas/TaskPhaseStage" + status: + $ref: "#/components/schemas/TaskStatus" + input_data_id_list: + type: array + description: タスクに含まれる入力データのID + items: + $ref: "#/components/schemas/InputDataId" + account_id: + $ref: "#/components/schemas/AccountId" + histories_by_phase: + type: array + description: 簡易的なタスク履歴(あるフェーズを誰が担当したか) + items: + $ref: "#/components/schemas/TaskHistoryShort" + work_time_span: + type: integer + description: 累計実作業時間(ミリ秒) + number_of_rejections: + type: integer + deprecated: true + description: | + このタスクが差戻しされた回数(すべてのフェーズでの差戻し回数の合計 + + このフィールドは、どのフェーズで何回差戻されたかを区別できないため、廃止予定です。 + `histories_by_phase` で各フェーズの回数を計算することで、差戻し回数が分かります。 + + 例)`acceptance`フェーズが3回ある場合、`acceptance`フェーズで2回差し戻しされたことになります。 + started_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + sampling: + type: string + enum: + - inspection_skipped + - inspection_stages_skipped + - acceptance_skipped + - inspection_and_acceptance_skipped + description: | + * `inspection_skipped` - このタスクが抜取検査の対象外となり、検査フェーズをスキップしたことを表す。 + * `inspection_stages_skipped` - このタスクが抜取検査の対象外となり、検査フェーズのステージを一部スキップしたことを表す。 + * `acceptance_skipped` - このタスクが抜取検査の対象外となり、受入フェーズをスキップしたことを表す。 + * `inspection_and_acceptance_skipped` - このタスクが抜取検査の対象外となり、検査・受入フェーズをスキップしたことを表す + + 未指定時はこのタスクが抜取検査の対象となったことを表す。(通常のワークフローを通過する) + TaskPhase: + type: string + enum: + - annotation + - inspection + - acceptance + description: | + * `annotation` - 教師付け。 + * `inspection` - 中間検査。ワークフローが3フェーズのときのみ。 + * `acceptance` - 受入。 + TaskPhaseStage: + type: integer + minimum: 1 + TaskStatus: + type: string + enum: + - not_started + - working + - on_hold + - break + - complete + - rejected + - cancelled + description: | + * `not_started` - 未着手。 + * `working` - 作業中。誰かが実際にエディタ上で作業している状態。 + * `on_hold` - 保留。作業ルールの確認などで作業できない状態。 + * `break` - 休憩中。 + * `complete` - 完了。次のフェーズへ進む + * `rejected` - 差戻し。修正のため、`annotation`フェーズへ戻る。[operateTask](#operation/operateTask) APIのリクエストボディに渡すときのみ利用する。その他のAPIのリクエストやレスポンスには使われない。 + * `cancelled` - 提出取消し。修正のため、前フェーズへ戻る。[operateTask](#operation/operateTask) APIのリクエストボディに渡すときのみ利用する。その他のAPIのリクエストやレスポンスには使われない。 + TaskRequest: + type: object + required: + - input_data_id_list + properties: + input_data_id_list: + type: array + items: + $ref: "#/components/schemas/InputDataId" + TaskGenerateRequest: + type: object + required: + - task_generate_rule + - project_last_updated_datetime + properties: + task_generate_rule: + $ref: "#/components/schemas/TaskGenerateRule" + project_last_updated_datetime: + type: string + format: date-time + description: プロジェクトの最終更新日時([getProject](#operation/getProject) APIのレスポンス `updated_datetime`)。タスク生成の排他制御に使用。 + TaskGenerateRule: + description: | + * `TaskGenerateRuleByCount`: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 + * `TaskGenerateRuleByDirectory`: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。 + * `TaskGenerateRuleByInputDataCsv`: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 + oneOf: + - $ref: "#/components/schemas/TaskGenerateRuleByCount" + - $ref: "#/components/schemas/TaskGenerateRuleByDirectory" + - $ref: "#/components/schemas/TaskGenerateRuleByInputDataCsv" + discriminator: + propertyName: "_type" + mapping: + ByCount: "#/components/schemas/TaskGenerateRuleByCount" + ByDirectory: "#/components/schemas/TaskGenerateRuleByDirectory" + ByInputDataCsv: "#/components/schemas/TaskGenerateRuleByInputDataCsv" + TaskGenerateRuleByCount: + description: 1つのタスクに割りあてる入力データの個数を指定してタスクを生成します。 + type: object + required: + - task_id_prefix + - allow_duplicate_input_data + - input_data_count + - input_data_order + properties: + task_id_prefix: + type: string + description: | + 生成するタスクIDのプレフィックス。[値の制約についてはこちら。](#section/API-Convention/APIID) + allow_duplicate_input_data: + type: boolean + description: falseのときは、既にタスクに使われている入力データを除外し、まだタスクに使われていない入力データだけを新しいタスクに割り当てます。trueのときは、既にタスクに使われている入力データを除外しません。 + input_data_count: + type: integer + description: 1つのタスクに割り当てる入力データの個数 + example: 10 + input_data_order: + $ref: "#/components/schemas/InputDataOrder" + _type: + type: string + description: | + `ByCount` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "ByCount" + TaskGenerateRuleByDirectory: + description: 入力データ名をファイルパスに見立て、ディレクトリ単位でタスクを生成します。
+ type: object + required: + - task_id_prefix + properties: + task_id_prefix: + type: string + description: | + 生成するタスクIDのプレフィックス。[値の制約についてはこちら。](#section/API-Convention/APIID) + input_data_name_prefix: + type: string + description: タスク生成対象の入力データ名プレフィックス + _type: + type: string + description: | + `ByDirectory` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "ByDirectory" + TaskGenerateRuleByInputDataCsv: + description: 各タスクへの入力データへの割当を記入したCSVへのS3上のパスを指定してタスクを生成します。 + type: object + required: + - csv_data_path + properties: + csv_data_path: + type: string + description: 各タスクへの入力データへの割当を記入したCSVへのS3上のパス + example: "s3://ANNOFAB-BUCKET/PATH/TO/CSV" + _type: + type: string + description: | + `ByInputDataCsv` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "ByInputDataCsv" + InputDataOrder: + type: string + enum: + - name_asc + - name_desc + - random + description: | + タスクに割り当てる入力データの順序 + + * `name_asc` - 入力データ名 昇順(a, b, c, ...)。日付や番号などの連続するデータ名を扱う場合に推奨 + * `name_desc` - 入力データ名 降順(z, y, x, ...) + * `random` - ランダム + TaskOperation: + type: object + required: + - status + - last_updated_datetime + properties: + status: + $ref: "#/components/schemas/TaskStatus" + description: | + 次に遷移させるタスクの状態。[詳細はこちら](#section/TaskStatus)。 + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + description: | + タスクの最終更新日時 + account_id: + $ref: "#/components/schemas/AccountId" + description: 変更後の担当者のアカウントID。担当者を未割り当てにする場合は未指定。 + force: + type: boolean + default: false + description: | + タスクの強制操作を行う場合に立てるフラグ。現在、強制操作は強制差戻しのみがサポートされています。 + TaskStart: + type: object + properties: + phase: + $ref: "#/components/schemas/TaskPhase" + description: 開始するタスクのフェーズ + TaskAssignRequest: + type: object + required: + - request_type + properties: + request_type: + $ref: "#/components/schemas/TaskAssignRequestType" + TaskAssignRequestType: + description: | + * `TaskAssignRequestTypeRandom`: タスクフェーズのみを指定してランダムにタスクを自身に割当します。プロジェクト設定でタスクのランダム割当を有効にした場合のみ利用できます。 + * `TaskAssignRequestTypeSelection`: 担当者とタスクを明示的に指定してタスクを割当します。プロジェクトオーナーもしくはチェッカーのみ、自身以外のプロジェクトメンバーを担当者に指定できます。プロジェクト設定でタスクの選択割当を有効にした場合のみ利用できます。 + oneOf: + - $ref: "#/components/schemas/TaskAssignRequestTypeRandom" + - $ref: "#/components/schemas/TaskAssignRequestTypeSelection" + discriminator: + propertyName: "_type" + mapping: + Random: "#/components/schemas/TaskAssignRequestTypeRandom" + Selection: "#/components/schemas/TaskAssignRequestTypeSelection" + TaskAssignRequestTypeRandom: + type: object + required: + - phase + properties: + phase: + $ref: "#/components/schemas/TaskPhase" + description: 割当するタスクフェーズ。[詳細はこちら](#section/TaskPhase) + _type: + type: string + description: Random + example: "Random" + TaskAssignRequestTypeSelection: + type: object + required: + - user_id + - task_ids + properties: + user_id: + $ref: "#/components/schemas/UserId" + description: タスクを誰に割当するか + task_ids: + description: 割当するタスクのID + type: array + items: + $ref: "#/components/schemas/TaskId" + _type: + type: string + description: Selection + example: "Selection" + TaskHistoryShort: + description: タスクのあるフェーズを誰が担当したかを表します。 + type: object + required: + - phase + - phase_stage + - account_id + properties: + phase: + $ref: "#/components/schemas/TaskPhase" + phase_stage: + type: integer + default: 1 + minimum: 1 + account_id: + $ref: "#/components/schemas/AccountId" + worked: + type: boolean + description: そのフェーズでタスクの作業を行ったかどうか(行った場合はtrue) + default: false + TaskHistory: + description: タスクのあるフェーズで、誰がいつどれくらいの作業時間を費やしたかを表すタスク履歴です。 + type: object + required: + - project_id + - task_id + - task_history_id + - accumulated_labor_time_milliseconds + - phase + - phase_stage + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + task_history_id: + $ref: "#/components/schemas/TaskHistoryId" + started_datetime: + type: string + format: date-time + ended_datetime: + type: string + format: date-time + accumulated_labor_time_milliseconds: + type: string + description: 累計実作業時間(ISO 8601 duration) + example: "PT34H17M36.789S" + phase: + $ref: "#/components/schemas/TaskPhase" + phase_stage: + type: integer + minimum: 1 + account_id: + $ref: "#/components/schemas/AccountId" + TaskHistoryEvent: + description: タスク履歴イベントは、タスクの状態が変化した1時点を表します。作業時間は、複数のこれらイベントを集約して計算するものなので、このオブジェクトには含まれません。 + type: object + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + task_history_id: + $ref: "#/components/schemas/TaskHistoryId" + created_datetime: + type: string + format: date-time + phase: + $ref: "#/components/schemas/TaskPhase" + phase_stage: + type: integer + default: 1 + minimum: 1 + status: + $ref: "#/components/schemas/TaskStatus" + account_id: + $ref: "#/components/schemas/AccountId" + request: + $ref: "#/components/schemas/TaskOperation" + TaskValidation: + description: タスクの全入力データに対するバリデーション結果です。 + type: object + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + inputs: + type: array + items: + $ref: "#/components/schemas/InputDataSummary" + InputDataSummary: + description: ある入力データのバリデーション結果です。入力データIDをキーに引けるようにMap[入力データID, バリデーション結果]となっています + type: object + properties: + input_data_id: + $ref: "#/components/schemas/InputDataId" + inspection_summary: + $ref: "#/components/schemas/InspectionSummary" + annotation_summaries: + type: array + items: + $ref: "#/components/schemas/ValidationError" + InspectionSummary: + type: string + enum: + - no_inspection + - no_comment_inspection + - new_reply_to_unprocessed + - new_unprocessed_inspection + - unprocessed + - complete + description: | + - `no_inspection` - 入力データに検査コメントが付けられていない。 + - `no_comment_inspection` - 入力データに空の検査コメントが付けられている。 + - `new_reply_to_unprocessed` - 現在進行中の検査・受入フェーズで未処理の検査コメントに対して新たに返信が付けられている。 + - `new_unprocessed_inspection` - 現在進行中の検査・受入フェーズでつけられた検査コメントのうち、未処理のものが1つ以上ある。 + - `unprocessed` - 過去の検査・受入フェーズでつけられた検査コメントのうち、未処理のものが1つ以上ある。 + - `complete` - 入力データにつけられた検査コメントで未処理のものがない。 + InputData: + description: 入力データの情報を表すデータ構造です。 + type: object + required: + - input_data_id + - project_id + - input_data_name + - input_data_path + - updated_datetime + properties: + input_data_id: + $ref: "#/components/schemas/InputDataId" + project_id: + $ref: "#/components/schemas/ProjectId" + input_data_name: + type: string + description: 表示用の名前です。 + input_data_path: + type: string + example: "s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA" + description: | + 入力データの実体が保存されたパスです。 + s3スキーマまたはhttpsスキーマのみサポートしています。 + url: + type: string + description: | + 入力データを取得するためのhttpsスキーマのURLです。 + + このURLはセキュリティのために認証認可が必要となっており、URLだけでは入力データを参照できません。 + このURLは内部用であり、常に変更になる可能性があります。そのため、アクセスは保証外となります。 + また、このURLのレスポンスは最低1時間キャッシュされます。 + キャッシュを無効にしたい場合は、クエリパラメータにアクセス毎にランダムなUUIDなどを付与してください。 + + 設定の不備等でデータが取得できない場合、この属性は設定されません。 + etag: + type: string + original_input_data_path: + type: string + example: "s3://YOUR-BUCKET/PATH/TO/INPUT_DATA" + description: | + AF外部のストレージから登録された場合、その外部ストレージ中のパス。 + それ以外の場合は値なし + original_resolution: + deprecated: true + $ref: "#/components/schemas/Resolution" + description: | + 入力データの元画像サイズ。 + 入力データ登録時に画像がリサイズされた場合のみ設定される。 + resized_resolution: + deprecated: true + $ref: "#/components/schemas/Resolution" + description: | + 入力データのリサイズ後サイズ。 + 入力データ登録時に画像がリサイズされた場合のみ設定される。 + input_duration: + deprecated: true + type: number + description: | + 入力データが動画の場合、動画の長さ(秒)。小数点以下はミリ秒以下を表します。 + + 動画の長さが取得できなかった場合、あるいは入力データが画像の場合は値なし。 + updated_datetime: + type: string + format: date-time + sign_required: + type: boolean + description: | + データがSigned Cookieによるクロスオリジン配信に対応しているか否かです。 + metadata: + type: object + description: | + ユーザーが自由に登録できるkey-value型のメタデータです。主にカスタムエディタで使われることを想定しています。 + additionalProperties: + type: string + system_metadata: + $ref: "#/components/schemas/SystemMetadata" + SystemMetadata: + oneOf: + - $ref: "#/components/schemas/SystemMetadataImage" + - $ref: "#/components/schemas/SystemMetadataMovie" + - $ref: "#/components/schemas/SystemMetadataCustom" + discriminator: + propertyName: "_type" + mapping: + Image: "#/components/schemas/SystemMetadataImage" + Movie: "#/components/schemas/SystemMetadataMovie" + Custom: "#/components/schemas/SystemMetadataCustom" + description: | + * `SystemMetadataImage`: 画像プロジェクトの場合。画像データ固有のメタデータが保存されます。 + * `SystemMetadataMovie`: 動画プロジェクトの場合。動画データ固有のメタデータが保存されます。 + * `SystemMetadataCustom`: カスタムプロジェクトの場合。カスタムデータ固有のメタデータが保存されます。 + + `metadata` プロパティとは違い、ユーザー側では値を編集できない読取専用のプロパティです。 + SystemMetadataImage: + type: object + required: + - _type + description: | + 画像データ用システムメタデータ。 + properties: + original_resolution: + $ref: "#/components/schemas/Resolution" + description: | + 入力データの元画像サイズ。 + 入力データ登録時に画像がリサイズされた場合のみ設定される。 + resized_resolution: + $ref: "#/components/schemas/Resolution" + description: | + 入力データのリサイズ後サイズ。 + 入力データ登録時に画像がリサイズされた場合のみ設定される。 + _type: + type: string + description: "`Image`" + example: Image + SystemMetadataMovie: + type: object + required: + - _type + description: | + 動画データ用システムメタデータ。 + properties: + input_duration: + type: number + description: | + 入力データが動画の場合、動画の長さ(秒)。小数点以下はミリ秒以下を表します。 + 動画の長さが取得できなかった場合は値なし。 + _type: + type: string + description: "`Movie`" + example: Movie + SystemMetadataCustom: + type: object + required: + - _type + description: | + カスタムデータ用システムメタデータ。 + 現行はプロパティがない形式的なオブジェクトです。 + properties: + _type: + type: string + description: "`Custom`" + example: Custom + InputDataRequest: + type: object + required: + - input_data_name + - input_data_path + properties: + input_data_name: + type: string + description: 表示用の名前 + input_data_path: + type: string + example: "s3://YOUR-BUCKET/PATH/TO/OBJECT" + description: | + AnnoFabに登録する入力データの実体が保存されたパスです。 + + 対応スキーマ: + * s3 + * https + + 場面別の使い分け: + * [一時データ保存先取得API](#operation/createTempPath)を使ってAFにアップロードした場合: `s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA` + * [プライベートストレージ](/docs/faq/#prst9c)の場合 + * `https://YOUR-DOMAIN/PATH/TO/INPUT_DATA` + * `s3://YOUR-BUCKET-FOR-PRIVATE-STORAGE/PATH/TO/INPUT_DATA` + * S3プライベートストレージのパスを登録する場合、[事前に認可の設定が必要](/docs/faq/#m0b240)です。 + last_updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + sign_required: + type: boolean + description: | + データがSigned Cookieによるクロスオリジン配信に対応しているか否かです。
+ このオプションを有効にする場合は、`input_data_path`として、AnnoFabのAWS IDをTrusted Signerとして登録したCloudFrontのURLを指定してください。 + metadata: + type: object + description: | + ユーザーが自由に登録できるkey-value型のメタデータです。主にカスタムエディタで使われることを想定しています。 + additionalProperties: + type: string + SupplementaryData: + type: object + required: + - project_id + - input_data_id + - supplementary_data_id + - supplementary_data_name + - supplementary_data_path + - supplementary_data_type + - supplementary_data_number + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + input_data_id: + $ref: "#/components/schemas/InputDataId" + supplementary_data_id: + $ref: "#/components/schemas/SupplementaryDataId" + supplementary_data_name: + type: string + description: 表示用の名前 + supplementary_data_path: + type: string + example: "s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA" + description: | + 補助情報の実体が保存されたパスです。 + s3スキーマまたはhttpsスキーマのみサポートしています。 + url: + type: string + format: uri + deprecated: true + description: このフィールドはAF内部での利用のみを想定しており、依存しないでください。 + etag: + type: string + supplementary_data_type: + $ref: "#/components/schemas/SupplementaryDataType" + supplementary_data_number: + type: integer + description: 表示順を表す数値(昇順)。同じ入力データに対して複数の補助情報で表示順が重複する場合、順序不定になります。 + updated_datetime: + type: string + format: date-time + SupplementaryDataType: + type: string + enum: + - image + - text + - custom + SupplementaryDataRequest: + type: object + required: + - supplementary_data_name + - supplementary_data_path + - supplementary_data_type + - supplementary_data_number + properties: + supplementary_data_name: + type: string + description: 表示用の名前 + supplementary_data_path: + type: string + example: "s3://YOUR-BUCKET/PATH/TO/OBJECT" + description: | + AnnoFabに登録する補助情報の実体が保存されたパスです。 + + 対応スキーマ:s3, https + + * [一時データ保存先取得API](#operation/createTempPath)を使ってAFにアップロードしたファイルパスの場合 + * `s3://ANNOFAB-BUCKET/PATH/TO/INPUT_DATA` + * 補助情報作成/更新API成功時、アップロードしたファイルが一時データ保存先からコピーされます。 + * APIのレスポンスからアップロードしたファイルのコピー先パス(s3スキーマ)を取得できます。 + * すでにAFに登録されている補助情報のパスの場合 + * `s3://ANNOFAB-SUPPLEMENTARY-BUCKET/PATH/TO/INPUT_DATA` + * ファイルはコピーされません。 + * [プライベートストレージ](/docs/faq/#prst9c)のパスの場合 + * `https://YOUR-DOMAIN/PATH/TO/INPUT_DATA` + * `s3://YOUR-BUCKET-FOR-PRIVATE-STORAGE/PATH/TO/INPUT_DATA` + * S3プライベートストレージのパスを登録する場合、[事前に認可の設定が必要](/docs/faq/#m0b240)です。 + * AFにファイルはコピーされません。 + supplementary_data_type: + $ref: "#/components/schemas/SupplementaryDataType" + + supplementary_data_number: + type: integer + description: 表示順を表す数値(昇順)。同じ入力データに対して複数の補助情報で表示順が重複する場合、順序不定になります。 + last_updated_datetime: + type: string + format: date-time + WebhookTestRequest: + type: object + properties: + placeholders: + description: プレースホルダ名と置換する値 + type: object + example: + SOME_PLACEHOLDER: value + SOME_NAME: value2 + WebhookTestResponse: + type: object + properties: + result: + description: | + * success: 通知先から正常なレスポンス(2xx系)を受け取った + * failure: 通知先からエラーレスポンス(2xx系以外)を受け取った + * error: リクエスト送信に失敗した、もしくはレスポンスを受信できなかった + type: string + enum: [success, failure, error] + example: success + request_body: + description: 実際に送信されたリクエストボディ + type: string + response_status: + description: 通知先から返されたHTTPステータスコード + type: integer + example: 200 + response_body: + description: 通知先から返されたレスポンスボディ + type: string + message: + description: result="error" 時のエラー内容等 + type: string + BatchInputDataRequestItemDelete: + type: object + description: 入力データ削除 + required: + - project_id + - input_data_id + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + input_data_id: + $ref: "#/components/schemas/InputDataId" + _type: + type: string + description: | + `Delete` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Delete" + BatchTaskRequestItemDelete: + type: object + description: タスク削除 + required: + - project_id + - task_id + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + _type: + type: string + description: | + `Delete` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Delete" + DataPath: + type: object + properties: + url: + type: string + format: uri + example: "https://s3..amazonaws.com///?param1=...¶m2=..." + description: ファイルアップロード用の一時URLです。このURLにファイルをアップロードします。 + path: + type: string + example: s3://// + description: アップロードしたファイルをAFの [入力データ](#tag/af-input) や [補助情報](#tag/af-supplementary) に登録するとき、この`path`を指定します。 + InstructionImagePath: + type: object + required: + - url + - path + properties: + url: + type: string + format: uri + example: "https://s3..amazonaws.com///?param1=...¶m2=..." + description: ファイルアップロード用の一時URLです。このURLにファイルをアップロードします。 + path: + type: string + format: url + example: https://annofab.com/projects/{project_id}/instruction-images/{image_id} + description: 作業ガイド画像のURL + AnnotationQuery: + type: object + properties: + task_id: + $ref: "#/components/schemas/TaskId" + exact_match_task_id: + description: | + タスクIDの検索方法を指定します。 + trueの場合は完全一致検索、falseの場合は中間一致検索です。 + type: boolean + default: true + input_data_id: + $ref: "#/components/schemas/InputDataId" + exact_match_input_data_id: + description: | + 入力データIDの検索方法を指定します。 + trueの場合は完全一致検索、falseの場合は中間一致検索です。 + type: boolean + default: true + label_id: + $ref: "#/components/schemas/LabelId" + attributes: + type: array + items: + $ref: "#/components/schemas/AdditionalData" + updated_from: + description: | + 開始日・終了日を含む区間[updated_from, updated_to]でアノテーションの更新日を絞り込むときに使用する、開始日。updated_toより後ろに指定された場合、期間指定は開始日・終了日を含む区間[updated_to, updated_from]となる。未指定の場合、本日であるとして扱われる。 + type: string + example: "20191010" + updated_to: + description: | + 開始日・終了日を含む区間[updated_from, updated_to]でアノテーションの更新日を絞り込むときに使用する、終了日。未指定の場合、本日であるとして扱われる。 + type: string + example: "20191010" + Annotation: + type: object + required: + - project_id + - task_id + - input_data_id + - details + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + input_data_id: + $ref: "#/components/schemas/InputDataId" + details: + type: array + description: 矩形、ポリゴン、全体アノテーションなど個々のアノテーションの配列。 + items: + $ref: "#/components/schemas/AnnotationDetail" + updated_datetime: + $ref: "#/components/schemas/LastUpdatedDatetime" + AnnotationDataHoldingType: + type: string + enum: + - inner + - outer + description: | + * `inner` - アノテーションのデータ部をJSON内部に保持します。 + * `outer` - アノテーションのデータ部を外部ファイルの形式(画像など)で保持します + AnnotationDetail: + type: object + required: + - annotation_id + - account_id + - label_id + - is_protected + - data_holding_type + - additional_data_list + properties: + annotation_id: + $ref: "#/components/schemas/AnnotationId" + account_id: + $ref: "#/components/schemas/AccountId" + description: アノテーションを作成したユーザのアカウントID。 + label_id: + $ref: "#/components/schemas/LabelId" + description: ラベルID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 + is_protected: + description: | + `true`の場合、アノテーションをアノテーションエディタ上での削除から保護できます。 + 外部から取り込んだアノテーションに属性を追加するときなどに指定すると、データの削除を防げます。 + type: boolean + default: false + data_holding_type: + $ref: "#/components/schemas/AnnotationDataHoldingType" + data: + $ref: "#/components/schemas/AnnotationData" + path: + type: string + description: | + 外部ファイルに保存されたアノテーションのパス。`data_holding_type`が`inner`の場合は未指定です。 + レスポンスの場合は`annotation_id`と同じ値が格納されます。 + + [putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は、[createTempPath](#operation/createTempPath) APIで取得できる一時データ保存先S3パスを格納してください。 + 更新しない場合は、[getEditorAnnotation](#operation/getEditorAnnotation) APIで取得した`path`をそのまま渡せます。 + + 外部ファイルのフォーマットは下表の通りです。 + + + + +
annotation_type形式
segmentation / segmentation_v2 PNG画像。塗りつぶした部分はrgba(255, 255, 255, 1) 、塗りつぶしていない部分はrgba(0, 0, 0, 0)
+ etag: + type: string + description: 外部ファイルに保存されたアノテーションのETag。`data_holding_type`が`inner`の場合、または[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は未指定です。 + url: + type: string + format: uri + description: 外部ファイルに保存されたアノテーションの認証済み一時URL。`data_holding_type`が`inner`の場合、または[putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は未指定です。 + additional_data_list: + type: array + description: | + 各要素は、 [アノテーション仕様](#operation/getAnnotationSpecs)で定義された属性(`additional_data_definitions`内)のいずれかの要素と対応づけます。 + 各要素は、どの属性なのかを表す`additional_data_definition_id`と値が必要です。値は、属性の種類に対応するキーに格納します(下表)。 + + + + + + + + +
アノテーション属性の種類
additional_data_definitiontype
属性の値を格納するキーデータ型
text, comment または trackingcommentstring
flagflagboolean
integerintegerinteger
choice または selectchoicestring(選択肢ID)
linkcommentstring(アノテーションID)
+ items: + $ref: "#/components/schemas/AdditionalData" + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + AdditionalData: + type: object + required: + - additional_data_definition_id + properties: + additional_data_definition_id: + $ref: "#/components/schemas/AdditionalDataDefinitionId" + description: 属性ID。[アノテーション仕様](#tag/af-annotation-specs)で定義されます。 + flag: + type: boolean + description: | + `additional_data_definition`の`type`が`flag`のときの属性値。 + integer: + type: integer + description: | + `additional_data_definition`の`type`が`integer`のときの属性値。 + comment: + type: string + description: | + `additional_data_definition`の`type`が`text`,`comment`,`link` または `tracking`のときの属性値。 + choice: + $ref: "#/components/schemas/ChoiceId" + description: | + `additional_data_definition`の`type`が`choice` または `select `のときの属性値(選択肢ID)。 + AdditionalDataValue: + oneOf: + - $ref: "#/components/schemas/AdditionalDataValueFlag" + - $ref: "#/components/schemas/AdditionalDataValueInteger" + - $ref: "#/components/schemas/AdditionalDataValueComment" + - $ref: "#/components/schemas/AdditionalDataValueChoice" + - $ref: "#/components/schemas/AdditionalDataValueTracking" + - $ref: "#/components/schemas/AdditionalDataValueLink" + discriminator: + propertyName: "_type" + mapping: + Flag: "#/components/schemas/AdditionalDataValueFlag" + Integer: "#/components/schemas/AdditionalDataValueInteger" + Comment: "#/components/schemas/AdditionalDataValueComment" + Choice: "#/components/schemas/AdditionalDataValueChoice" + Tracking: "#/components/schemas/AdditionalDataValueTracking" + Link: "#/components/schemas/AdditionalDataValueLink" + AdditionalDataValueFlag: + type: object + required: + - _type + - value + properties: + _type: + type: string + description: Flag + example: "Flag" + value: + type: boolean + description: フラグのON(true)またはOFF(false) + AdditionalDataValueInteger: + type: object + required: + - _type + properties: + _type: + type: string + description: Integer + example: "Integer" + value: + type: integer + description: 整数値 + AdditionalDataValueComment: + type: object + required: + - _type + properties: + _type: + type: string + description: Comment + example: "Comment" + value: + type: string + description: 自由記述 + AdditionalDataValueChoice: + type: object + required: + - _type + properties: + _type: + type: string + description: Choice + example: "Choice" + value: + $ref: "#/components/schemas/AdditionalDataChoiceValue" + AdditionalDataChoiceValue: + type: object + required: + - id + - name + properties: + id: + $ref: "#/components/schemas/ChoiceId" + description: 選択された選択肢のID + name: + $ref: "#/components/schemas/InternationalizationMessage" + description: 選択された選択肢の表示名 + AdditionalDataValueTracking: + type: object + required: + - _type + properties: + _type: + type: string + description: Tracking + example: "Tracking" + value: + type: string + description: トラッキングID + AdditionalDataValueLink: + type: object + required: + - _type + properties: + _type: + type: string + description: Link + example: "Link" + value: + type: string + description: リンク先アノテーションID + SingleAnnotation: + type: object + required: + - project_id + - task_id + - input_data_id + - detail + - updated_datetime + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + input_data_id: + $ref: "#/components/schemas/InputDataId" + detail: + $ref: "#/components/schemas/SingleAnnotationDetail" + updated_datetime: + type: string + format: date-time + SimpleAnnotation: + type: object + required: + - annotation_format_version + - project_id + - task_id + - task_phase + - task_phase_stage + - task_status + - input_data_id + - input_data_name + - details + properties: + annotation_format_version: + $ref: "#/components/schemas/AnnotationFormatVersion" + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + task_phase: + $ref: "#/components/schemas/TaskPhase" + task_phase_stage: + type: integer + default: 1 + minimum: 1 + task_status: + $ref: "#/components/schemas/TaskStatus" + input_data_id: + $ref: "#/components/schemas/InputDataId" + input_data_name: + type: string + description: 入力データ名 + details: + type: array + description: 矩形、ポリゴン、全体アノテーションなど個々のアノテーションの配列。 + items: + $ref: "#/components/schemas/SimpleAnnotationDetail" + updated_datetime: + type: string + format: date-time + description: 更新日時。アノテーションが一つもない場合(教師付作業が未着手のときなど)は、未指定。 + BatchAnnotation: + type: object + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + input_data_id: + $ref: "#/components/schemas/InputDataId" + annotation_id: + $ref: "#/components/schemas/AnnotationId" + label_id: + $ref: "#/components/schemas/LabelId" + additional_data_list: + type: array + items: + $ref: "#/components/schemas/AdditionalData" + updated_datetime: + type: string + format: date-time + BatchAnnotationRequestItemPut: + type: object + description: アノテーション更新 + required: + - data + properties: + data: + $ref: "#/components/schemas/BatchAnnotation" + _type: + type: string + description: | + `Put` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Put" + BatchAnnotationRequestItemDelete: + type: object + description: アノテーション削除 + required: + - project_id + - task_id + - input_data_id + - annotation_id + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + input_data_id: + $ref: "#/components/schemas/InputDataId" + annotation_id: + $ref: "#/components/schemas/AnnotationId" + updated_datetime: + type: string + format: date-time + _type: + type: string + description: | + `Delete` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Delete" + SingleAnnotationDetail: + type: object + required: + - annotation_id + - account_id + - label_id + - data_holding_type + - additional_data_list + - created_datetime + - updated_datetime + properties: + annotation_id: + $ref: "#/components/schemas/AnnotationId" + account_id: + $ref: "#/components/schemas/AccountId" + label_id: + $ref: "#/components/schemas/LabelId" + data_holding_type: + $ref: "#/components/schemas/AnnotationDataHoldingType" + data: + $ref: "#/components/schemas/FullAnnotationData" + etag: + type: string + description: data_holding_typeがouterの場合のみ存在し、データのETagが格納される + url: + type: string + format: uri + description: data_holding_typeがouterの場合のみ存在し、データへの一時URLが格納される + additional_data_list: + type: array + items: + $ref: "#/components/schemas/AdditionalData" + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + SimpleAnnotationDetail: + type: object + required: + - label + - annotation_id + - data + - attributes + properties: + label: + type: string + example: "pedestrian" + description: | + アノテーション仕様のラベル名です。 + annotation_id: + type: string + example: "acb5359e-be2e-402b-b59a-b5fdbb378ad9" + description: | + 個々のアノテーションにつけられたIDです。 + data: + $ref: "#/components/schemas/FullAnnotationData" + attributes: + type: object + description: | + キーに属性の名前、値に各属性の値が入った辞書構造です。 + example: + maker: "AAA Motors" + size: 12345 + is_foo_bar_buz: true + FullAnnotation: + type: object + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + task_phase: + $ref: "#/components/schemas/TaskPhase" + task_phase_stage: + type: integer + default: 1 + minimum: 1 + task_status: + $ref: "#/components/schemas/TaskStatus" + input_data_id: + $ref: "#/components/schemas/InputDataId" + input_data_name: + type: string + details: + type: array + items: + $ref: "#/components/schemas/FullAnnotationDetail" + updated_datetime: + type: string + format: date-time + annotation_format_version: + $ref: "#/components/schemas/AnnotationFormatVersion" + FullAnnotationDetail: + type: object + properties: + annotation_id: + $ref: "#/components/schemas/AnnotationId" + user_id: + $ref: "#/components/schemas/UserId" + label_id: + $ref: "#/components/schemas/LabelId" + label_name: + $ref: "#/components/schemas/InternationalizationMessage" + annotation_type: + $ref: "#/components/schemas/AnnotationType" + data_holding_type: + $ref: "#/components/schemas/AnnotationDataHoldingType" + data: + $ref: "#/components/schemas/FullAnnotationData" + additional_data_list: + type: array + items: + $ref: "#/components/schemas/FullAnnotationAdditionalData" + AnnotationData: + description: | + アノテーションの座標値や区間などのデータ。 + `annotation_type` に応じて `string` や `object` の構造が変わります。 + + API レスポンスに使われる場合は常に `string` 形式です。 + [putAnnotation](#operation/putAnnotation) APIのリクエストボディに渡す場合は `string` に加え、`object` 形式も使用できます。 + oneOf: + - $ref: "#/components/schemas/FullAnnotationDataString" + - $ref: "#/components/schemas/FullAnnotationData" + FullAnnotationDataString: + type: string + example: "1,1,5,5" + description: | + アノテーション座標値や区間などの文字列表現です。 + アノテーション種類(`annotation_type`)とデータ格納形式(`data_holding_type`)に応じて、以下のとおり表現が変わります。 + + + + + + + + + + +
annotation_typedata_holding_type文字列表現
bounding_boxinner"左上x,左上y,右下x,右下y"
pointinner"x1,y1"
polygon / polylineinner"x1,y1,x2,y2, ... "
range inner"開始時間(ミリ秒),終了時間(ミリ秒) "
classificationinnernull
segmentationouternull
segmentation_v2outernull
+ FullAnnotationData: + oneOf: + - $ref: "#/components/schemas/FullAnnotationDataClassification" + - $ref: "#/components/schemas/FullAnnotationDataSegmentation" + - $ref: "#/components/schemas/FullAnnotationDataSegmentationV2" + - $ref: "#/components/schemas/FullAnnotationDataBoundingBox" + - $ref: "#/components/schemas/FullAnnotationDataPoints" + - $ref: "#/components/schemas/FullAnnotationDataSinglePoint" + - $ref: "#/components/schemas/FullAnnotationDataRange" + - $ref: "#/components/schemas/FullAnnotationDataUnknown" + discriminator: + propertyName: "_type" + mapping: + Classification: "#/components/schemas/FullAnnotationDataClassification" + Segmentation: "#/components/schemas/FullAnnotationDataSegmentation" + SegmentationV2: "#/components/schemas/FullAnnotationDataSegmentationV2" + BoundingBox: "#/components/schemas/FullAnnotationDataBoundingBox" + Points: "#/components/schemas/FullAnnotationDataPoints" + SinglePoint: "#/components/schemas/FullAnnotationDataSinglePoint" + Range: "#/components/schemas/FullAnnotationDataRange" + Unknown: "#/components/schemas/FullAnnotationDataUnknown" + description: | + アノテーションのデータが格納されます。 + * `FullAnnotationDataClassification`: 入力データ全体に対するアノテーションデータです。 + * `FullAnnotationDataSegmentation`: ピクセルレベルでの塗りつぶし(ラスター)のアノテーションデータです。 + * `FullAnnotationDataSegmentationV2`: 塗りつぶしv2ののアノテーションデータです。塗りつぶしv2はSemantic Segmentationに特化しています。 + * `FullAnnotationDataBoundingBox`: 矩形のアノテーションデータです。 + * `FullAnnotationDataPoints`: ポリゴン(閉じた頂点集合)のアノテーションデータです。 + * `FullAnnotationDataSegmentation`: 点のアノテーションデータです。 + * `FullAnnotationDataRange`: 動画区間のアノテーションデータです。 + FullAnnotationDataClassification: + type: object + nullable: true + required: + - _type + properties: + _type: + type: string + description: Classification + example: "Classification" + FullAnnotationDataSegmentation: + description: 塗っていないところは rgba(0,0,0,0)、塗ったところは rgba(255,255,255,1) の PNGデータをBase64エンコードしたもの。 + type: object + nullable: true + required: + - data_uri + - _type + properties: + data_uri: + type: string + _type: + type: string + description: Segmentation + example: "Segmentation" + FullAnnotationDataSegmentationV2: + type: object + nullable: true + required: + - data_uri + - _type + properties: + data_uri: + type: string + _type: + type: string + description: SegmentationV2 + example: "SegmentationV2" + FullAnnotationDataBoundingBox: + description: annotation_type が bounding_boxの場合に、[左上頂点座標, 右下頂点座標]を {"x":int, "y":int} の形式で記述したもの。 + type: object + required: + - left_top + - right_bottom + - _type + properties: + left_top: + $ref: "#/components/schemas/Point" + right_bottom: + $ref: "#/components/schemas/Point" + _type: + type: string + description: BoundingBox + example: "BoundingBox" + FullAnnotationDataPoints: + description: | + 頂点座標 {"x":int, "y":int} の配列。 + + * annotation_type が polygon/polyline の場合: ポリゴン/ポリラインを構成する頂点の配列。 + type: object + required: + - points + - _type + properties: + points: + type: array + items: + $ref: "#/components/schemas/Point" + _type: + type: string + description: Points + example: "Points" + FullAnnotationDataSinglePoint: + description: annotation_type が pointの場合。 + type: object + required: + - point + - _type + properties: + point: + $ref: "#/components/schemas/Point" + _type: + type: string + description: SinglePoint。 + example: "SinglePoint" + FullAnnotationDataRange: + description: annotation_type が rangeの場合に、[開始時間, 終了時間]を {"begin":number, "end":number} の形式で記述したもの。開始時間・終了時間の単位は秒で、精度はミリ秒まで。 + type: object + required: + - begin + - end + - _type + properties: + begin: + type: number + description: 開始時間(ミリ秒)。小数点以下はミリ秒以下を表します。 + end: + type: number + description: 終了時間(ミリ秒)。小数点以下はミリ秒以下を表します。 + _type: + type: string + description: Range + example: "Range" + FullAnnotationDataUnknown: + description: annotation_typeにデータ構造が一致していない場合に、元のdata文字列をそのまま記述したもの。 + type: object + required: + - data + - _type + properties: + data: + type: string + _type: + type: string + description: Unknown + example: "Unknown" + Point: + description: 座標 + type: object + required: + - x + - y + properties: + x: + type: integer + y: + type: integer + FullAnnotationAdditionalData: + type: object + properties: + additional_data_definition_id: + $ref: "#/components/schemas/AdditionalDataDefinitionId" + description: 属性ID + additional_data_definition_name: + $ref: "#/components/schemas/InternationalizationMessage" + description: 属性表示名 + type: + $ref: "#/components/schemas/AdditionalDataDefinitionType" + value: + $ref: "#/components/schemas/AdditionalDataValue" + BatchInspectionRequestItemPut: + type: object + description: 検査コメント更新 + required: + - data + properties: + data: + $ref: "#/components/schemas/Inspection" + _type: + type: string + description: | + `Put` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Put" + BatchInspectionRequestItemDelete: + type: object + description: 検査コメント削除 + required: + - project_id + - task_id + - input_data_id + - inspection_id + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + input_data_id: + $ref: "#/components/schemas/InputDataId" + inspection_id: + $ref: "#/components/schemas/InspectionId" + _type: + type: string + description: | + `Delete` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Delete" + Inspection: + type: object + description: 検査コメント + required: + - project_id + - task_id + - input_data_id + - inspection_id + - phase + - phase_stage + - commenter_account_id + - data + - status + - comment + - created_datetime + properties: + project_id: + $ref: "#/components/schemas/ProjectId" + task_id: + $ref: "#/components/schemas/TaskId" + input_data_id: + $ref: "#/components/schemas/InputDataId" + inspection_id: + $ref: "#/components/schemas/InspectionId" + phase: + $ref: "#/components/schemas/TaskPhase" + description: 検査コメントを付与したときのタスクフェーズ。[詳細はこちら](#section/TaskPhase) + phase_stage: + type: integer + description: 検査コメントを付与したときのフェーズのステージ + default: 1 + minimum: 1 + commenter_account_id: + $ref: "#/components/schemas/AccountId" + description: 検査コメントを付与したユーザのアカウントID + annotation_id: + $ref: "#/components/schemas/AnnotationId" + description: | + 検査コメントに紐づくアノテーションのID。アノテーションに紐付けられていない場合(アノテーションの付け忘れに対する指定など)は未指定。 + [詳細はこちら](#section/AnnotationId)。 + data: + $ref: "#/components/schemas/InspectionData" + parent_inspection_id: + $ref: "#/components/schemas/InspectionId" + description: | + 返信先の検査コメントの検査ID。返信先の検査コメントは「スレッド内の直前のコメント」ではなく「スレッドの先頭のコメント」を指します。 + phrases: + type: array + description: 参照している定型指摘のID。 + items: + $ref: "#/components/schemas/PhraseId" + comment: + description: | + 検査コメントの中身 + type: string + example: 枠がズレています + status: + $ref: "#/components/schemas/InspectionStatus" + created_datetime: + type: string + format: date-time + updated_datetime: + type: string + format: date-time + InspectionData: + description: | + 検査コメントの座標値や区間。 + + * `InspectionDataPoint`:点で検査コメントを付与したときの座標値 + * `InspectionDataPolyline`:ポリラインで検査コメントを付与したときの座標値 + * `InspectionDataTime`:検査コメントを付与した区間(動画プロジェクトの場合) + * `InspectionDataCustom`:カスタム + oneOf: + - $ref: "#/components/schemas/InspectionDataPoint" + - $ref: "#/components/schemas/InspectionDataPolyline" + - $ref: "#/components/schemas/InspectionDataTime" + - $ref: "#/components/schemas/InspectionDataCustom" + discriminator: + propertyName: "_type" + mapping: + Point: "#/components/schemas/InspectionDataPoint" + Polyline: "#/components/schemas/InspectionDataPolyline" + Time: "#/components/schemas/InspectionDataTime" + Custom: "#/components/schemas/InspectionDataCustom" + InspectionDataPoint: + type: object + description: | + 問題のある部分を示す座標 + required: + - x + - y + properties: + x: + type: integer + y: + type: integer + _type: + type: string + description: | + `Point` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Point" + InspectionDataPolyline: + type: object + description: | + 問題のある部分を示すポリライン + required: + - coordinates + properties: + coordinates: + type: array + description: | + ポリラインを構成する頂点の配列 + items: + type: object + properties: + x: + type: integer + y: + type: integer + _type: + type: string + description: | + `Polyline` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Polyline" + InspectionDataTime: + type: object + description: | + 問題のある時間帯を表す区間 + required: + - start + - end + properties: + start: + type: number + description: 開始時間(ミリ秒)。小数点以下はミリ秒以下を表します。 + end: + type: number + description: 終了時間(ミリ秒)。小数点以下はミリ秒以下を表します。 + _type: + type: string + description: | + `Time` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Time" + InspectionDataCustom: + type: object + properties: + data: + type: string + _type: + type: string + description: | + `Custom` + [詳しくはこちら](#section/API-Convention/API-_type) + example: "Custom" + Resolution: + type: object + required: + - width + - height + properties: + width: + type: number + height: + type: number + InspectionStatus: + type: string + enum: + - annotator_action_required + - no_correction_required + - error_corrected + - no_comment_inspection + description: | + * `annotator_action_required` - 未処置。`annotation`フェーズ担当者が何らかの回答をする必要あり + * `no_correction_required` - 処置不要。`annotation`フェーズ担当者が、検査コメントによる修正は不要、と回答した + * `error_corrected` - 修正済み。`annotation`フェーズ担当者が、検査コメントの指示どおり修正した + * `no_comment_inspection` - 作成途中。検査コメントの中身が未入力 + AggregationResult: + oneOf: + - $ref: "#/components/schemas/CountResult" + CountResult: + type: object + properties: + _type: + type: string + example: "CountResult" + description: | + `CountResult` + [詳しくはこちら](#section/API-Convention/API-_type) + name: + type: string + description: | + 複数の集約を区別するための名前です。 + + `(フィールド名)_(集約内容)` のように命名されます。例えば `account_id` フィールドを `count` する場合、`account_id_count` となります。 + field: + type: string + description: | + 集約に使われたリソースのフィールド名です。 + + リソースの属性のさらに属性を参照するときは、`foo.bar.buz` のようにドット区切りになります。 + items: + type: array + items: + $ref: "#/components/schemas/Count" + description: | + 集約結果の値です。 + Count: + type: object + properties: + key: + type: string + description: | + 集約対象の `field` の値です。 + count: + type: integer + description: | + 集約対象 `field` の値が `key` の値と等しかったリソースの件数です。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + この集約のサブ集約です。サブ集約がないときは空の配列になります。 + Instruction: + type: object + properties: + html: + type: string + description: 作業ガイドのHTML + example: "

test

" + last_updated_datetime: + type: string + format: date-time + description: | + * [getInstruction](#operation/getInstruction) APIのレスポンスの場合: 最後に作業ガイドを更新した日時。 + * [putInstruction](#operation/putInstruction) APIのリクエストボディの場合: 最後に作業ガイドを更新した日時を指定する。まだ一度も保存した事がない場合は指定しない。 + InstructionHistory: + type: object + required: + - history_id + - account_id + - updated_datetime + properties: + history_id: + type: string + description: 作業ガイドの履歴ID + account_id: + type: string + description: 作業ガイドを更新したユーザのアカウントID + updated_datetime: + type: string + format: date-time + description: 作業ガイドの最終更新日時 + InstructionImage: + type: object + required: + - image_id + - path + - url + - etag + properties: + image_id: + type: string + description: 作業ガイド画像ID + path: + type: string + example: "s3://ANNOFAB-BUCKET/PATH/TO/INSTRUCTION_IMAGE" + description: | + 作業ガイド画像の実体が保存されたパスです。 + url: + type: string + format: uri + example: https://annofab.com/projects/{project_id}/instruction-images/{image_id} + description: + 作業ガイド画像を取得するための内部用URLです。 + etag: + type: string + ValidationError: + oneOf: + - $ref: "#/components/schemas/InvalidAnnotationData" + - $ref: "#/components/schemas/DuplicatedSegmentationV2" + - $ref: "#/components/schemas/InvalidCommentFormat" + - $ref: "#/components/schemas/UnknownLinkTarget" + - $ref: "#/components/schemas/InvalidLinkTarget" + - $ref: "#/components/schemas/EmptyAttribute" + - $ref: "#/components/schemas/Duplicated" + - $ref: "#/components/schemas/UnknownAdditionalData" + - $ref: "#/components/schemas/OutOfImageBounds" + - $ref: "#/components/schemas/UnknownLabel" + discriminator: + propertyName: "_type" + mapping: + InvalidAnnotationData: "#/components/schemas/InvalidAnnotationData" + DuplicatedSegmentationV2: "#/components/schemas/DuplicatedSegmentationV2" + InvalidCommentFormat: "#/components/schemas/InvalidCommentFormat" + UnknownLinkTarget: "#/components/schemas/UnknownLinkTarget" + InvalidLinkTarget: "#/components/schemas/InvalidLinkTarget" + EmptyAttribute: "#/components/schemas/EmptyAttribute" + Duplicated: "#/components/schemas/Duplicated" + UnknownAdditionalData: "#/components/schemas/UnknownAdditionalData" + OutOfImageBounds: "#/components/schemas/OutOfImageBounds" + UnknownLabel: "#/components/schemas/UnknownLabel" + InvalidAnnotationData: + type: object + description: アノテーションデータ不正エラー + properties: + labelId: + type: string + annotationId: + type: string + message: + type: string + _type: + type: string + description: InvalidAnnotationData + example: "InvalidAnnotationData" + DuplicatedSegmentationV2: + type: object + description: 塗りつぶしv2のラベルに対する1ラベルにつき1アノテーションまでの制約違反エラー + properties: + labelId: + type: string + annotationIds: + type: array + items: + type: string + _type: + type: string + description: DuplicatedSegmentationV2 + example: "DuplicatedSegmentationV2" + InvalidCommentFormat: + type: object + description: コメントが正規表現に合致しないエラー + properties: + labelId: + type: string + annotationId: + type: string + additionalDataDefinitionId: + type: string + _type: + type: string + description: InvalidCommentFormat + example: "InvalidCommentFormat" + UnknownLinkTarget: + type: object + description: 指定されたIDに該当するアノテーションが存在しないエラー + properties: + labelId: + type: string + annotationId: + type: string + additionalDataDefinitionId: + type: string + _type: + type: string + description: UnknownLinkTarget + example: "UnknownLinkTarget" + InvalidLinkTarget: + type: object + description: リンク先アノテーションが許可されているラベルでないエラー + properties: + labelId: + type: string + annotationId: + type: string + additionalDataDefinitionId: + type: string + _type: + type: string + description: InvalidLinkTarget + example: "InvalidLinkTarget" + EmptyAttribute: + type: object + description: 属性が未入力であるエラー + properties: + labelId: + type: string + annotationId: + type: string + additionalDataDefinitionId: + type: string + _type: + type: string + description: EmptyAttribute + example: "EmptyAttribute" + Duplicated: + type: object + description: 値の重複が許可されていない属性の重複エラー + properties: + labelId: + type: string + annotationId: + type: string + additionalData: + $ref: "#/components/schemas/AdditionalData" + _type: + type: string + description: Duplicated + example: "Duplicated" + UnknownAdditionalData: + type: object + description: 何らかの原因で、アノテーション仕様にない属性がついているエラー + properties: + labelId: + type: string + annotationId: + type: string + additionalDataDefinitionId: + type: string + _type: + type: string + description: UnknownAdditionalData + example: "UnknownAdditionalData" + OutOfImageBounds: + type: object + description: 画像範囲外にアノテーションがはみ出しているエラー + properties: + labelId: + type: string + annotationId: + type: string + _type: + type: string + description: OutOfImageBounds + example: "OutOfImageBounds" + UnknownLabel: + type: object + description: 何らかの原因で、アノテーション仕様にないラベルがついているエラー + properties: + labelId: + type: string + annotationId: + type: string + _type: + type: string + description: UnknownLabel + example: "UnknownLabel" + ProjectTaskCounts: + type: object + properties: + task_counts: + type: array + items: + type: object + properties: + phase: + $ref: "#/components/schemas/TaskPhase" + status: + $ref: "#/components/schemas/TaskStatus" + count: + description: 該当するタスクの数 + type: number + TemporaryUrl: + type: object + description: 認証済み一時URL + properties: + url: + type: string + description: 認証済み一時URL + AnnotationList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/SingleAnnotation" + description: 現在のページ番号に含まれる0件以上のアノテーションです。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるアノテーションが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + InputDataList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/InputData" + description: 現在のページ番号に含まれる0件以上の入力データです。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる入力データが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + JobInfoContainer: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/JobInfo" + has_next: + type: boolean + MyOrganizationList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/MyOrganization" + description: 現在のページ番号に含まれる0件以上の所属組織です。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる所属組織が0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + ProjectList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/Project" + description: 現在のページ番号に含まれる0件以上のプロジェクトです。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + OrganizationMemberList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/OrganizationMember" + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまる組織メンバーが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + OrganizationPluginList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/OrganizationPlugin" + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + ProjectMemberList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/ProjectMember" + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるプロジェクトメンバーが0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + ProjectContainer: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/Project" + has_next: + type: boolean + TaskList: + type: object + properties: + list: + type: array + items: + $ref: "#/components/schemas/Task" + description: 現在のページ番号に含まれる0件以上のタスクです。 + page_no: + type: number + description: 現在のページ番号です。 + total_page_no: + type: number + description: 指定された条件にあてはまる検索結果の総ページ数。検索条件に当てはまるタスク0件であっても、総ページ数は1となります。 + total_count: + type: number + description: 検索結果の総件数。 + over_limit: + type: boolean + description: 検索結果が1万件を超えた場合にtrueとなる。 + aggregations: + type: array + items: + $ref: "#/components/schemas/AggregationResult" + description: | + [Aggregationによる集約結果](#section/API-Convention/AggregationResult)。 + BatchAnnotationRequestItem: + oneOf: + - $ref: "#/components/schemas/BatchAnnotationRequestItemPut" + - $ref: "#/components/schemas/BatchAnnotationRequestItemDelete" + discriminator: + propertyName: "_type" + mapping: + Put: "#/components/schemas/BatchAnnotationRequestItemPut" + Delete: "#/components/schemas/BatchAnnotationRequestItemDelete" + BatchInspectionRequestItem: + oneOf: + - $ref: "#/components/schemas/BatchInspectionRequestItemPut" + - $ref: "#/components/schemas/BatchInspectionRequestItemDelete" + discriminator: + propertyName: "_type" + mapping: + Put: "#/components/schemas/BatchInspectionRequestItemPut" + Delete: "#/components/schemas/BatchInspectionRequestItemDelete" + BatchInputDataRequestItem: + oneOf: + - $ref: "#/components/schemas/BatchInputDataRequestItemDelete" + discriminator: + propertyName: "_type" + mapping: + Delete: "#/components/schemas/BatchInputDataRequestItemDelete" + BatchTaskRequestItem: + oneOf: + - $ref: "#/components/schemas/BatchTaskRequestItemDelete" + discriminator: + propertyName: "_type" + mapping: + Delete: "#/components/schemas/BatchTaskRequestItemDelete" + AdditionalDataDefaultType: + oneOf: + - type: boolean + - type: integer + - type: string + description: | + 属性の初期値です。 + + 初期値を指定する場合、属性の種類に応じて次の値を指定します。初期値を設定しない場合には空文字を指定します。 + + * type が flag の場合: 真偽値(`true` or `false`) + * type が integer の場合: 整数値 + * type が text の場合: 文字列 + * type が comment の場合: 文字列 + * type が choice の場合: 選択肢(`choices`)の `choice_id` + * type が select の場合: 選択肢(`choices`)の `choice_id` + + 属性の種類に対して有効でない初期値を設定した場合、その設定は無視されます。 + + なお、トラッキングとリンクには初期値を設定できません。 + DeleteProjectResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Project" + - $ref: "#/components/schemas/DeleteProjectResponse" + ProjectCopyResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Project" + - $ref: "#/components/schemas/ProjectCopyResponse" + PostProjectTasksUpdateResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Message" + - $ref: "#/components/schemas/PostProjectTasksUpdateResponse" + PutProjectResponseWrapper: + oneOf: + - $ref: "swagger-api-components.yaml#/components/schemas/Project" + - $ref: "swagger-api-components.yaml#/components/schemas/PutProjectResponse" + AnnotationSpecs: + oneOf: + - $ref: "#/components/schemas/AnnotationSpecsV1" + - $ref: "#/components/schemas/AnnotationSpecsV2" + AnnotationSpecsRequest: + oneOf: + - $ref: "#/components/schemas/AnnotationSpecsRequestV1" + - $ref: "#/components/schemas/AnnotationSpecsRequestV2" + TaskGenerateResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Project" + - $ref: "#/components/schemas/TaskGenerateResponse" + PostAnnotationArchiveUpdateResponseWrapper: + oneOf: + - $ref: "#/components/schemas/Message" + - $ref: "#/components/schemas/PostAnnotationArchiveUpdateResponse" + MessageOrJobInfo: + oneOf: + - $ref: "#/components/schemas/Message" + - $ref: "#/components/schemas/JobInfo" From 2be33042371a4482ba75ff52a1318d2d50564496 Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 10:08:24 +0900 Subject: [PATCH 11/15] update generate.sh --- generate/generate.sh | 24 ++++--------------- .../partial-header/dataclass/annotation.py | 2 +- 2 files changed, 5 insertions(+), 21 deletions(-) diff --git a/generate/generate.sh b/generate/generate.sh index bdc84fc6..836da711 100755 --- a/generate/generate.sh +++ b/generate/generate.sh @@ -47,20 +47,7 @@ if "${FLAG_DOWNLOAD}"; then curl https://annofab.com/docs/api/swagger.yaml --output swagger/swagger.yaml curl https://annofab.com/docs/api/swagger.v2.yaml --output swagger/swagger.v2.yaml curl https://annofab.com/docs/api/swagger-api-components.yaml --output swagger/swagger-api-components.yaml - -# # インデントを1つ深くする -# sed -e "s/#\/schemas/#\/components\/schemas/g" -e "s/^/ /g" swagger/swagger-api-components.yaml --in-place -# -# sed '/swagger-api-components.yaml/d' swagger/swagger.yaml > swagger/swagger-tmp.yaml -# cat swagger/swagger-tmp.yaml swagger/swagger-api-components.yaml > swagger/swagger.yaml -# -# sed '/swagger-api-components.yaml/d' swagger/swagger.v2.yaml > swagger/swagger-tmp.v2.yaml -# cat swagger/swagger-tmp.v2.yaml swagger/swagger-api-components.yaml > swagger/swagger.v2.yaml -# -# rm swagger/swagger-tmp.yaml swagger/swagger-tmp.v2.yaml - - cat swagger/swagger-partial-header.yaml swagger/swagger-api-components.yaml > swagger/swagger-models.yaml - + cat swagger/swagger-partial-header.yaml swagger/swagger-api-components.yaml > swagger/swagger-models.yaml fi @@ -79,12 +66,8 @@ docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=$ --ignore-file-override=/local/.openapi-generator-ignore_v1 cat partial-header/generated_api_partial_header_v1.py out/openapi_client/api/*_api.py > ../annofabapi/generated_api.py - -cat partial-header/models_partial_header_v1.py out/openapi_client/models/*.py > ../annofabapi/models.py - rm -Rf out/openapi_client - # v2 apiを生成 docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=${JAVA_OPTS} ${DOCKER_IMAGE} generate \ --input-spec swagger/swagger.v2.yaml \ @@ -94,7 +77,6 @@ docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=${ --ignore-file-override=/local/.openapi-generator-ignore_v2 cat partial-header/generated_api_partial_header_v2.py out/openapi_client/api/*_api.py > ../annofabapi/generated_api2.py - rm -Rf out/openapi_client @@ -106,11 +88,13 @@ docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=${ --global-property ,models,modelTests=false,modelDocs=false \ --ignore-file-override=/local/.openapi-generator-ignore_v1 +cat partial-header/models_partial_header_v1.py out/openapi_client/models/*.py > ../annofabapi/models.py +rm -Rf out/openapi_client # v1 apiのmodelからDataClass用のpythonファイルを生成する。 docker run --rm -u `id -u`:`id -g` -v ${PWD}:/local -w /local -e JAVA_OPTS=${JAVA_OPTS} \ ${DOCKER_IMAGE} generate \ - --input-spec swagger/swagger.yaml \ + --input-spec swagger/swagger-models.yaml \ ${OPENAPI_GENERATOR_CLI_COMMON_OPTION} \ --template-dir /local/template_dataclass \ --global-property models,modelTests=false,modelDocs=false \ diff --git a/generate/partial-header/dataclass/annotation.py b/generate/partial-header/dataclass/annotation.py index e4470433..1f6e2978 100644 --- a/generate/partial-header/dataclass/annotation.py +++ b/generate/partial-header/dataclass/annotation.py @@ -7,6 +7,6 @@ TaskStatus, ) -AdditionalDataValue = Union[str, Dict[str, Any]] +AnnotationData = Union[str, Dict[str, Any]] FullAnnotationData = Dict[str, Any] AdditionalDataValue = Dict[str, Any] From ab4d8f8b19bd1efcd424240611647dc3ff8c2fb6 Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 10:09:36 +0900 Subject: [PATCH 12/15] update models --- annofabapi/dataclass/annotation.py | 90 +++++++ annofabapi/dataclass/input.py | 1 + annofabapi/models.py | 389 ++++++++++++++++++++++++++++- 3 files changed, 477 insertions(+), 3 deletions(-) diff --git a/annofabapi/dataclass/annotation.py b/annofabapi/dataclass/annotation.py index 9b9edce3..187dd4d0 100644 --- a/annofabapi/dataclass/annotation.py +++ b/annofabapi/dataclass/annotation.py @@ -167,6 +167,96 @@ class AdditionalData: """""" +@dataclass_json +@dataclass +class FullAnnotationAdditionalData: + """ + + """ + + additional_data_definition_id: Optional[str] + """""" + + additional_data_definition_name: Optional[InternationalizationMessage] + """""" + + type: Optional[AdditionalDataDefinitionType] + """""" + + value: Optional[AdditionalDataValue] + """""" + + +@dataclass_json +@dataclass +class FullAnnotationDetail: + """ + + """ + + annotation_id: Optional[str] + """アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
annotation_type が classification の場合は label_id と同じ値が格納されます。 """ + + user_id: Optional[str] + """""" + + label_id: Optional[str] + """""" + + label_name: Optional[InternationalizationMessage] + """""" + + annotation_type: Optional[AnnotationType] + """""" + + data_holding_type: Optional[AnnotationDataHoldingType] + """""" + + data: Optional[FullAnnotationData] + """""" + + additional_data_list: Optional[List[FullAnnotationAdditionalData]] + """""" + + +@dataclass_json +@dataclass +class FullAnnotation: + """ + + """ + + project_id: Optional[str] + """プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) """ + + task_id: Optional[str] + """タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) """ + + task_phase: Optional[TaskPhase] + """""" + + task_phase_stage: Optional[int] + """""" + + task_status: Optional[TaskStatus] + """""" + + input_data_id: Optional[str] + """入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) """ + + input_data_name: Optional[str] + """""" + + details: Optional[List[FullAnnotationDetail]] + """""" + + updated_datetime: Optional[str] + """""" + + annotation_format_version: Optional[str] + """アノテーションフォーマットのバージョンです。 アノテーションフォーマットとは、プロジェクト個別のアノテーション仕様ではなく、AnnoFabのアノテーション構造のことです。 したがって、アノテーション仕様を更新しても、このバージョンは変化しません。 バージョンの読み方と更新ルールは、業界慣習の[Semantic Versioning](https://semver.org/)にもとづきます。 JSONに出力されるアノテーションフォーマットのバージョンは、アノテーションZIPが作成される時点のものが使われます。 すなわち、`1.0.0`の時点のタスクで作成したアノテーションであっても、フォーマットが `1.0.1` に上がった次のZIP作成時では `1.0.1` となります。 バージョンを固定してZIPを残しておきたい場合は、プロジェクトが完了した時点でZIPをダウンロードして保管しておくか、またはプロジェクトを「停止中」にします。 """ + + @dataclass_json @dataclass class SimpleAnnotationDetail: diff --git a/annofabapi/dataclass/input.py b/annofabapi/dataclass/input.py index 2cfff15b..d9b16397 100644 --- a/annofabapi/dataclass/input.py +++ b/annofabapi/dataclass/input.py @@ -17,6 +17,7 @@ SystemMetadata = Dict[str, Any] + @dataclass_json @dataclass class Resolution: diff --git a/annofabapi/models.py b/annofabapi/models.py index 2d383928..ca9ba9d3 100644 --- a/annofabapi/models.py +++ b/annofabapi/models.py @@ -242,6 +242,19 @@ class AccountAuthority(Enum): * choice: str +""" + +AdditionalDataChoiceValue = Dict[str, Any] +""" + + +Kyes of Dict + +* id: str + +* name: InternationalizationMessage + + """ AdditionalDataDefaultType = Dict[str, Any] @@ -461,6 +474,97 @@ class AdditionalDataDefinitionType(Enum): * value: str +""" + +AdditionalDataValue = Dict[str, Any] +""" + + +Kyes of Dict + +* type: str + Link +* value: str + リンク先アノテーションID + +""" + +AdditionalDataValueChoice = Dict[str, Any] +""" + + +Kyes of Dict + +* type: str + Choice +* value: AdditionalDataChoiceValue + + +""" + +AdditionalDataValueComment = Dict[str, Any] +""" + + +Kyes of Dict + +* type: str + Comment +* value: str + 自由記述 + +""" + +AdditionalDataValueFlag = Dict[str, Any] +""" + + +Kyes of Dict + +* type: str + Flag +* value: bool + フラグのON(true)またはOFF(false) + +""" + +AdditionalDataValueInteger = Dict[str, Any] +""" + + +Kyes of Dict + +* type: str + Integer +* value: int + 整数値 + +""" + +AdditionalDataValueLink = Dict[str, Any] +""" + + +Kyes of Dict + +* type: str + Link +* value: str + リンク先アノテーションID + +""" + +AdditionalDataValueTracking = Dict[str, Any] +""" + + +Kyes of Dict + +* type: str + Tracking +* value: str + トラッキングID + """ AggregationResult = Dict[str, Any] @@ -1239,6 +1343,52 @@ class AssigneeRuleOfResubmittedTask(Enum): * context: __DictStrKeyAnyValue__ 内部補足情報 +""" + +FullAnnotation = Dict[str, Any] +""" + + +Kyes of Dict + +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* task_id: str + タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* task_phase: TaskPhase + +* task_phase_stage: int + +* task_status: TaskStatus + +* input_data_id: str + 入力データID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* input_data_name: str + +* details: List[FullAnnotationDetail] + +* updated_datetime: str + +* annotation_format_version: str + アノテーションフォーマットのバージョンです。 アノテーションフォーマットとは、プロジェクト個別のアノテーション仕様ではなく、AnnoFabのアノテーション構造のことです。 したがって、アノテーション仕様を更新しても、このバージョンは変化しません。 バージョンの読み方と更新ルールは、業界慣習の[Semantic Versioning](https://semver.org/)にもとづきます。 JSONに出力されるアノテーションフォーマットのバージョンは、アノテーションZIPが作成される時点のものが使われます。 すなわち、`1.0.0`の時点のタスクで作成したアノテーションであっても、フォーマットが `1.0.1` に上がった次のZIP作成時では `1.0.1` となります。 バージョンを固定してZIPを残しておきたい場合は、プロジェクトが完了した時点でZIPをダウンロードして保管しておくか、またはプロジェクトを「停止中」にします。 + +""" + +FullAnnotationAdditionalData = Dict[str, Any] +""" + + +Kyes of Dict + +* additional_data_definition_id: str + +* additional_data_definition_name: InternationalizationMessage + +* type: AdditionalDataDefinitionType + +* value: AdditionalDataValue + + """ FullAnnotationData = Dict[str, Any] @@ -1374,6 +1524,31 @@ class AssigneeRuleOfResubmittedTask(Enum): """ +FullAnnotationDetail = Dict[str, Any] +""" + + +Kyes of Dict + +* annotation_id: str + アノテーションID。[値の制約についてはこちら。](#section/API-Convention/APIID)
annotation_type が classification の場合は label_id と同じ値が格納されます。 +* user_id: str + +* label_id: str + +* label_name: InternationalizationMessage + +* annotation_type: AnnotationType + +* data_holding_type: AnnotationDataHoldingType + +* data: FullAnnotationData + +* additional_data_list: List[FullAnnotationAdditionalData] + + +""" + class GraphType(Enum): """ @@ -1899,6 +2074,31 @@ class InspectionSummary(Enum): * updated_datetime: str +""" + +JobInfo2 = Dict[str, Any] +""" + + +Kyes of Dict + +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* job_type: JobType + +* job_id: str + +* job_status: JobStatus + +* job_execution: __DictStrKeyAnyValue__ + ジョブの内部情報 +* job_detail: __DictStrKeyAnyValue__ + ジョブ結果の内部情報 +* created_datetime: str + +* updated_datetime: str + + """ JobInfoContainer = Dict[str, Any] @@ -2294,6 +2494,23 @@ class JobType(Enum): * storage_usage_bytes: float +""" + +OrganizationCacheRecord = Dict[str, Any] +""" + + +Kyes of Dict + +* input: str + +* members: str + +* statistics: str + +* organization: str + + """ OrganizationMember = Dict[str, Any] @@ -2570,6 +2787,35 @@ class PricePlan(Enum): * summary: ProjectSummary +""" + +Project2 = Dict[str, Any] +""" + + +Kyes of Dict + +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* organization_id: str + 組織ID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* title: str + プロジェクトのタイトル +* overview: str + プロジェクトの概要 +* project_status: ProjectStatus + +* input_data_type: InputDataType + +* configuration: ProjectConfiguration2 + +* created_datetime: str + +* updated_datetime: str + +* summary: ProjectSummary + + """ ProjectAccountStatistics = Dict[str, Any] @@ -2600,12 +2846,66 @@ class PricePlan(Enum): * worktime: str 作業時間(ISO 8601 duration) +""" + +ProjectCacheRecord = Dict[str, Any] +""" + + +Kyes of Dict + +* input: str + +* members: str + +* project: str + +* instruction: str + +* specs: str + +* statistics: str + +* organization: str + +* supplementary: str + + """ ProjectConfiguration = Dict[str, Any] """ +Kyes of Dict + +* number_of_inspections: int + 検査回数。 * 0回:教師付け -> 受入 * 1回:教師付け -> 検査 -> 受入 * n回(n >= 2):教師付け -> 検査1 -> ... -> 検査n -> 受入 +* assignee_rule_of_resubmitted_task: AssigneeRuleOfResubmittedTask + +* task_assignment_type: TaskAssignmentType + +* max_tasks_per_member: int + 保留中のタスクを除き、1人(オーナー以外)に割り当てられるタスク数上限。未指定の場合は10件として扱う。 +* max_tasks_per_member_including_hold: int + 保留中のタスクを含めて、1人(オーナー以外)に割り当てられるタスク数上限。未指定の場合は20件として扱う。 +* input_data_set_id_list: List[str] + このフィールドは内部用でまだ何も意味を成しません。今は空配列を指定してください。 +* input_data_max_long_side_length: int + 入力データ画像の長辺の最大値(未指定時は4096px)。 画像をアップロードすると、長辺がこの値になるように画像が自動で圧縮されます。 アノテーションの座標は、もとの解像度の画像でつけたものに復元されます。 大きな数値を設定すると入力データ画像のサイズが大きくなり、生産性低下やブラウザで画像を表示できない懸念があります。注意して設定してください。 +* sampling_inspection_rate: int + 抜取検査率。0-100のパーセント値で指定し、未指定の場合は100%として扱う。 +* sampling_acceptance_rate: int + 抜取受入率。0-100のパーセント値で指定し、未指定の場合は100%として扱う。 +* private_storage_aws_iam_role_arn: str + AWS IAMロール。ビジネスプランでのS3プライベートストレージの認可で使います。 [S3プライベートストレージの認可の設定についてはこちら](/docs/faq/#m0b240)をご覧ください。 + +""" + +ProjectConfiguration2 = Dict[str, Any] +""" + + Kyes of Dict * number_of_inspections: int @@ -2860,6 +3160,32 @@ class ProjectStatus(Enum): """ +ProjectTaskCounts = Dict[str, Any] +""" + + +Kyes of Dict + +* task_counts: List[ProjectTaskCountsTaskCounts] + + +""" + +ProjectTaskCountsTaskCounts = Dict[str, Any] +""" + + +Kyes of Dict + +* phase: TaskPhase + +* status: TaskStatus + +* count: float + 該当するタスクの数 + +""" + ProjectTaskStatistics = Dict[str, Any] """ @@ -3007,6 +3333,19 @@ class ProjectStatus(Enum): * project: Project +""" + +PutProjectResponse2 = Dict[str, Any] +""" + + +Kyes of Dict + +* job: JobInfo2 + +* project: Project2 + + """ PutProjectResponseWrapper = Dict[str, Any] @@ -3027,7 +3366,7 @@ class ProjectStatus(Enum): * input_data_type: InputDataType -* configuration: ProjectConfiguration +* configuration: ProjectConfiguration2 * created_datetime: str @@ -3035,9 +3374,9 @@ class ProjectStatus(Enum): * summary: ProjectSummary -* job: JobInfo +* job: JobInfo2 -* project: Project +* project: Project2 """ @@ -3552,6 +3891,33 @@ class TaskAssignmentType(Enum): * account_id: str +""" + +TaskHistoryEvent = Dict[str, Any] +""" +タスク履歴イベントは、タスクの状態が変化した1時点を表します。作業時間は、複数のこれらイベントを集約して計算するものなので、このオブジェクトには含まれません。 + +Kyes of Dict + +* project_id: str + プロジェクトID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* task_id: str + タスクID。[値の制約についてはこちら。](#section/API-Convention/APIID) +* task_history_id: str + +* created_datetime: str + +* phase: TaskPhase + +* phase_stage: int + +* status: TaskStatus + +* account_id: str + +* request: TaskOperation + + """ TaskHistoryShort = Dict[str, Any] @@ -3760,6 +4126,23 @@ class TaskStatus(Enum): * type: str UnknownLinkTarget +""" + +UserCacheRecord = Dict[str, Any] +""" + + +Kyes of Dict + +* account: str + +* members: str + +* projects: str + +* organizations: str + + """ ValidationError = Dict[str, Any] From 1c6683ecd5ad6b4c9930225c67cd6e12ff35295f Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 10:26:50 +0900 Subject: [PATCH 13/15] =?UTF-8?q?=E4=B8=8D=E8=A6=81=E3=81=AA=E3=83=A1?= =?UTF-8?q?=E3=82=BD=E3=83=83=E3=83=89=E3=82=92=E5=89=8A=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- annofabapi/wrapper.py | 60 ------------------------------------------- 1 file changed, 60 deletions(-) diff --git a/annofabapi/wrapper.py b/annofabapi/wrapper.py index 235f3d81..4581f866 100644 --- a/annofabapi/wrapper.py +++ b/annofabapi/wrapper.py @@ -55,15 +55,6 @@ class AnnotationSpecsRelation: choice_id: Dict[ChoiceKey, ChoiceKey] -@dataclass(frozen=True) -class AnnotationQuery: - """ - 削除対象のアノテーションを指定するクエリ - """ - - label_id: str - - def _first_true(iterable, default=None, pred=None): return next(filter(pred, iterable), default) @@ -366,57 +357,6 @@ def copy_annotation( self.api.put_annotation(dest.project_id, dest.task_id, dest.input_data_id, request_body=request_body) return True - @staticmethod - def __match_query_for_annotation(annotation_detail: Dict[str, Any], query: AnnotationQuery) -> bool: - return annotation_detail["label_id"] == query.label_id - - @staticmethod - def __to_put_annotation_detail(annotation_detail: Dict[str, Any]) -> Dict[str, Any]: - """ - `get_annotation_editor`メソッドで取得したアノテーションを、`put_annotation`メソッドに渡すアノテーションに変換する - """ - annotation_detail["url"] = None - return annotation_detail - - def delete_annotation( - self, project_id: str, task_id: str, input_data_id: str, query: Optional[AnnotationQuery] = None - ) -> Optional[Dict[str, Any]]: - """ - 特定のアノテーションを削除する - - Args: - project_id: - task_id: - input_data_id: - query: 削除対象のアノテーションを指定するクエリ - - Returns: - `put_annotation`メソッドのレスポン - """ - old_annotation, _ = self.api.get_editor_annotation(project_id, task_id, input_data_id) - old_details = old_annotation["details"] - if len(old_details) == 0: - return None - - if query is None: - new_details = [] - else: - new_details = [ - self.__to_put_annotation_detail(d) - for d in old_details - if not self.__match_query_for_annotation(d, query) - ] - - updated_datetime = old_annotation["updated_datetime"] - request_body = { - "project_id": project_id, - "task_id": task_id, - "input_data_id": input_data_id, - "details": new_details, - "updated_datetime": updated_datetime, - } - return self.api.put_annotation(project_id, task_id, input_data_id, request_body=request_body)[0] - ######################################### # Public Method : AnnotationSpecs ######################################### From 86a3c0414c1418f93fdbc256dc0d9cf84130669d Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 10:27:21 +0900 Subject: [PATCH 14/15] =?UTF-8?q?test=20data=E3=81=AE=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/data/dataclass/input-data.json | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/data/dataclass/input-data.json b/tests/data/dataclass/input-data.json index d1c18df6..718edbdb 100644 --- a/tests/data/dataclass/input-data.json +++ b/tests/data/dataclass/input-data.json @@ -11,5 +11,10 @@ "original_resolution": null, "input_duration": null, "sign_required": false, - "metadata": {} + "metadata": {}, + "system_metadata": { + "resized_resolution": null, + "original_resolution": null, + "_type": "Image" + } } From 7ae2782e8e349163c6439b0cfd7aab4f2d573cb3 Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Wed, 24 Jun 2020 10:35:04 +0900 Subject: [PATCH 15/15] update poetry, version up --- annofabapi/__version__.py | 2 +- poetry.lock | 168 +++++++++++++++++++------------------- pyproject.toml | 2 +- 3 files changed, 86 insertions(+), 86 deletions(-) diff --git a/annofabapi/__version__.py b/annofabapi/__version__.py index 49f85f29..eab0e9cd 100644 --- a/annofabapi/__version__.py +++ b/annofabapi/__version__.py @@ -1 +1 @@ -__version__ = "0.33.1" +__version__ = "0.34.0" diff --git a/poetry.lock b/poetry.lock index e7d6a0e4..6b1dacf1 100644 --- a/poetry.lock +++ b/poetry.lock @@ -28,7 +28,7 @@ description = "An abstract syntax tree for Python with inference support." name = "astroid" optional = false python-versions = ">=3.5" -version = "2.4.1" +version = "2.4.2" [package.dependencies] lazy-object-proxy = ">=1.4.0,<1.5.0" @@ -118,7 +118,7 @@ description = "Python package for providing Mozilla's CA Bundle." name = "certifi" optional = false python-versions = "*" -version = "2020.4.5.1" +version = "2020.6.20" [[package]] category = "main" @@ -171,7 +171,7 @@ description = "Easily serialize dataclasses to and from JSON" name = "dataclasses-json" optional = false python-versions = ">=3.6" -version = "0.4.2" +version = "0.5.1" [package.dependencies] marshmallow = ">=3.3.0,<4.0.0" @@ -214,7 +214,7 @@ description = "the modular source code checker: pep8 pyflakes and co" name = "flake8" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,>=2.7" -version = "3.8.1" +version = "3.8.3" [package.dependencies] mccabe = ">=0.6.0,<0.7.0" @@ -248,14 +248,14 @@ marker = "python_version < \"3.8\"" name = "importlib-metadata" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" -version = "1.6.0" +version = "1.6.1" [package.dependencies] zipp = ">=0.5" [package.extras] docs = ["sphinx", "rst.linker"] -testing = ["packaging", "importlib-resources"] +testing = ["packaging", "pep517", "importlib-resources (>=1.3)"] [[package]] category = "dev" @@ -307,12 +307,12 @@ description = "A lightweight library for converting complex datatypes to and fro name = "marshmallow" optional = false python-versions = ">=3.5" -version = "3.6.0" +version = "3.6.1" [package.extras] -dev = ["pytest", "pytz", "simplejson", "mypy (0.770)", "flake8 (3.7.9)", "flake8-bugbear (20.1.4)", "pre-commit (>=1.20,<3.0)", "tox"] -docs = ["sphinx (3.0.3)", "sphinx-issues (1.2.0)", "alabaster (0.7.12)", "sphinx-version-warning (1.1.2)"] -lint = ["mypy (0.770)", "flake8 (3.7.9)", "flake8-bugbear (20.1.4)", "pre-commit (>=1.20,<3.0)"] +dev = ["pytest", "pytz", "simplejson", "mypy (0.770)", "flake8 (3.8.2)", "flake8-bugbear (20.1.4)", "pre-commit (>=2.4,<3.0)", "tox"] +docs = ["sphinx (3.0.4)", "sphinx-issues (1.2.0)", "alabaster (0.7.12)", "sphinx-version-warning (1.1.2)", "autodocsumm (0.1.13)"] +lint = ["mypy (0.770)", "flake8 (3.8.2)", "flake8-bugbear (20.1.4)", "pre-commit (>=2.4,<3.0)"] tests = ["pytest", "pytz", "simplejson"] [[package]] @@ -340,7 +340,7 @@ description = "More routines for operating on iterables, beyond itertools" name = "more-itertools" optional = false python-versions = ">=3.5" -version = "8.3.0" +version = "8.4.0" [[package]] category = "dev" @@ -348,7 +348,7 @@ description = "Optional static typing for Python" name = "mypy" optional = false python-versions = ">=3.5" -version = "0.770" +version = "0.782" [package.dependencies] mypy-extensions = ">=0.4.3,<0.5.0" @@ -408,7 +408,7 @@ description = "library with cross-python path, ini-parsing, io, code, log facili name = "py" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -version = "1.8.1" +version = "1.8.2" [[package]] category = "dev" @@ -440,7 +440,7 @@ description = "python code static checker" name = "pylint" optional = false python-versions = ">=3.5.*" -version = "2.5.2" +version = "2.5.3" [package.dependencies] astroid = ">=2.4.0,<=2.5" @@ -463,7 +463,7 @@ description = "pytest: simple powerful testing with Python" name = "pytest" optional = false python-versions = ">=3.5" -version = "5.4.2" +version = "5.4.3" [package.dependencies] atomicwrites = ">=1.0" @@ -488,15 +488,15 @@ category = "dev" description = "Pytest plugin for measuring coverage." name = "pytest-cov" optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -version = "2.8.1" +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" +version = "2.10.0" [package.dependencies] coverage = ">=4.4" -pytest = ">=3.6" +pytest = ">=4.6" [package.extras] -testing = ["fields", "hunter", "process-tests (2.0.2)", "six", "virtualenv"] +testing = ["fields", "hunter", "process-tests (2.0.2)", "six", "pytest-xdist", "virtualenv"] [[package]] category = "dev" @@ -551,7 +551,7 @@ description = "Alternative regular expression module, to replace re." name = "regex" optional = false python-versions = "*" -version = "2020.5.14" +version = "2020.6.8" [[package]] category = "main" @@ -559,7 +559,7 @@ description = "Python HTTP for Humans." name = "requests" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" -version = "2.23.0" +version = "2.24.0" [package.dependencies] certifi = ">=2017.4.17" @@ -685,11 +685,11 @@ socks = ["PySocks (>=1.5.6,<1.5.7 || >1.5.7,<2.0)"] [[package]] category = "dev" -description = "Measures number of Terminal column cells of wide-character codes" +description = "Measures the displayed width of unicode strings in a terminal" name = "wcwidth" optional = false python-versions = "*" -version = "0.1.9" +version = "0.2.5" [[package]] category = "dev" @@ -730,8 +730,8 @@ appdirs = [ {file = "appdirs-1.4.4.tar.gz", hash = "sha256:7d5d0167b2b1ba821647616af46a749d1c653740dd0d2415100fe26e27afdf41"}, ] astroid = [ - {file = "astroid-2.4.1-py3-none-any.whl", hash = "sha256:d8506842a3faf734b81599c8b98dcc423de863adcc1999248480b18bd31a0f38"}, - {file = "astroid-2.4.1.tar.gz", hash = "sha256:4c17cea3e592c21b6e222f673868961bad77e1f985cb1694ed077475a89229c1"}, + {file = "astroid-2.4.2-py3-none-any.whl", hash = "sha256:bc58d83eb610252fd8de6363e39d4f1d0619c894b0ed24603b881c02e64c7386"}, + {file = "astroid-2.4.2.tar.gz", hash = "sha256:2f4078c2a41bf377eea06d71c9d2ba4eb8f6b1af2135bec27bbbb7d8f12bb703"}, ] atomicwrites = [ {file = "atomicwrites-1.4.0-py2.py3-none-any.whl", hash = "sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197"}, @@ -757,8 +757,8 @@ black = [ {file = "black-19.10b0.tar.gz", hash = "sha256:c2edb73a08e9e0e6f65a0e6af18b059b8b1cdd5bef997d7a0b181df93dc81539"}, ] certifi = [ - {file = "certifi-2020.4.5.1-py2.py3-none-any.whl", hash = "sha256:1d987a998c75633c40847cc966fcf5904906c920a7f17ef374f5aa4282abd304"}, - {file = "certifi-2020.4.5.1.tar.gz", hash = "sha256:51fcb31174be6e6664c5f69e3e1691a2d72a1a12e90f872cbdb1567eb47b6519"}, + {file = "certifi-2020.6.20-py2.py3-none-any.whl", hash = "sha256:8fc0819f1f30ba15bdb34cceffb9ef04d99f420f68eb75d901e9560b8749fc41"}, + {file = "certifi-2020.6.20.tar.gz", hash = "sha256:5930595817496dd21bb8dc35dad090f1c2cd0adfaf21204bf6732ca5d8ee34d3"}, ] chardet = [ {file = "chardet-3.0.4-py2.py3-none-any.whl", hash = "sha256:fc323ffcaeaed0e0a02bf4d117757b98aed530d9ed4531e3e15460124c106691"}, @@ -810,8 +810,8 @@ dataclasses = [ {file = "dataclasses-0.6.tar.gz", hash = "sha256:6988bd2b895eef432d562370bb707d540f32f7360ab13da45340101bc2307d84"}, ] dataclasses-json = [ - {file = "dataclasses-json-0.4.2.tar.gz", hash = "sha256:65ac9ae2f7ec152ee01bf42c8c024736d4cd6f6fb761502dec92bd553931e3d9"}, - {file = "dataclasses_json-0.4.2-py3-none-any.whl", hash = "sha256:dbb53ebbac30ef45f44f5f436b21bd5726a80a14e1a193958864229100271372"}, + {file = "dataclasses-json-0.5.1.tar.gz", hash = "sha256:6e38b11b178e404124bffd6d213736bc505338e8a4c718596efec8d32eb96f5a"}, + {file = "dataclasses_json-0.5.1-py3-none-any.whl", hash = "sha256:2f5fca4f097f9f9727e2100c824ed48153171186a679487f8875eca8d8c05107"}, ] docutils = [ {file = "docutils-0.16-py2.py3-none-any.whl", hash = "sha256:0c5b78adfbf7762415433f5515cd5c9e762339e23369dbe8000d84a4bf4ab3af"}, @@ -822,8 +822,8 @@ execnet = [ {file = "execnet-1.7.1.tar.gz", hash = "sha256:cacb9df31c9680ec5f95553976c4da484d407e85e41c83cb812aa014f0eddc50"}, ] flake8 = [ - {file = "flake8-3.8.1-py2.py3-none-any.whl", hash = "sha256:6c1193b0c3f853ef763969238f6c81e9e63ace9d024518edc020d5f1d6d93195"}, - {file = "flake8-3.8.1.tar.gz", hash = "sha256:ea6623797bf9a52f4c9577d780da0bb17d65f870213f7b5bcc9fca82540c31d5"}, + {file = "flake8-3.8.3-py2.py3-none-any.whl", hash = "sha256:15e351d19611c887e482fb960eae4d44845013cc142d42896e9862f775d8cf5c"}, + {file = "flake8-3.8.3.tar.gz", hash = "sha256:f04b9fcbac03b0a3e58c0ab3a0ecc462e023a9faf046d57794184028123aa208"}, ] idna = [ {file = "idna-2.9-py2.py3-none-any.whl", hash = "sha256:a068a21ceac8a4d63dbfd964670474107f541babbd2250d61922f029858365fa"}, @@ -834,8 +834,8 @@ imagesize = [ {file = "imagesize-1.2.0.tar.gz", hash = "sha256:b1f6b5a4eab1f73479a50fb79fcf729514a900c341d8503d62a62dbc4127a2b1"}, ] importlib-metadata = [ - {file = "importlib_metadata-1.6.0-py2.py3-none-any.whl", hash = "sha256:2a688cbaa90e0cc587f1df48bdc97a6eadccdcd9c35fb3f976a09e3b5016d90f"}, - {file = "importlib_metadata-1.6.0.tar.gz", hash = "sha256:34513a8a0c4962bc66d35b359558fd8a5e10cd472d37aec5f66858addef32c1e"}, + {file = "importlib_metadata-1.6.1-py2.py3-none-any.whl", hash = "sha256:15ec6c0fd909e893e3a08b3a7c76ecb149122fb14b7efe1199ddd4c7c57ea958"}, + {file = "importlib_metadata-1.6.1.tar.gz", hash = "sha256:0505dd08068cfec00f53a74a0ad927676d7757da81b7436a6eefe4c7cf75c545"}, ] isort = [ {file = "isort-4.3.21-py2.py3-none-any.whl", hash = "sha256:6e811fcb295968434526407adb8796944f1988c5b65e8139058f2014cbe100fd"}, @@ -904,8 +904,8 @@ markupsafe = [ {file = "MarkupSafe-1.1.1.tar.gz", hash = "sha256:29872e92839765e546828bb7754a68c418d927cd064fd4708fab9fe9c8bb116b"}, ] marshmallow = [ - {file = "marshmallow-3.6.0-py2.py3-none-any.whl", hash = "sha256:f88fe96434b1f0f476d54224d59333eba8ca1a203a2695683c1855675c4049a7"}, - {file = "marshmallow-3.6.0.tar.gz", hash = "sha256:c2673233aa21dde264b84349dc2fd1dce5f30ed724a0a00e75426734de5b84ab"}, + {file = "marshmallow-3.6.1-py2.py3-none-any.whl", hash = "sha256:9aa20f9b71c992b4782dad07c51d92884fd0f7c5cb9d3c737bea17ec1bad765f"}, + {file = "marshmallow-3.6.1.tar.gz", hash = "sha256:35ee2fb188f0bd9fc1cf9ac35e45fd394bd1c153cee430745a465ea435514bd5"}, ] marshmallow-enum = [ {file = "marshmallow-enum-1.5.1.tar.gz", hash = "sha256:38e697e11f45a8e64b4a1e664000897c659b60aa57bfa18d44e226a9920b6e58"}, @@ -916,24 +916,24 @@ mccabe = [ {file = "mccabe-0.6.1.tar.gz", hash = "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f"}, ] more-itertools = [ - {file = "more-itertools-8.3.0.tar.gz", hash = "sha256:558bb897a2232f5e4f8e2399089e35aecb746e1f9191b6584a151647e89267be"}, - {file = "more_itertools-8.3.0-py3-none-any.whl", hash = "sha256:7818f596b1e87be009031c7653d01acc46ed422e6656b394b0f765ce66ed4982"}, + {file = "more-itertools-8.4.0.tar.gz", hash = "sha256:68c70cc7167bdf5c7c9d8f6954a7837089c6a36bf565383919bb595efb8a17e5"}, + {file = "more_itertools-8.4.0-py3-none-any.whl", hash = "sha256:b78134b2063dd214000685165d81c154522c3ee0a1c0d4d113c80361c234c5a2"}, ] mypy = [ - {file = "mypy-0.770-cp35-cp35m-macosx_10_6_x86_64.whl", hash = "sha256:a34b577cdf6313bf24755f7a0e3f3c326d5c1f4fe7422d1d06498eb25ad0c600"}, - {file = "mypy-0.770-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:86c857510a9b7c3104cf4cde1568f4921762c8f9842e987bc03ed4f160925754"}, - {file = "mypy-0.770-cp35-cp35m-win_amd64.whl", hash = "sha256:a8ffcd53cb5dfc131850851cc09f1c44689c2812d0beb954d8138d4f5fc17f65"}, - {file = "mypy-0.770-cp36-cp36m-macosx_10_6_x86_64.whl", hash = "sha256:7687f6455ec3ed7649d1ae574136835a4272b65b3ddcf01ab8704ac65616c5ce"}, - {file = "mypy-0.770-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:3beff56b453b6ef94ecb2996bea101a08f1f8a9771d3cbf4988a61e4d9973761"}, - {file = "mypy-0.770-cp36-cp36m-win_amd64.whl", hash = "sha256:15b948e1302682e3682f11f50208b726a246ab4e6c1b39f9264a8796bb416aa2"}, - {file = "mypy-0.770-cp37-cp37m-macosx_10_6_x86_64.whl", hash = "sha256:b90928f2d9eb2f33162405f32dde9f6dcead63a0971ca8a1b50eb4ca3e35ceb8"}, - {file = "mypy-0.770-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:c56ffe22faa2e51054c5f7a3bc70a370939c2ed4de308c690e7949230c995913"}, - {file = "mypy-0.770-cp37-cp37m-win_amd64.whl", hash = "sha256:8dfb69fbf9f3aeed18afffb15e319ca7f8da9642336348ddd6cab2713ddcf8f9"}, - {file = "mypy-0.770-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:219a3116ecd015f8dca7b5d2c366c973509dfb9a8fc97ef044a36e3da66144a1"}, - {file = "mypy-0.770-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:7ec45a70d40ede1ec7ad7f95b3c94c9cf4c186a32f6bacb1795b60abd2f9ef27"}, - {file = "mypy-0.770-cp38-cp38-win_amd64.whl", hash = "sha256:f91c7ae919bbc3f96cd5e5b2e786b2b108343d1d7972ea130f7de27fdd547cf3"}, - {file = "mypy-0.770-py3-none-any.whl", hash = "sha256:3b1fc683fb204c6b4403a1ef23f0b1fac8e4477091585e0c8c54cbdf7d7bb164"}, - {file = "mypy-0.770.tar.gz", hash = "sha256:8a627507ef9b307b46a1fea9513d5c98680ba09591253082b4c48697ba05a4ae"}, + {file = "mypy-0.782-cp35-cp35m-macosx_10_6_x86_64.whl", hash = "sha256:2c6cde8aa3426c1682d35190b59b71f661237d74b053822ea3d748e2c9578a7c"}, + {file = "mypy-0.782-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:9c7a9a7ceb2871ba4bac1cf7217a7dd9ccd44c27c2950edbc6dc08530f32ad4e"}, + {file = "mypy-0.782-cp35-cp35m-win_amd64.whl", hash = "sha256:c05b9e4fb1d8a41d41dec8786c94f3b95d3c5f528298d769eb8e73d293abc48d"}, + {file = "mypy-0.782-cp36-cp36m-macosx_10_6_x86_64.whl", hash = "sha256:6731603dfe0ce4352c555c6284c6db0dc935b685e9ce2e4cf220abe1e14386fd"}, + {file = "mypy-0.782-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:f05644db6779387ccdb468cc47a44b4356fc2ffa9287135d05b70a98dc83b89a"}, + {file = "mypy-0.782-cp36-cp36m-win_amd64.whl", hash = "sha256:b7fbfabdbcc78c4f6fc4712544b9b0d6bf171069c6e0e3cb82440dd10ced3406"}, + {file = "mypy-0.782-cp37-cp37m-macosx_10_6_x86_64.whl", hash = "sha256:3fdda71c067d3ddfb21da4b80e2686b71e9e5c72cca65fa216d207a358827f86"}, + {file = "mypy-0.782-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:d7df6eddb6054d21ca4d3c6249cae5578cb4602951fd2b6ee2f5510ffb098707"}, + {file = "mypy-0.782-cp37-cp37m-win_amd64.whl", hash = "sha256:a4a2cbcfc4cbf45cd126f531dedda8485671545b43107ded25ce952aac6fb308"}, + {file = "mypy-0.782-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:6bb93479caa6619d21d6e7160c552c1193f6952f0668cdda2f851156e85186fc"}, + {file = "mypy-0.782-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:81c7908b94239c4010e16642c9102bfc958ab14e36048fa77d0be3289dda76ea"}, + {file = "mypy-0.782-cp38-cp38-win_amd64.whl", hash = "sha256:5dd13ff1f2a97f94540fd37a49e5d255950ebcdf446fb597463a40d0df3fac8b"}, + {file = "mypy-0.782-py3-none-any.whl", hash = "sha256:e0b61738ab504e656d1fe4ff0c0601387a5489ca122d55390ade31f9ca0e252d"}, + {file = "mypy-0.782.tar.gz", hash = "sha256:eff7d4a85e9eea55afa34888dfeaccde99e7520b51f867ac28a48492c0b1130c"}, ] mypy-extensions = [ {file = "mypy_extensions-0.4.3-py2.py3-none-any.whl", hash = "sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d"}, @@ -952,8 +952,8 @@ pluggy = [ {file = "pluggy-0.13.1.tar.gz", hash = "sha256:15b2acde666561e1298d71b523007ed7364de07029219b604cf808bfa1c765b0"}, ] py = [ - {file = "py-1.8.1-py2.py3-none-any.whl", hash = "sha256:c20fdd83a5dbc0af9efd622bee9a5564e278f6380fffcacc43ba6f43db2813b0"}, - {file = "py-1.8.1.tar.gz", hash = "sha256:5e27081401262157467ad6e7f851b7aa402c5852dbcb3dae06768434de5752aa"}, + {file = "py-1.8.2-py2.py3-none-any.whl", hash = "sha256:a673fa23d7000440cc885c17dbd34fafcb7d7a6e230b29f6766400de36a33c44"}, + {file = "py-1.8.2.tar.gz", hash = "sha256:f3b3a4c36512a4c4f024041ab51866f11761cc169670204b235f6b20523d4e6b"}, ] pycodestyle = [ {file = "pycodestyle-2.6.0-py2.py3-none-any.whl", hash = "sha256:2295e7b2f6b5bd100585ebcb1f616591b652db8a741695b3d8f5d28bdc934367"}, @@ -968,20 +968,20 @@ pygments = [ {file = "Pygments-2.6.1.tar.gz", hash = "sha256:647344a061c249a3b74e230c739f434d7ea4d8b1d5f3721bc0f3558049b38f44"}, ] pylint = [ - {file = "pylint-2.5.2-py3-none-any.whl", hash = "sha256:dd506acce0427e9e08fb87274bcaa953d38b50a58207170dbf5b36cf3e16957b"}, - {file = "pylint-2.5.2.tar.gz", hash = "sha256:b95e31850f3af163c2283ed40432f053acbc8fc6eba6a069cb518d9dbf71848c"}, + {file = "pylint-2.5.3-py3-none-any.whl", hash = "sha256:d0ece7d223fe422088b0e8f13fa0a1e8eb745ebffcb8ed53d3e95394b6101a1c"}, + {file = "pylint-2.5.3.tar.gz", hash = "sha256:7dd78437f2d8d019717dbf287772d0b2dbdfd13fc016aa7faa08d67bccc46adc"}, ] pyparsing = [ {file = "pyparsing-2.4.7-py2.py3-none-any.whl", hash = "sha256:ef9d7589ef3c200abe66653d3f1ab1033c3c419ae9b9bdb1240a85b024efc88b"}, {file = "pyparsing-2.4.7.tar.gz", hash = "sha256:c203ec8783bf771a155b207279b9bccb8dea02d8f0c9e5f8ead507bc3246ecc1"}, ] pytest = [ - {file = "pytest-5.4.2-py3-none-any.whl", hash = "sha256:95c710d0a72d91c13fae35dce195633c929c3792f54125919847fdcdf7caa0d3"}, - {file = "pytest-5.4.2.tar.gz", hash = "sha256:eb2b5e935f6a019317e455b6da83dd8650ac9ffd2ee73a7b657a30873d67a698"}, + {file = "pytest-5.4.3-py3-none-any.whl", hash = "sha256:5c0db86b698e8f170ba4582a492248919255fcd4c79b1ee64ace34301fb589a1"}, + {file = "pytest-5.4.3.tar.gz", hash = "sha256:7979331bfcba207414f5e1263b5a0f8f521d0f457318836a7355531ed1a4c7d8"}, ] pytest-cov = [ - {file = "pytest-cov-2.8.1.tar.gz", hash = "sha256:cc6742d8bac45070217169f5f72ceee1e0e55b0221f54bcf24845972d3a47f2b"}, - {file = "pytest_cov-2.8.1-py2.py3-none-any.whl", hash = "sha256:cdbdef4f870408ebdbfeb44e63e07eb18bb4619fae852f6e760645fa36172626"}, + {file = "pytest-cov-2.10.0.tar.gz", hash = "sha256:1a629dc9f48e53512fcbfda6b07de490c374b0c83c55ff7a1720b3fccff0ac87"}, + {file = "pytest_cov-2.10.0-py2.py3-none-any.whl", hash = "sha256:6e6d18092dce6fad667cd7020deed816f858ad3b49d5b5e2b1cc1c97a4dba65c"}, ] pytest-forked = [ {file = "pytest-forked-1.1.3.tar.gz", hash = "sha256:1805699ed9c9e60cb7a8179b8d4fa2b8898098e82d229b0825d8095f0f261100"}, @@ -1000,31 +1000,31 @@ pytz = [ {file = "pytz-2020.1.tar.gz", hash = "sha256:c35965d010ce31b23eeb663ed3cc8c906275d6be1a34393a1d73a41febf4a048"}, ] regex = [ - {file = "regex-2020.5.14-cp27-cp27m-win32.whl", hash = "sha256:e565569fc28e3ba3e475ec344d87ed3cd8ba2d575335359749298a0899fe122e"}, - {file = "regex-2020.5.14-cp27-cp27m-win_amd64.whl", hash = "sha256:d466967ac8e45244b9dfe302bbe5e3337f8dc4dec8d7d10f5e950d83b140d33a"}, - {file = "regex-2020.5.14-cp36-cp36m-manylinux1_i686.whl", hash = "sha256:27ff7325b297fb6e5ebb70d10437592433601c423f5acf86e5bc1ee2919b9561"}, - {file = "regex-2020.5.14-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:ea55b80eb0d1c3f1d8d784264a6764f931e172480a2f1868f2536444c5f01e01"}, - {file = "regex-2020.5.14-cp36-cp36m-manylinux2010_i686.whl", hash = "sha256:c9bce6e006fbe771a02bda468ec40ffccbf954803b470a0345ad39c603402577"}, - {file = "regex-2020.5.14-cp36-cp36m-manylinux2010_x86_64.whl", hash = "sha256:d881c2e657c51d89f02ae4c21d9adbef76b8325fe4d5cf0e9ad62f850f3a98fd"}, - {file = "regex-2020.5.14-cp36-cp36m-win32.whl", hash = "sha256:99568f00f7bf820c620f01721485cad230f3fb28f57d8fbf4a7967ec2e446994"}, - {file = "regex-2020.5.14-cp36-cp36m-win_amd64.whl", hash = "sha256:70c14743320a68c5dac7fc5a0f685be63bc2024b062fe2aaccc4acc3d01b14a1"}, - {file = "regex-2020.5.14-cp37-cp37m-manylinux1_i686.whl", hash = "sha256:a7c37f048ec3920783abab99f8f4036561a174f1314302ccfa4e9ad31cb00eb4"}, - {file = "regex-2020.5.14-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:89d76ce33d3266173f5be80bd4efcbd5196cafc34100fdab814f9b228dee0fa4"}, - {file = "regex-2020.5.14-cp37-cp37m-manylinux2010_i686.whl", hash = "sha256:51f17abbe973c7673a61863516bdc9c0ef467407a940f39501e786a07406699c"}, - {file = "regex-2020.5.14-cp37-cp37m-manylinux2010_x86_64.whl", hash = "sha256:ce5cc53aa9fbbf6712e92c7cf268274eaff30f6bd12a0754e8133d85a8fb0f5f"}, - {file = "regex-2020.5.14-cp37-cp37m-win32.whl", hash = "sha256:8044d1c085d49673aadb3d7dc20ef5cb5b030c7a4fa253a593dda2eab3059929"}, - {file = "regex-2020.5.14-cp37-cp37m-win_amd64.whl", hash = "sha256:c2062c7d470751b648f1cacc3f54460aebfc261285f14bc6da49c6943bd48bdd"}, - {file = "regex-2020.5.14-cp38-cp38-manylinux1_i686.whl", hash = "sha256:329ba35d711e3428db6b45a53b1b13a0a8ba07cbbcf10bbed291a7da45f106c3"}, - {file = "regex-2020.5.14-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:579ea215c81d18da550b62ff97ee187b99f1b135fd894a13451e00986a080cad"}, - {file = "regex-2020.5.14-cp38-cp38-manylinux2010_i686.whl", hash = "sha256:3a9394197664e35566242686d84dfd264c07b20f93514e2e09d3c2b3ffdf78fe"}, - {file = "regex-2020.5.14-cp38-cp38-manylinux2010_x86_64.whl", hash = "sha256:ce367d21f33e23a84fb83a641b3834dd7dd8e9318ad8ff677fbfae5915a239f7"}, - {file = "regex-2020.5.14-cp38-cp38-win32.whl", hash = "sha256:1386e75c9d1574f6aa2e4eb5355374c8e55f9aac97e224a8a5a6abded0f9c927"}, - {file = "regex-2020.5.14-cp38-cp38-win_amd64.whl", hash = "sha256:7e61be8a2900897803c293247ef87366d5df86bf701083b6c43119c7c6c99108"}, - {file = "regex-2020.5.14.tar.gz", hash = "sha256:ce450ffbfec93821ab1fea94779a8440e10cf63819be6e176eb1973a6017aff5"}, + {file = "regex-2020.6.8-cp27-cp27m-win32.whl", hash = "sha256:fbff901c54c22425a5b809b914a3bfaf4b9570eee0e5ce8186ac71eb2025191c"}, + {file = "regex-2020.6.8-cp27-cp27m-win_amd64.whl", hash = "sha256:112e34adf95e45158c597feea65d06a8124898bdeac975c9087fe71b572bd938"}, + {file = "regex-2020.6.8-cp36-cp36m-manylinux1_i686.whl", hash = "sha256:92d8a043a4241a710c1cf7593f5577fbb832cf6c3a00ff3fc1ff2052aff5dd89"}, + {file = "regex-2020.6.8-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:bae83f2a56ab30d5353b47f9b2a33e4aac4de9401fb582b55c42b132a8ac3868"}, + {file = "regex-2020.6.8-cp36-cp36m-manylinux2010_i686.whl", hash = "sha256:b2ba0f78b3ef375114856cbdaa30559914d081c416b431f2437f83ce4f8b7f2f"}, + {file = "regex-2020.6.8-cp36-cp36m-manylinux2010_x86_64.whl", hash = "sha256:95fa7726d073c87141f7bbfb04c284901f8328e2d430eeb71b8ffdd5742a5ded"}, + {file = "regex-2020.6.8-cp36-cp36m-win32.whl", hash = "sha256:e3cdc9423808f7e1bb9c2e0bdb1c9dc37b0607b30d646ff6faf0d4e41ee8fee3"}, + {file = "regex-2020.6.8-cp36-cp36m-win_amd64.whl", hash = "sha256:c78e66a922de1c95a208e4ec02e2e5cf0bb83a36ceececc10a72841e53fbf2bd"}, + {file = "regex-2020.6.8-cp37-cp37m-manylinux1_i686.whl", hash = "sha256:08997a37b221a3e27d68ffb601e45abfb0093d39ee770e4257bd2f5115e8cb0a"}, + {file = "regex-2020.6.8-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:2f6f211633ee8d3f7706953e9d3edc7ce63a1d6aad0be5dcee1ece127eea13ae"}, + {file = "regex-2020.6.8-cp37-cp37m-manylinux2010_i686.whl", hash = "sha256:55b4c25cbb3b29f8d5e63aeed27b49fa0f8476b0d4e1b3171d85db891938cc3a"}, + {file = "regex-2020.6.8-cp37-cp37m-manylinux2010_x86_64.whl", hash = "sha256:89cda1a5d3e33ec9e231ece7307afc101b5217523d55ef4dc7fb2abd6de71ba3"}, + {file = "regex-2020.6.8-cp37-cp37m-win32.whl", hash = "sha256:690f858d9a94d903cf5cada62ce069b5d93b313d7d05456dbcd99420856562d9"}, + {file = "regex-2020.6.8-cp37-cp37m-win_amd64.whl", hash = "sha256:1700419d8a18c26ff396b3b06ace315b5f2a6e780dad387e4c48717a12a22c29"}, + {file = "regex-2020.6.8-cp38-cp38-manylinux1_i686.whl", hash = "sha256:654cb773b2792e50151f0e22be0f2b6e1c3a04c5328ff1d9d59c0398d37ef610"}, + {file = "regex-2020.6.8-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:52e1b4bef02f4040b2fd547357a170fc1146e60ab310cdbdd098db86e929b387"}, + {file = "regex-2020.6.8-cp38-cp38-manylinux2010_i686.whl", hash = "sha256:cf59bbf282b627130f5ba68b7fa3abdb96372b24b66bdf72a4920e8153fc7910"}, + {file = "regex-2020.6.8-cp38-cp38-manylinux2010_x86_64.whl", hash = "sha256:5aaa5928b039ae440d775acea11d01e42ff26e1561c0ffcd3d805750973c6baf"}, + {file = "regex-2020.6.8-cp38-cp38-win32.whl", hash = "sha256:97712e0d0af05febd8ab63d2ef0ab2d0cd9deddf4476f7aa153f76feef4b2754"}, + {file = "regex-2020.6.8-cp38-cp38-win_amd64.whl", hash = "sha256:6ad8663c17db4c5ef438141f99e291c4d4edfeaacc0ce28b5bba2b0bf273d9b5"}, + {file = "regex-2020.6.8.tar.gz", hash = "sha256:e9b64e609d37438f7d6e68c2546d2cb8062f3adb27e6336bc129b51be20773ac"}, ] requests = [ - {file = "requests-2.23.0-py2.py3-none-any.whl", hash = "sha256:43999036bfa82904b6af1d99e4882b560e5e2c68e5c4b0aa03b655f3d7d73fee"}, - {file = "requests-2.23.0.tar.gz", hash = "sha256:b3f43d496c6daba4493e7c431722aeb7dbc6288f52a6e04e7b6023b0247817e6"}, + {file = "requests-2.24.0-py2.py3-none-any.whl", hash = "sha256:fe75cc94a9443b9246fc7049224f75604b113c36acb93f87b80ed42c44cbb898"}, + {file = "requests-2.24.0.tar.gz", hash = "sha256:b3559a131db72c33ee969480840fff4bb6dd111de7dd27c8ee1f820f4f00231b"}, ] six = [ {file = "six-1.15.0-py2.py3-none-any.whl", hash = "sha256:8b74bedcbbbaca38ff6d7491d76f2b06b3592611af620f8426e82dddb04a5ced"}, @@ -1087,8 +1087,8 @@ urllib3 = [ {file = "urllib3-1.25.9.tar.gz", hash = "sha256:3018294ebefce6572a474f0604c2021e33b3fd8006ecd11d62107a5d2a963527"}, ] wcwidth = [ - {file = "wcwidth-0.1.9-py2.py3-none-any.whl", hash = "sha256:cafe2186b3c009a04067022ce1dcd79cb38d8d65ee4f4791b8888d6599d1bbe1"}, - {file = "wcwidth-0.1.9.tar.gz", hash = "sha256:ee73862862a156bf77ff92b09034fc4825dd3af9cf81bc5b360668d425f3c5f1"}, + {file = "wcwidth-0.2.5-py2.py3-none-any.whl", hash = "sha256:beb4802a9cebb9144e99086eff703a642a13d6a0052920003a230f3294bbe784"}, + {file = "wcwidth-0.2.5.tar.gz", hash = "sha256:c4d647b99872929fdb7bdcaa4fbe7f01413ed3d98077df798530e5b04f116c83"}, ] wrapt = [ {file = "wrapt-1.12.1.tar.gz", hash = "sha256:b62ffa81fb85f4332a4f609cab4ac40709470da05643a082ec1eb88e6d9b97d7"}, diff --git a/pyproject.toml b/pyproject.toml index cfa23a99..88ea9847 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "annofabapi" -version = "0.33.1" +version = "0.34.0" description = "Python Clinet Library of AnnoFab WebAPI (https://annofab.com/docs/api/)" authors = ["yuji38kwmt "] maintainers = ["yuji38kwmt "]