curl --request GET \
--url https://api.hubapi.com/crm/v3/extensions/cards-dev/sample-response
{
"totalCount": 1,
"allItemsLinkUrl": "https://example.com/all-items-link-url",
"cardLabel": "Tickets",
"topLevelActions": {
"settings": {
"type": "IFRAME",
"width": 640,
"height": 480,
"url": "https://example.com/iframe-contents",
"label": "Edit",
"propertyNamesIncluded": [
"some_crm_property"
]
},
"primary": {
"type": "IFRAME",
"width": 640,
"height": 480,
"url": "https://example.com/primary-iframe",
"label": "test_label_primary",
"propertyNamesIncluded": []
},
"secondary": [
{
"type": "IFRAME",
"width": 640,
"height": 480,
"url": "https://example.com/secondary-iframe",
"label": "test_label_secondary",
"propertyNamesIncluded": []
}
]
},
"sections": [
{
"id": "123",
"title": "API-22: APIs working too fast",
"linkUrl": "http://example.com/1",
"tokens": [
{
"name": "created",
"label": "test_label",
"dataType": "DATE",
"value": "2016-08-04"
}
],
"actions": [
{
"type": "ACTION_HOOK",
"httpMethod": "POST",
"url": "https://example.com/action-hook-frame",
"label": "action-hook-label",
"propertyNamesIncluded": [
"email",
"firstName"
]
},
{
"type": "ACTION_HOOK",
"confirmation": {
"prompt": "action-confirmation-body-prompt",
"confirmButtonLabel": "Continue",
"cancelButtonLabel": "Cancel"
},
"httpMethod": "POST",
"url": "https://example.com/confirmation-action-hook",
"label": "confirmation-hook-label",
"propertyNamesIncluded": []
},
{
"type": "IFRAME",
"width": 640,
"height": 480,
"url": "https://example.com/iframe-action-label",
"label": "iframe-action-label",
"propertyNamesIncluded": [
"property1",
"property2",
"property3"
]
}
]
}
],
"responseVersion": "v3"
}
Gibt eine Antwort mit Beispielkartendetails zurück. Dies ist die Payload mit angezeigten Details für eine Karte, die einem Benutzer angezeigt wird. Eine App sollte dies als Antwort auf die Datenabrufanfrage senden.
curl --request GET \
--url https://api.hubapi.com/crm/v3/extensions/cards-dev/sample-response
{
"totalCount": 1,
"allItemsLinkUrl": "https://example.com/all-items-link-url",
"cardLabel": "Tickets",
"topLevelActions": {
"settings": {
"type": "IFRAME",
"width": 640,
"height": 480,
"url": "https://example.com/iframe-contents",
"label": "Edit",
"propertyNamesIncluded": [
"some_crm_property"
]
},
"primary": {
"type": "IFRAME",
"width": 640,
"height": 480,
"url": "https://example.com/primary-iframe",
"label": "test_label_primary",
"propertyNamesIncluded": []
},
"secondary": [
{
"type": "IFRAME",
"width": 640,
"height": 480,
"url": "https://example.com/secondary-iframe",
"label": "test_label_secondary",
"propertyNamesIncluded": []
}
]
},
"sections": [
{
"id": "123",
"title": "API-22: APIs working too fast",
"linkUrl": "http://example.com/1",
"tokens": [
{
"name": "created",
"label": "test_label",
"dataType": "DATE",
"value": "2016-08-04"
}
],
"actions": [
{
"type": "ACTION_HOOK",
"httpMethod": "POST",
"url": "https://example.com/action-hook-frame",
"label": "action-hook-label",
"propertyNamesIncluded": [
"email",
"firstName"
]
},
{
"type": "ACTION_HOOK",
"confirmation": {
"prompt": "action-confirmation-body-prompt",
"confirmButtonLabel": "Continue",
"cancelButtonLabel": "Cancel"
},
"httpMethod": "POST",
"url": "https://example.com/confirmation-action-hook",
"label": "confirmation-hook-label",
"propertyNamesIncluded": []
},
{
"type": "IFRAME",
"width": 640,
"height": 480,
"url": "https://example.com/iframe-action-label",
"label": "iframe-action-label",
"propertyNamesIncluded": [
"property1",
"property2",
"property3"
]
}
]
}
],
"responseVersion": "v3"
}
successful operation
The card details payload, sent to HubSpot by an app in response to a data fetch request when a user visits a CRM record page.