importTemplate
- 印刷する
- PDF
importTemplate
- 印刷する
- PDF
Article Summary
Share feedback
Thanks for sharing your feedback!
ユーザーがJsonで作成したテンプレート構造ファイルをインポートします。
POST https://{endpoint}/template/import
リクエスト
リクエストパラメータ
パラメータ名 | 必須 | タイプ | 制約事項 | 説明 |
---|---|---|---|---|
file | Yes | File | importするJsonファイル(Jsonに重複などの不具合が発生することがある場合、当該不具合発生直前までのみ追加され、その後は追加されない。) |
レスポンス
HTTPステータスレコード | 説明 |
---|---|
201 | テンプレートimport済み |
400 | 認証失敗、間違ったリクエスト |
500 | サーバエラー |
例示
リクエスト
POST https://mail.apigw.ntruss.com/api/v1/template/import
Content-Type: multipart/form-data; boundary=----WebKitFormBoundarysvwDAQeQdwkAw4RS
------WebKitFormBoundarysvwDAQeQdwkAw4RS
Content-Disposition: form-data; name="file"; filename="template_20200513180659.json"
Content-Type: application/json
------WebKitFormBoundarysvwDAQeQdwkAw4RS--
レスポンス
{
"contents": [
{
"sid": 268,
"parentSid": -1,
"createDate": {
"utc": 1589358238711,
"formattedDate": "2020-05-13",
"formattedDateTime": "2020-05-13 17:23:58 711"
},
"name": "AD",
"isCategory": true,
"isUse": true,
"subCategories": [],
"templates": [
{
"sid": 269,
"parentSid": 268,
"createDate": {
"utc": 1589360814507,
"formattedDate": "2020-05-13",
"formattedDateTime": "2020-05-13 18:06:54 507"
},
"name": "AD_Template",
"isCategory": false,
"isUse": true,
"subCategories": null,
"templates": null
}
]
},
{
"sid": 270,
"parentSid": -1,
"createDate": {
"utc": 1589361807385,
"formattedDate": "2020-05-13",
"formattedDateTime": "2020-05-13 18:23:27 385"
},
"name": "Nomal",
"isCategory": true,
"isUse": true,
"subCategories": [],
"templates": [
{
"sid": 271,
"parentSid": 270,
"createDate": {
"utc": 1589361807394,
"formattedDate": "2020-05-13",
"formattedDateTime": "2020-05-13 18:23:27 394"
},
"name": "Nomal_Template",
"isCategory": false,
"isUse": true,
"subCategories": null,
"templates": null
}
]
},
{
"sid": 272,
"parentSid": -1,
"createDate": {
"utc": 1589365172274,
"formattedDate": "2020-05-13",
"formattedDateTime": "2020-05-13 19:19:32 274"
},
"name": "ETC",
"isCategory": true,
"isUse": true,
"subCategories": null,
"templates": null
}
]
}
属性
項目 | 必須 | タイプ | 制約事項 | 説明 |
---|---|---|---|---|
contents | No | List<TemplateStructureResponse> | テンプレート·カテゴリの詳細構造 |
エラーコード
HTTP Status Code | リターンコード | レスポンスメッセージ |
---|---|---|
400 | 77101 | ログイン情報のエラー |
400 | 77102 | BAD_REQUEST |
400 | 77103 | リソースが存在しない |
403 | 77201 | 権限なし |
403 | 77202 | Email商品の利用申込をしていない |
405 | 77001 | METHOD_NOT_ALLOWED |
415 | 77002 | UNSUPPORTED_MEDIA_TYPE |
500 | 77301 | 基本プロジェクトが存在しない |
500 | 77302 | 外部システムAPIの連動エラー |
500 | 77303 | その他のINTERNAL_SERVER_ERROR |
この記事は役に立ちましたか?