Zum Hauptinhalt springen
POST
/
cms
/
v3
/
source-code
/
{environment}
/
content
/
{path}
ファイルを作成
curl --request POST \
  --url https://api.hubapi.com/cms/v3/source-code/{environment}/content/{path} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form file=@example-file
{
  "createdAt": 123,
  "archivedAt": 123,
  "folder": true,
  "children": [
    "<string>"
  ],
  "name": "<string>",
  "id": "<string>",
  "hash": "<string>",
  "updatedAt": 123
}
次のいずれかの製品またはそれ以上が必要です。
Marketing HubMarketing Hub -無料ツール
Sales HubSales Hub -無料ツール
Service HubService Hub -無料ツール
Content HubContent Hub -無料ツール
この API には、次のいずれかのスコープが必要です。
content

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

environment
string
required

ファイルの環境(「下書き」または「公開済み」)。

path
string
required

ファイルのファイルシステムでの位置。

Body

multipart/form-data
file
file

Response

successful operation

createdAt
integer
required

オブジェクトが最初に作成された時点のタイムスタンプ。

folder
boolean
required

このパスがフォルダーを参照するかどうかが決定されます。

name
string
required

ファイルの名前。

id
string
required

CMS開発者ファイルシステムにおけるファイルのパス。

updatedAt
integer
required

オブジェクトが最後に更新された時点のタイムスタンプ。

archivedAt
integer

オブジェクトがアーカイブ(削除)された時点のタイムスタンプ。

children
string[]

オブジェクトがフォルダーの場合は、フォルダー内のファイルのファイル名が含まれます。

hash
string
I