API 一覧
用語と「永続化」の扱い
- 本ページでは、変換定義を 「マッピングセッティングプロファイル」(拡張子:
.frumap)、定義一式(ZIP)を 「マッピングパック」 と表記します。 - 「永続化」 は文脈ごとに保存先が異なります。
- Definition(定義系):マッピングパック/プロファイルを設定DBに保存=「永続化(Definition)」。
- Excute(実行系):変換されたFHIRリソースをリソースDBに保存=「永続化(Excute)」 。
特定のインタラクションと関係しないエラー
| No | Interaction | Remarks | summary | operation | expectation HTTP status | expectation Response Body |
|---|---|---|---|---|---|---|
| 1 | (対応されていないインタラクション) | リクエストが不正である | 対応されていないインタラクションを実行する | 400 Bad Request | ||
| 2 | (インタラクションは無関係) | サーバエラー | ※500 Internal Server Error を起こす場合 AP サーバの異常時にインタラクションを実行する | 5XX |
マッピングパック永続化(Definition)
機能説明:マッピングパックをFRUCtoS設定DBに**永続化(保存)**するAPI群です。
GET
一覧取得
- 保存済マッピングパックの 一覧(Bundle) を返す。
GET [base]/csv-plugin/definition
| No | Interaction | Remarks | summary | operation | expectation HTTP status | expectation Response Body |
|---|---|---|---|---|---|---|
| 1 | GET [base]/csv-plugin/definition | 基本形 オプションパラメータ無し | 200 OK | Bundle |
取得(パック単位)
- 指定の [mappingPackName] を取得。
- バリデーションエラー:400、未検出:404。
GET [base]/csv-plugin/definition/[mappingPackName]
| No | Interaction | Remarks | summary | operation | expectation HTTP status | expectation Response Body |
|---|---|---|---|---|---|---|
| 1 | GET [base]/csv-plugin/definition/[mappingPackName] | 基本形 オプションパラメータ無し | [mappingPackName]に存在するリソースのマッピングパック名を指定する | 200 OK | List | |
| 2 | GET [base]/csv-plugin/definition/[mappingPackName] | リクエストが不正である | バリデーションルールに違反するマッピングパック名を指定する | 400 Bad Request | OperationOutcome | |
| 3 | GET [base]/csv-plugin/definition/[mappingPackName] | 未検出 | [mappingPackName]に存在しないリソースのマッピングパック 名を指定する | 404 Not Found | OperationOutcome |
取得(パック内プロファイル単位・?path=任意)
- パック内の特定マッピングプロファイル(必要に応じてファイルパスを指定)を取得。
- 典型的なエラー:重複、パス不正、未検出。
GET [base]/csv-plugin/definition/[mappingPackName]/[mappingProfileName] {?path=[mappingFilePath]}
| No | Interaction | Remarks | summary | operation | expectation HTTP status | expectation Response Body |
|---|---|---|---|---|---|---|
| 1 | GET [base]/csv-plugin/definition/[mappingPackName]/[mappingProfileName] | 基本形 オプションパラメータ無し | [mappingPackName]に存在するリソースのマッピングパック名を指定する [mappingProfileName]に[mappingPackName]内に存在するリソースのマッピングプロファイル名を指定する | 200 OK | Basic | |
| 2 | GET [base]/csv-plugin/definition/[mappingPackName]/[mappingProfileName]?path=[mappingFilePath] | path指定 | [mappingPackName]に存在するリソースのマッピングパック名を指定する [mappingProfileName]に[mappingPackName]内に存在するリソースのマッピングプロファイル名を指定する [mappingFilePath]にマッピングパック内definitionからの拡張子付き相対パスを指定する | 200 OK | Basic | |
| 3 | GET [base]/csv-plugin/definition/[mappingPackName]/[mappingProfileName] | リクエストが不正である | バリデーションルールに違反するマッピングパック名またはマッピングプロファイル名を指定する | 400 Bad Request | OperationOutcome | |
| 4 | GET [base]/csv-plugin/definition/[mappingPackName]/[mappingProfileName] | 重複 | [mappingPackName]内に[mappingProfileName]で指定したリソースが複数存在する | 400 Bad Request | OperationOutcome | |
| 5 | GET [base]/csv-plugin/definition/[mappingPackName]/[mappingProfileName]?path=[mappingFilePath] | pathパラメータ不正 | バリデーションルールに違反するマッピングパック名またはマッピングプロファイル名、マッピングプロファイルのパスを指定する | 400 Bad Request | OperationOutcome | |
| 6 | GET [base]/csv-plugin/definition/[mappingPackName]/[mappingProfileName] | 未検出 | [mappingPackName]に存在しないリソースのマッピングパック名を指定する [mappingProfileName]に[mappingPackName]内に存在しないリソースのマッピングプロファイル名を指定する | 404 Not Found | OperationOutcome | |
| 7 | GET [base]/csv-plugin/definition/[mappingPackName]/[mappingProfileName]?path=[mappingFilePath] | 未検出 | [mappingPackName]に存在しないリソースのマッピングパック名を指定する [mappingProfileName]に[mappingPackName]内に存在しないリソースのマッピングプロファイル名を指定する [mappingFilePath]に存在しないパスを指定する | 404 Not Found | OperationOutcome |
POST
登録(保存)
- definition/ を含むZIPをBase64で送信し、設定DBに保存。
- 同名パックがすでに存在:重複エラー、request body空:400。
POST [base]/csv-plugin/definition/[mappingPackName]
| No | Interaction | Remarks | summary | operation | expectation HTTP status | expectation Response Body |
|---|---|---|---|---|---|---|
| 1 | POST [base]/csv-plugin/definition/[mappingPackName] | definition以下が設定DBに永続化される | 基本形 オプションパラメータ無し | [mappingPackName]に存在しないリソースのマッピングパック名を指定する request bodyに登録するZIP圧縮されたマッピングパックをBASE64エンコードしたものをセットする | 201 Created | List |
| 2 | POST [base]/csv-plugin/definition/[mappingPackName] | リクエストが不正である | request bodyが空 | 400 Bad Request | OperationOutcome | |
| 3 | POST [base]/csv-plugin/definition/[mappingPackName] | リクエストが不正である | バリデーションルールに違反するマッピングパック名を指定する | 400 Bad Request | OperationOutcome | |
| 4 | POST [base]/csv-plugin/definition/[mappingPackName] | 重複 | [mappingPackName]に存在するリソースのマッピングパック名を指定する | 400 Bad Request | OperationOutcome |
PUT
更新(未実装)
PUT [base]/csv-plugin/definition/[mappingPackName]
| No | Interaction | Remarks | summary | operation | expectation HTTP status | expectation Response Body |
|---|---|---|---|---|---|---|
| 1 | PUT [base]/csv-plugin/definition/[mappingPackName] | 未実装 | 基本形 オプションパラメータ無し | [mappingPackName]に存在しないリソースのマッピングパック名を指定する request bodyに更新するZIP圧縮されたマッピングパックをBASE64エンコードしたものをセットする | 200 OK | List |
DELETE
削除
- 指定マッピングパック(配下のプロファイルを含む)を設定DBから削除。
- バリデーションエラー:400、未検出:404。
DELETE [base]/csv-plugin/definition/[mappingPackName]
| No | Interaction | Remarks | summary | operation | expectation HTTP status | expectation Response Body |
|---|---|---|---|---|---|---|
| 1 | DELETE [base]/csv-plugin/definition/[mappingPackName] | 指定したマッピングパック内の全マッピングプロファイルも削除される | 基本形 オプションパラメータ無し | [mappingPackName]に存在するリソースのマッピングパック名を指定する | 200 OK | OperationOutcome |
| 2 | DELETE [base]/csv-plugin/definition/[mappingPackName] | リクエストが不正である | バリデーションルールに違反するマッピングパック名を指定する | 400 Bad Request | OperationOutcome | |
| 3 | DELETE [base]/csv-plugin/definition/[mappingPackName] | 未検出 | [mappingPackName]に存在しないリソースのマッ ピングパック名を指定する | 404 Not Found | OperationOutcome |
FHIRリソース変換(Excute)
機能説明:マッピングパックの変換定義に従って入力ファイルをFHIRリソースに変換し、変換されたFHIRリソースをFRUCtoSのリソースDBに永続化します。
POST
ワンショット実行(入力と変換を同時に送る)
- input/ とdefinition/ を含むZIPをBase64で送って実行。拡張子(
.frumap)はURIに付けない。 - 成功:200(Bundle:検索URLあり)、失敗:OperationOutcome。
- 代表的エラー:request body空(400)request body空(400)、命名規則違反(400)、指定プロファイル未検出(500)。
POST [base]/csv-plugin/execute/[mappingProfileName]
| No | Interaction | Remarks | summary | operation | expectation HTTP status | expectation Response Body |
|---|---|---|---|---|---|---|
| 1 | POST [base]/csv-plugin/execute/[mappingProfileName] | 変換したリソースはBundle内URLから確認可能 | 基本形 オプションパラメータ無し | [mappingProfileName]にマッピングパック内に存在するマッピングプロファイル名を指定する request bodyに実行するZIP圧縮されたマッピングパックをBASE64エンコードしたものをセットする | 200 OK | Bundle |
| 2 | POST [base]/csv-plugin/execute/[mappingProfileName] | リクエストが不正である | request bodyが空 | 400 Bad Request | OperationOutcome | |
| 3 | POST [base]/csv-plugin/execute/[mappingProfileName] | リクエストが不正である | バリデーションルールに違反するマッピングパック名を指定する | 400 Bad Request | OperationOutcome | |
| 4 | POST [base]/csv-plugin/execute/[mappingProfileName] | 未検出 | [mappingProfileName]にマッピングパック内に存在しないマッピングプロファイル名を指定する | 500 Internal Server Error | OperationOutcome | |
| 5 | POST [base]/csv-plugin/execute/[mappingProfileName] | 変換失敗 | FHIRリソースへの変換に失敗した場合 変換不能な入力や変換定義を使用する | 500 Internal Server Error | OperationOutcome |