Get all deals (BETA)
GET {{baseUrl}}/deals/collection?cursor=<string>&limit=<integer>&since=<string>&until=<string>&user_id=<integer>&stage_id=<integer>&status=<string>
Returns all deals. This is a cursor-paginated endpoint that is currently in BETA. For more information, please refer to our documentation on pagination. Please note that only global admins (those with global permissions) can access these endpoints. Users with regular permissions will receive a 403 response. Read more about global permissions here.
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
cursor | string | For pagination, the marker (an opaque string value) representing the first item on the next page | |
limit | string | For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed. | |
since | string | The time boundary that points to the start of the range of data. Datetime in ISO 8601 format. E.g. 2022-11-01 08:55:59. Operates on the update_time field. | |
until | string | The time boundary that points to the end of the range of data. Datetime in ISO 8601 format. E.g. 2022-11-01 08:55:59. Operates on the update_time field. | |
user_id | string | If supplied, only deals matching the given user will be returned | |
stage_id | string | If supplied, only deals within the given stage will be returned | |
status | string | Only fetch deals with a specific status. If omitted, all not deleted deals are returned. If set to deleted, deals that have been deleted up to 30 days ago will be included. |
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Accept | string |
RESPONSES
status: OK
{"success":true,"data":[{"id":1,"creator_user_id":8877,"person_id":1101,"org_id":5,"stage_id":2,"title":"Deal One","value":5000,"currency":"EUR","add_time":"2019-05-29 04:21:51","update_time":"2019-11-28 16:19:50","status":"open","probability":null,"lost_reason":null,"visible_to":"1","close_time":null,"pipeline_id":1,"won_time":"2019-11-27 11:40:36","lost_time":"2019-11-27 11:40:36","expected_close_date":"2019-06-29","label":"11"}],"additional_data":{"next_cursor":"eyJhY3Rpdml0aWVzIjoyN30"}}