Pular para o conteúdo principal
POST
Criar cobrança Pix

Autorizações

Authorization
string
header
obrigatório

Chave de API MingoPay com prefixo mp_test_ ou mp_live_.

Cabeçalhos

Idempotency-Key
string
obrigatório

Chave única de 16 a 128 caracteres seguros para esta tentativa.

Pattern: ^[A-Za-z0-9._-]{16,128}$
Exemplo:

"pedido-1024-cobranca-001"

Corpo

application/json
amountCents
integer
obrigatório

Valor em centavos.

Intervalo obrigatório: 100 <= x <= 100000000
method
string
obrigatório
Allowed value: "pix"
payer
object
obrigatório
externalReference
string
Required string length: 1 - 100
description
string
Required string length: 1 - 140
expiresInSeconds
integer
padrão:1800
Intervalo obrigatório: 60 <= x <= 86400
metadata
object
subaccountId
string<uuid>

ID MingoPay da subconta da mesma organização e ambiente. O crédito líquido pertence exclusivamente a ela.

Resposta

Cobrança criada.

id
string<uuid>
obrigatório
organizationId
string<uuid>
obrigatório
amountCents
integer
obrigatório
feeCents
integer
obrigatório

Total descontado: mingoFeeCents + commissionCents.

netCents
integer
obrigatório
currency
string
obrigatório
Allowed value: "BRL"
method
enum<string>
obrigatório
Opções disponíveis:
pix,
card
status
enum<string>
obrigatório
Opções disponíveis:
created,
pending,
processing,
paid,
failed,
cancelled,
partially_refunded,
refunded
metadata
object
obrigatório
createdAt
string<date-time>
obrigatório
updatedAt
string<date-time>
obrigatório
environment
enum<string>
obrigatório
Opções disponíveis:
sandbox,
production
providerFeeCents
integer
obrigatório
platformFeeCents
integer
obrigatório

Receita Mingo: mingoFeeCents - providerFeeCents, sem a comissão do criador.

commissionCents
integer
obrigatório

Comissão do criador da subconta, incluída em feeCents.

Intervalo obrigatório: x >= 0
mingoFeeCents
integer
obrigatório

Tarifa Mingo, incluindo o custo do provedor.

Intervalo obrigatório: x >= 0
pix
object
obrigatório
customerId
string<uuid> | null
externalReference
string | null
provider
string | null
providerReference
string | null
description
string | null
expiresAt
string<date-time> | null
paidAt
string<date-time> | null
subaccountId
string<uuid> | null