# CREATE TICKET: Stage missing

**URL:** <https://community.hubspot.com/t/create-ticket-stage-missing/71150>\
**Category:** APIs & Integrations\
**Tags:** professional\
**Created:** [December 13, 2022, 7:46pm UTC](https://community.hubspot.com/t/create-ticket-stage-missing/71150 "2022-12-13T19:46:59Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![EIbbetson](https://avatars.discourse-cdn.com/v4/letter/e/d9b06d/32.png) [@EIbbetson](https://community.hubspot.com/u/EIbbetson)\
**Post date:** [December 13, 2022, 7:46pm UTC](https://community.hubspot.com/t/create-ticket-stage-missing/71150/1 "2022-12-13T19:46:59Z")

</div>

Hello,

I am hoping to use the API listed here:

/crm/v3/objects/tickets

([CRM API | Tickets (hubspot.com)](https://developers.hubspot.com/docs/api/crm/tickets)

The error in my script says

Error creating TICKET. Some required properties were not set.

I put it into Postman and got this additional part:

{

```
"status": "error",

"message": "Error creating TICKET. Some required properties were not set.",

"correlationId": "bba1c5fe-59ce-4991-80ea-f21582b15658",

"context": {

    "properties": \[

        "hs\_pipeline\_stage"

    ]

},

"category": "VALIDATION\_ERROR"

```

}

The data I am sending:

{

```
"hs\_pipeline": 1,

"hs\_pipeline\_stage": 2,

"hs\_ticket\_priority": "HIGH",

"hubspot\_owner\_id": "3",

"subject": "Test: 12-0",

"gracoroberts\_order\_number": "12-0",

"source": "EMAIL",

"content": "Test ticket",

"hs\_ticket\_category": "Sales Order"

```

}

Noted I have checked the hs\_pipeline, hs\_pipeline\_stage and hubspot\_owner\_id are the correct ones via both the UI and API outputs, where I ran:

[https://api.hubapi.com/crm/v3/pipelines/tickets](https://api.hubapi.com/crm/v3/pipelines/tickets)

Outputted the Pipeline and Stage, I pasted them in. I also pasted the exact names for hs\_pipeline etc.

Also checked the owner id is an actual user, I went into users and took their ID. They are also active.

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [December 13, 2022, 8:52pm UTC](https://community.hubspot.com/t/create-ticket-stage-missing/71150/2 "2022-12-13T20:52:24Z")

</div>

Hi, @EIbbetson 👋 Thanks for reaching out. I cannot reproduce your error when using your example. I tested with my example:

 ![my-ex-01.jpg](https://d2qpr2jzcazej7.cloudfront.net/original/3X/e/6/e6abdde01910115d9cfb6144d100960249670f97.jpeg)

As well as using the first 4 lines of your request body (I used copy + paste and changed the IDs to work with my portal) and testing from the documentation example here — [POST](https://developers.hubspot.com/docs/api/crm/tickets)  
[/crm/v3/objects/tickets](https://developers.hubspot.com/docs/api/crm/tickets)

Request:

```lia-code-sample
curl --request POST \
 --url https://api.hubapi.com/crm/v3/objects/tickets \
 --header 'authorization: Bearer YOUR_ACCESS_TOKEN' \
 --header 'content-type: application/json' \
 --data '{
 "properties": {
 "hs_pipeline": 0,
 "hs_pipeline_stage": 2,
 "hs_ticket_priority": "HIGH",
 "hubspot_owner_id": "198670650"
 }
}'

```

Response:

```lia-code-sample
HTTP 201

{
 "id": "1317382811",
 "properties": {
 "createdate": "2022-12-13T20:34:07.713Z",
 "hs_all_accessible_team_ids": "12073943",
 "hs_all_owner_ids": "198670650",
 "hs_all_team_ids": "12073943",
 "hs_lastmodifieddate": "2022-12-13T20:34:07.713Z",
 "hs_object_id": "1317382811",
 "hs_pipeline": "0",
 "hs_pipeline_stage": "2",
 "hs_ticket_id": "1317382811",
 "hs_ticket_priority": "HIGH",
 "hs_user_ids_of_all_owners": "10233975",
 "hubspot_owner_assigneddate": "2022-12-13T20:34:07.713Z",
 "hubspot_owner_id": "198670650",
 "hubspot_team_id": "12073943"
 },
 "createdAt": "2022-12-13T20:34:07.713Z",
 "updatedAt": "2022-12-13T20:34:07.713Z",
 "archived": false
}

```

In both examples, I successfully created a ticket in my test portal using the provided endpoint example.

One request, for the pipeline you are using, can you go to Settings \> Objects \> Tickets \> Pipelines and verify the internal ID for your pipeline matches what you are inputting, please?

 ![CleanShot 2022-12-13 at 13.51.28.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/2/1/21adee65bd7e5b1462987c7b35f3442545420eac.png)

Best,

Jaycee

---

<div class="post-metadata">

**Author:** ![EIbbetson](https://avatars.discourse-cdn.com/v4/letter/e/d9b06d/32.png) [@EIbbetson](https://community.hubspot.com/u/EIbbetson)\
**Post date:** [December 13, 2022, 9:00pm UTC](https://community.hubspot.com/t/create-ticket-stage-missing/71150/3 "2022-12-13T21:00:44Z")

</div>

This is how I checked the Pipeline stage in the UI and again via API. It is correct for both the Pipeline and Stage.

My error seems to be complaining I haven’t got the stage in the properties body at all as it’s the same error if I remove the field entirely.

---

<div class="post-metadata">

**Author:** ![EIbbetson](https://avatars.discourse-cdn.com/v4/letter/e/d9b06d/32.png) [@EIbbetson](https://community.hubspot.com/u/EIbbetson)\
**Post date:** [December 14, 2022, 11:57am UTC](https://community.hubspot.com/t/create-ticket-stage-missing/71150/4 "2022-12-14T11:57:10Z")

</div>

I reproduced this error on a test developer account, with a different auth token that allows for tickets.

In this scenario, the pipeline is 0 and the stage is 1. Can’t go wrong here. I used the same fields as you, got my Owner ID number. Still fails citing HS\_PIPELINE\_STAGE is missing. I also tried removing the hubspot\_owner\_id and the same error is returned.

{

“status”: “error”,

“message”: “Error creating TICKET. Some required properties were not set.”,

“correlationId”: “981ec9fd-bb1d-46c3-a2c0-09fa911fb1dd”,

“context”: {

“properties”: [

“hs\_pipeline\_stage”

]

},

“category”: “VALIDATION\_ERROR”

}

---

<div class="post-metadata">

**Author:** ![EIbbetson](https://avatars.discourse-cdn.com/v4/letter/e/d9b06d/32.png) [@EIbbetson](https://community.hubspot.com/u/EIbbetson)\
**Post date:** [December 14, 2022, 12:02pm UTC](https://community.hubspot.com/t/create-ticket-stage-missing/71150/5 "2022-12-14T12:02:35Z")

</div>

I have resolved this. It requires the data to be encased inside a parent attribute:

{properties: {

data here

}}

This was not clear as the example provided for NodeJS is to use a wrapped API, however upon suggestion by a HubSpot developer, I am using Axios.
