POST
/
crm-objects
/
v1
/
objects
/
tickets
/
batch-create
Create a group of tickets
curl --request POST \
  --url https://api.hubapi.com/crm-objects/v1/objects/tickets/batch-create
"\nExample POST URL:\nhttps://api.hubapi.com/crm-objects/v1/objects/tickets/batch-create\n\nExample POST JSON (creating two tickets):\n[\n  [\n    {\n      \"name\": \"source_type\",\n      \"value\": \"TWITTER_DM\"\n    },\n    {\n      \"name\": \"status\",\n      \"value\": \"OPEN\"\n    },\n    {\n      \"name\": \"created_by\",\n      \"value\": \"496346\"\n    },\n    {\n      \"name\": \"subject\",\n      \"value\": \"This is another example ticket\"\n    }\n  ],\n  [\n    {\n      \"name\": \"source_type\",\n      \"value\": \"FORM\"\n    },\n    {\n      \"name\": \"status\",\n      \"value\": \"CLOSED\"\n    },\n    {\n      \"name\": \"created_by\",\n      \"value\": \"496346\"\n    },\n    {\n      \"name\": \"subject\",\n      \"value\": \"Yet anotherexample ticket\"\n    }\n  ]\n]\n\nExample response:\n[\n  {\n    \"objectType\": \"TICKET\",\n    \"portalId\": 62515,\n    \"objectId\": 178218,\n    \"properties\": {\n      \"hs_lastmodifieddate\": {\n        \"versions\": [\n          {\n            \"name\": \"hs_lastmodifieddate\",\n            \"value\": \"0\",\n            \"timestamp\": 0,\n            \"source\": \"CALCULATED\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"0\",\n        \"timestamp\": 0,\n        \"source\": \"CALCULATED\",\n        \"sourceId\": null\n      },\n      \"subject\": {\n        \"versions\": [\n          {\n            \"name\": \"subject\",\n            \"value\": \"This is another example ticket\",\n            \"timestamp\": 1522870759430,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"This is another example ticket\",\n        \"timestamp\": 1522870759430,\n        \"source\": \"API\",\n        \"sourceId\": null\n      },\n      \"createdate\": {\n        \"versions\": [\n          {\n            \"name\": \"createdate\",\n            \"value\": \"0\",\n            \"timestamp\": 0,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"0\",\n        \"timestamp\": 0,\n        \"source\": \"API\",\n        \"sourceId\": null\n      },\n      \"source_type\": {\n        \"versions\": [\n          {\n            \"name\": \"source_type\",\n            \"value\": \"TWITTER_DM\",\n            \"timestamp\": 1522870759430,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"TWITTER_DM\",\n        \"timestamp\": 1522870759430,\n        \"source\": \"API\",\n        \"sourceId\": null\n      },\n      \"created_by\": {\n        \"versions\": [\n          {\n            \"name\": \"created_by\",\n            \"value\": \"496346\",\n            \"timestamp\": 1522870759430,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"496346\",\n        \"timestamp\": 1522870759430,\n        \"source\": \"API\",\n        \"sourceId\": null\n      },\n      \"status\": {\n        \"versions\": [\n          {\n            \"name\": \"status\",\n            \"value\": \"OPEN\",\n            \"timestamp\": 1522870759430,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"OPEN\",\n        \"timestamp\": 1522870759430,\n        \"source\": \"API\",\n        \"sourceId\": null\n      }\n    },\n    \"isDeleted\": false\n  },\n  {\n    \"objectType\": \"TICKET\",\n    \"portalId\": 62515,\n    \"objectId\": 176602,\n    \"properties\": {\n      \"hs_lastmodifieddate\": {\n        \"versions\": [\n          {\n            \"name\": \"hs_lastmodifieddate\",\n            \"value\": \"0\",\n            \"timestamp\": 0,\n            \"source\": \"CALCULATED\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"0\",\n        \"timestamp\": 0,\n        \"source\": \"CALCULATED\",\n        \"sourceId\": null\n      },\n      \"subject\": {\n        \"versions\": [\n          {\n            \"name\": \"subject\",\n            \"value\": \"Yet anotherexample ticket\",\n            \"timestamp\": 1522870759430,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"Yet anotherexample ticket\",\n        \"timestamp\": 1522870759430,\n        \"source\": \"API\",\n        \"sourceId\": null\n      },\n      \"createdate\": {\n        \"versions\": [\n          {\n            \"name\": \"createdate\",\n            \"value\": \"0\",\n            \"timestamp\": 0,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"0\",\n        \"timestamp\": 0,\n        \"source\": \"API\",\n        \"sourceId\": null\n      },\n      \"source_type\": {\n        \"versions\": [\n          {\n            \"name\": \"source_type\",\n            \"value\": \"FORM\",\n            \"timestamp\": 1522870759430,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"FORM\",\n        \"timestamp\": 1522870759430,\n        \"source\": \"API\",\n        \"sourceId\": null\n      },\n      \"created_by\": {\n        \"versions\": [\n          {\n            \"name\": \"created_by\",\n            \"value\": \"496346\",\n            \"timestamp\": 1522870759430,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"496346\",\n        \"timestamp\": 1522870759430,\n        \"source\": \"API\",\n        \"sourceId\": null\n      },\n      \"status\": {\n        \"versions\": [\n          {\n            \"name\": \"status\",\n            \"value\": \"CLOSED\",\n            \"timestamp\": 1522870759430,\n            \"source\": \"API\",\n            \"sourceVid\": []\n          }\n        ],\n        \"value\": \"CLOSED\",\n        \"timestamp\": 1522870759430,\n        \"source\": \"API\",\n        \"sourceId\": null\n      }\n    },\n    \"isDeleted\": false\n  }\n]"

Response

200 - application/json

Successful response - Delete a group of existing tickets

The response is of type object.