Ventia
Sales
POST
/sales

Authorization

bearerAuth
AuthorizationBearer <token>

API key sent as Authorization: Bearer <API_KEY>.

In: header

Request Body

application/json

status*string

The status of the sale to match in system.

ticket_id*string

ID of the ticket.

ticket_sale_id?string

ID of the ticket sale.

date_sale?string

Sale date. Accepted format: yyyy/mm/dd or yyyy-mm-dd.

Formatdate
date?string

Sale date. Accepted format: yyyy/mm/dd or yyyy-mm-dd.

Formatdate
type?string

Type of sale.

phone*string

Customer's phone number.

name?string

Customer's name.

gov_id?string

Customer's government ID.

user*string

ID of the user making the sale.

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://api.getventia.com/api/v1.0/sales" \  -H "Content-Type: application/json" \  -d '{    "status": "SOLD",    "ticket_id": "ticket-5678",    "phone": "+12345678900",    "user": "abcd1234efgh5678ijkl9012"  }'
{
  "ticket_id": "ticket-5678",
  "ticket_sale_id": "sale-5678",
  "date": "2024-02-24T15:00:00.000Z",
  "date_sale": "2024-02-24T15:00:00.000Z",
  "name": "John Doe",
  "phone": "+12345678900",
  "secondary_phones": [],
  "gov_id": "12345678",
  "status": "SOLD",
  "status_lock": false,
  "sold": true,
  "cancel": false,
  "lock": false,
  "user": "abcd1234efgh5678ijkl9012",
  "user_string": "John Doe",
  "user_lock": false,
  "user_edit": false,
  "company": "abcd1234efgh5678ijkl9012",
  "importation": "Public API",
  "value": 0,
  "remove_from_goal": false,
  "comissions": [
    {}
  ],
  "_id": "abcd1234efgh5678ijkl9012",
  "createdAt": "2024-10-23T20:02:13.887Z",
  "updatedAt": "2024-10-23T20:02:13.887Z",
  "__v": 0
}
{
  "error": "string",
  "zError": {}
}
{
  "error": "string"
}
{
  "error": "string"
}
{
  "error": "string"
}