curl --request POST \
--url https://api.hubapi.com/marketing/v3/marketing-events/events/upsert \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"inputs": [
{
"customProperties": [
{
"dataSensitivity": "high",
"isEncrypted": true,
"isLargeValue": true,
"name": "<string>",
"persistenceTimestamp": 123,
"requestId": "<string>",
"selectedByUser": true,
"selectedByUserTimestamp": 123,
"source": "ACADEMY",
"sourceId": "<string>",
"sourceLabel": "<string>",
"sourceMetadata": "<string>",
"sourceUpstreamDeployable": "<string>",
"sourceVid": [
123
],
"timestamp": 123,
"unit": "<string>",
"updatedByUserId": 123,
"useTimestampAsPersistenceTimestamp": true,
"value": "<string>"
}
],
"eventName": "<string>",
"eventOrganizer": "<string>",
"externalAccountId": "<string>",
"externalEventId": "<string>",
"endDateTime": "2023-11-07T05:31:56Z",
"eventCancelled": true,
"eventCompleted": true,
"eventDescription": "<string>",
"eventType": "<string>",
"eventUrl": "<string>",
"startDateTime": "2023-11-07T05:31:56Z"
}
]
}
'{
"completedAt": "2023-11-07T05:31:56Z",
"results": [
{
"createdAt": "2023-11-07T05:31:56Z",
"customProperties": [
{
"dataSensitivity": "high",
"isEncrypted": true,
"isLargeValue": true,
"name": "<string>",
"persistenceTimestamp": 123,
"requestId": "<string>",
"selectedByUser": true,
"selectedByUserTimestamp": 123,
"source": "ACADEMY",
"sourceId": "<string>",
"sourceLabel": "<string>",
"sourceMetadata": "<string>",
"sourceUpstreamDeployable": "<string>",
"sourceVid": [
123
],
"timestamp": 123,
"unit": "<string>",
"updatedByUserId": 123,
"useTimestampAsPersistenceTimestamp": true,
"value": "<string>"
}
],
"eventName": "<string>",
"eventOrganizer": "<string>",
"id": "<string>",
"updatedAt": "2023-11-07T05:31:56Z",
"endDateTime": "2023-11-07T05:31:56Z",
"eventCancelled": true,
"eventCompleted": true,
"eventDescription": "<string>",
"eventType": "<string>",
"eventUrl": "<string>",
"objectId": "<string>",
"startDateTime": "2023-11-07T05:31:56Z"
}
],
"startedAt": "2023-11-07T05:31:56Z",
"status": "CANCELED",
"errors": [
{
"category": "<string>",
"context": {},
"errors": [
{
"message": "<string>",
"code": "<string>",
"context": "{missingScopes=[scope1, scope2]}",
"in": "<string>",
"subCategory": "<string>"
}
],
"links": {},
"message": "<string>",
"status": "<string>",
"id": "<string>",
"subCategory": {}
}
],
"links": {},
"numErrors": 123,
"requestedAt": "2023-11-07T05:31:56Z"
}複数のマーケティングイベントを更新/挿入します。指定されたIDのマーケティングイベントがすでに存在する場合は、更新されます。存在しない場合は、新しいイベントが作成されます。
更新できるのは、同じアプリで最初に作成されたマーケティングイベントのみです。
curl --request POST \
--url https://api.hubapi.com/marketing/v3/marketing-events/events/upsert \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"inputs": [
{
"customProperties": [
{
"dataSensitivity": "high",
"isEncrypted": true,
"isLargeValue": true,
"name": "<string>",
"persistenceTimestamp": 123,
"requestId": "<string>",
"selectedByUser": true,
"selectedByUserTimestamp": 123,
"source": "ACADEMY",
"sourceId": "<string>",
"sourceLabel": "<string>",
"sourceMetadata": "<string>",
"sourceUpstreamDeployable": "<string>",
"sourceVid": [
123
],
"timestamp": 123,
"unit": "<string>",
"updatedByUserId": 123,
"useTimestampAsPersistenceTimestamp": true,
"value": "<string>"
}
],
"eventName": "<string>",
"eventOrganizer": "<string>",
"externalAccountId": "<string>",
"externalEventId": "<string>",
"endDateTime": "2023-11-07T05:31:56Z",
"eventCancelled": true,
"eventCompleted": true,
"eventDescription": "<string>",
"eventType": "<string>",
"eventUrl": "<string>",
"startDateTime": "2023-11-07T05:31:56Z"
}
]
}
'{
"completedAt": "2023-11-07T05:31:56Z",
"results": [
{
"createdAt": "2023-11-07T05:31:56Z",
"customProperties": [
{
"dataSensitivity": "high",
"isEncrypted": true,
"isLargeValue": true,
"name": "<string>",
"persistenceTimestamp": 123,
"requestId": "<string>",
"selectedByUser": true,
"selectedByUserTimestamp": 123,
"source": "ACADEMY",
"sourceId": "<string>",
"sourceLabel": "<string>",
"sourceMetadata": "<string>",
"sourceUpstreamDeployable": "<string>",
"sourceVid": [
123
],
"timestamp": 123,
"unit": "<string>",
"updatedByUserId": 123,
"useTimestampAsPersistenceTimestamp": true,
"value": "<string>"
}
],
"eventName": "<string>",
"eventOrganizer": "<string>",
"id": "<string>",
"updatedAt": "2023-11-07T05:31:56Z",
"endDateTime": "2023-11-07T05:31:56Z",
"eventCancelled": true,
"eventCompleted": true,
"eventDescription": "<string>",
"eventType": "<string>",
"eventUrl": "<string>",
"objectId": "<string>",
"startDateTime": "2023-11-07T05:31:56Z"
}
],
"startedAt": "2023-11-07T05:31:56Z",
"status": "CANCELED",
"errors": [
{
"category": "<string>",
"context": {},
"errors": [
{
"message": "<string>",
"code": "<string>",
"context": "{missingScopes=[scope1, scope2]}",
"in": "<string>",
"subCategory": "<string>"
}
],
"links": {},
"message": "<string>",
"status": "<string>",
"id": "<string>",
"subCategory": {}
}
],
"links": {},
"numErrors": 123,
"requestedAt": "2023-11-07T05:31:56Z"
}サポートされる製品
必須スコープ
The access token received from the authorization server in the OAuth 2.0 flow.
表示 子属性
successful operation
リクエストが完了した時点のタイムスタンプ。
表示 子属性
リクエストの処理が開始された時点のタイムスタンプ。
レスポンスのステータス。
CANCELED, COMPLETE, PENDING, PROCESSING 表示 子属性
リクエストの結果。
表示 子属性
リクエスト中に発生したエラーの数。
リクエストが送信された時点のタイムスタンプ。