Code2Des Status 取得
メソッド
この API は REST methodology に従います。
HTTP メソッド
GET: Code2Des status を取得
命名規則
Response JSON は、他の PostgreSQL lifecycle endpoint と同じ camelCase を使用します。
リクエストとレスポンス
ヘッダー
リクエストヘッダー
AuthorizationAcceptAccept-language
レスポンスヘッダー
Content-Type
Code2Des Status 取得
URI
パスパラメータ
| 名前 | 型 | 必須 | 説明 |
|---|---|---|---|
| organization_id | integer | 必須 | Organization ID |
| project_id | integer | 必須 | Project ID |
| code2des_id | string | 必須 | Code2Des UUID |
リクエストボディ
なし。
レスポンス
Response は JSON(HTTP status: 200 OK)です。
{
"code2desId": "019ffa75-01c0-75a2-8123-456789abcdf0",
"pageImportId": "019ffa75-01c0-75a2-8123-456789abcdef",
"organizationId": 1,
"projectId": 7,
"figmaFileKey": "aBc123",
"screenId": "homepage",
"placementTarget": null,
"status": "1",
"attempt": 1,
"resultUrl": "s3://bucket/1/7/code2des/019ffa75-01c0-75a2-8123-456789abcdf0/result.json",
"warningCount": 2,
"error": null,
"materializedAt": null,
"materializedNodeId": null,
"createdAt": "2026-08-20T00:00:00.000Z",
"updatedAt": "2026-08-20T01:00:00.000Z"
}
レスポンスフィールド
| 名前 | 型 | 説明 |
|---|---|---|
| code2desId | string | Job UUID と polling key。 |
| pageImportId | string | Source として使用した再利用可能な completed Page Import。 |
| organizationId / projectId | integer | Tenant scope。 |
| figmaFileKey | string | Plugin discovery に使用する target Figma file。 |
| screenId | string | Generated screen identity。 |
| placementTarget | string | null | 任意の initial Figma placement context。 |
| status | string | "0" processing、"1" completed、"2" failed。 |
| attempt | integer | Worker attempt fence。現在は 1。 |
| resultUrl | string | null | Backend artifact pointer。Client は直接読まず result endpoint を使用。 |
| warningCount | integer | null | Deterministic conversion warning count。 |
| error | string | null | Client に公開可能な terminal failure detail。 |
| materializedAt | string | null | 最初の成功 Figma placement timestamp。 |
| materializedNodeId | string | null | 最初に作成成功した Figma root ID。 |
| createdAt / updatedAt | string | ISO 8601 audit timestamp。 |
Status Code
| 値 | 意味 |
|---|---|
"0" |
processing |
"1" |
completed |
"2" |
failed |
データソース
全 field は scope 内かつ non-deleted の PostgreSQL code2des row から取得します。これは lightweight control-plane polling endpoint であり、生成 artifact や image asset は download しません。
status: "1" を確認した後、Code2Des Result 取得を使用します。これは WF2Des/Code2WF と同じ status/result separation です。
認証
Amazon Cognito JWT で認証し、project の Read access が必要です。
エラーハンドリング
| 説明 | Status Code | Status 名 |
|---|---|---|
| Authentication credential がない | 401 | Unauthorized |
| Scope 内・認可済み・non-deleted の Code2Des row がない | 404 | Not Found |
| Internal database error | 500 | Internal Server Error |
処理フロー
- Authenticate し、Read access を検証します。
- Organization、project、ID で non-deleted Code2Des row を取得します。
- S3 を読まずに lifecycle と artifact-pointer metadata を返します。