Templates de Webhooks do BaaS
Esse endpoint permite que nossos clientes consultem todos os eventos e templates de webhook do BaaS.
Confira o tutorial desse módulo
1. Consultar eventos de Webhook
Passos para Integrar
- Realizar autenticação na API - [API Reference]
- Consultar eventos dos Webhooks [API Reference]
cURL da chamada
curl -X 'GET' \
'https://sandbox.openfinance.celcoin.dev/baas-webhookmanager/v1/webhook/entity/list' \
-H 'accept: application/json'
Exemplo de retorno
Sucesso 200
{
"version": "1.0.0",
"status": "SUCCESS",
"body": {
"entityList": [
{
"entity": "pix-payment-out"
}
]
}
}
Error 400
{
"version": "1.0.0",
"status": "ERROR",
"error": {
"errorCode": "CIE999",
"message": "Ocorreu um erro interno durante a chamada da api."
}
}
2. Consultar templates de Webhook
Passos para Integrar
- Realizar autenticação na API - [API Reference]
- Consultar templates dos Webhooks [API Reference]
cURL da chamada
curl --location --request GET 'https://sandbox.openfinance.celcoin.dev/baas-webhookmanager/v1/webhook/templates?Page=1&Limit=200&LimitPerPage=200&Entity=pix-payment-out&Status=CONFIRMED' \
--header 'accept: application/json' \
--header 'Authorization: {{token}}'
Parâmetros
Sobre os filtros de Parâmetros
Os parâmetros são opcionais para facilitar a sua busca por eventos, caso você não informe nenhum parâmetro iremos retornar todos os eventos e status
Nome | Descrição |
---|---|
Entity | onboarding-create pix-payment-out pix-payment-in pix-reversal-in pix-reversal-out spb-reversal-in spb-transfer-out spb-transfer-in pix-dict-claim-open pix-dict-claim-waiting pix-dict-claim-confirmed pix-dict-claim-cancelled pix-dict-claim-completed internal-transfer-in internal-transfer-out charge-in. charge-create. charge-canceled. kyc billpayment. billpayment-occurrence. slc-payment-in judicial-movement-in judicial-movement-out |
Status | CONFIRMED. ERROR. |
Exemplo de retorno
Sucesso 200
{
"body":{
"totalItems":18,
"currentPage":1,
"limitPerPage":200,
"totalPages":1,
"entityList":[
{
"entity":"spb-transfer-out",
"webhookTemplates":[
{
"entity":"spb-transfer-out",
"createTimestamp":"2023-07-14T00:09:42.995873",
"status":"ERROR",
"body":{
"clientFinality":"110",
"amount":0.01,
"debitParty":{
"bank":"13935893",
"taxId":"46463721000",
"accountType":"CC",
"name":"teste",
"personType":"F",
"branch":"0001",
"account":"300123"
},
"clientCode":"9bed3141-ad08-4082-ae3b-8cedb7551eca",
"id":"773ecd22-3447-49c2-a661-e9ba61bda4b9",
"creditParty":{
"bank":"123456",
"taxId":"46463721000",
"accountType":"CC",
"name":"teste",
"personType":"F",
"branch":"0001",
"account":"300123"
}
},
"error":{
"errorCode":"404",
"message":"SPB not found"
}
},
{
"entity":"spb-transfer-out",
"createTimestamp":"2023-07-24T17:02:47.0824409",
"status":"CONFIRMED",
"body":{
"clientFinality":"10",
"numCtrlStr":"STR20230724034501234",
"amount":750,
"debitParty":{
"bank":"13935893",
"taxId":"46463721000",
"accountType":"CC",
"name":"teste",
"personType":"J",
"branch":"0001",
"account":"300123"
},
"clientCode":"78d96006-c535-46e3-93a6-d8c85a6000bc",
"description":"Pagamento",
"id":"7e172eef-f05e-429e-ae36-401310a204cd",
"creditParty":{
"bank":"00360305",
"taxId":"46463721000",
"accountType":"CC",
"name":"teste",
"personType":"F",
"branch":"0001",
"account":"300123"
}
}
}
]
},
{
"entity":"spb-transfer-in",
"webhookTemplates":[
{
"entity":"spb-transfer-in",
"createTimestamp":"2023-07-27T09:10:29.5587634",
"status":"CONFIRMED",
"body":{
"numCtrlSTR":"1393589324514991234",
"amount":872.03,
"debitParty":{
"bank":"16501555",
"taxId":"46463721000",
"accountType":"PG",
"name":"teste",
"personType":"J",
"account":"300123"
},
"id":"e2726e30-c318-4e1f-b284-e37c14e6c4b2",
"clientfinality":"10",
"creditParty":{
"bank":"13935893",
"taxId":"46463721000",
"accountType":"CC",
"name":"teste",
"personType":"J",
"branch":"1",
"account":"300123"
}
}
}
]
}
]
},
"status":"SUCCESS",
"version":"1.0.0"
}
Error 400
{
"version": "1.0.0",
"status": "ERROR",
"error": {
"errorCode": "CIE999",
"message": "Ocorreu um erro interno durante a chamada da api."
}
}
Updated 4 months ago