Skip to main content
POST
/
orders
/
new
Nova Compra
curl --request POST \
  --url http://api.loya.com.br/v1/orders/new \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "entity": "phone",
  "doc": "11987654321",
  "value": 99.99,
  "dot": 99
}
'
{
  "id": 123,
  "entity": "phone",
  "doc": "11987654321",
  "value": 99.99,
  "dot": 99
}

Documentation Index

Fetch the complete documentation index at: https://developer.loya.com.br/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
entity
enum<string>
required

Tipo de documento

Available options:
cpf,
phone
Example:

"phone"

doc
string
required

Valor do documento

Example:

"11987654321"

value
number<float>
required

Valor do pagamento

Example:

99.99

dot
integer

Pontos resgatados para gerar essa compra

Example:

99

Response

Registro

id
integer
required

Id do registro

Example:

123

entity
enum<string>
required

Tipo de documento

Available options:
cpf,
phone
Example:

"phone"

doc
string
required

Valor do documento

Example:

"11987654321"

value
number<float>
required

Valor do pagamento

Example:

99.99

dot
integer

Pontos resgatados para gerar essa compra

Example:

99