openapi: 3.0.3 info: title: 'ClicPay API Documentation' description: 'API ClicPay v2 - M-Pesa, e-Mola, NetShop e autenticação' version: 1.0.0 servers: - url: 'https://clicpay.co.mz' tags: - name: 'Transações M-Pesa' description: '' - name: 'Transações eMola' description: '' - name: 'Transações Mkesh' description: '' - name: 'Transações NetShop' description: '' - name: 'Estado de Transações' description: '' - name: Carteiras description: '' - name: Autenticação description: '' - name: Endpoints description: '' components: securitySchemes: default: type: http scheme: bearer description: 'Para testar a API, insira seu token Bearer no campo "Authorize". Você pode obter um token através do endpoint de autenticação da API.' security: - default: [] paths: '/api/v2/wallets/{wallet_id}/c2b/mpesa': post: summary: '' operationId: postApiV2WalletsWallet_idC2bMpesa description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação iniciada com sucesso' clicpay_reference: CP123456789 status: pending transaction_id: 124 properties: message: type: string example: 'Transação iniciada com sucesso' clicpay_reference: type: string example: CP123456789 description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 124 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: msisdn: - 'Número de telefone inválido' amount: - 'Valor deve ser entre 1 e 50000' properties: errors: type: object properties: msisdn: type: array example: - 'Número de telefone inválido' items: type: string amount: type: array example: - 'Valor deve ser entre 1 e 50000' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' tags: - 'Transações M-Pesa' requestBody: required: true content: application/json: schema: type: object properties: msisdn: type: string description: 'Número de telefone' example: '841234567' amount: type: number description: 'Valor da transação (1-50000)' example: 500.0 reference_description: type: string description: 'Descrição da referência (3-32 caracteres)' example: 'Compra online' internal_notes: type: string description: 'optional Notas internas (máx 255 caracteres)' example: 'Pedido #12345' required: - msisdn - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer '/api/v2/wallets/{wallet_id}/c2b/mpesa/direct': post: summary: '' operationId: postApiV2WalletsWallet_idC2bMpesaDirect description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação iniciada com sucesso' clicpay_reference: CP123456789 status: pending transaction_id: 124 properties: message: type: string example: 'Transação iniciada com sucesso' clicpay_reference: type: string example: CP123456789 description: 'Referência único da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 124 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: msisdn: - 'Número de telefone inválido' amount: - 'Valor deve ser entre 1 e 50000' properties: errors: type: object properties: msisdn: type: array example: - 'Número de telefone inválido' items: type: string amount: type: array example: - 'Valor deve ser entre 1 e 50000' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' tags: - 'Transações M-Pesa' requestBody: required: true content: application/json: schema: type: object properties: msisdn: type: string description: 'Número de telefone' example: '841234567' amount: type: number description: 'Valor da transação (1-50000)' example: 500.0 reference_description: type: string description: 'Descrição da referência (3-32 caracteres)' example: 'Compra online' internal_notes: type: string description: 'optional Notas internas (máx 255 caracteres)' example: 'Pedido #12345' required: - msisdn - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer '/api/v2/wallets/{wallet_id}/b2c/mpesa': post: summary: '' operationId: postApiV2WalletsWallet_idB2cMpesa description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação iniciada com sucesso' clicpay_reference: CP123456789 status: pending transaction_id: 124 properties: message: type: string example: 'Transação iniciada com sucesso' clicpay_reference: type: string example: CP123456789 description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 124 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: msisdn: - 'Número de telefone inválido' amount: - 'Valor deve ser entre 1 e 50000' properties: errors: type: object properties: msisdn: type: array example: - 'Número de telefone inválido' items: type: string amount: type: array example: - 'Valor deve ser entre 1 e 50000' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' tags: - 'Transações M-Pesa' requestBody: required: true content: application/json: schema: type: object properties: msisdn: type: string description: 'Número de telefone' example: '841234567' amount: type: number description: 'Valor da transação (1-50000)' example: 500.0 reference_description: type: string description: 'Descrição da referência (3-32 caracteres)' example: 'Compra online' internal_notes: type: string description: 'optional Notas internas (máx 255 caracteres)' example: 'Pedido #12345' required: - msisdn - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer '/api/v2/wallets/{wallet_id}/c2b/emola': post: summary: '' operationId: postApiV2WalletsWallet_idC2bEmola description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação iniciada com sucesso' clicpay_reference: CP123456789 status: pending transaction_id: 123 properties: message: type: string example: 'Transação iniciada com sucesso' clicpay_reference: type: string example: CP123456789 description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 123 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: msisdn: - 'Número de telefone inválido' amount: - 'Valor deve ser entre 1 e 50000' properties: errors: type: object properties: msisdn: type: array example: - 'Número de telefone inválido' items: type: string amount: type: array example: - 'Valor deve ser entre 1 e 50000' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' tags: - 'Transações eMola' requestBody: required: true content: application/json: schema: type: object properties: msisdn: type: string description: 'Número de telefone' example: '841234567' amount: type: number description: 'Valor da transação (1-50000)' example: 1000.0 reference_description: type: string description: 'Descrição da referência (3-32 caracteres)' example: 'Pagamento de serviços' internal_notes: type: string description: 'optional Notas internas (máx 255 caracteres)' example: 'Pagamento mensal' required: - msisdn - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer '/api/v2/wallets/{wallet_id}/c2b/emola/direct': post: summary: '' operationId: postApiV2WalletsWallet_idC2bEmolaDirect description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação iniciada com sucesso' clicpay_reference: CP123456789 status: pending transaction_id: 123 properties: message: type: string example: 'Transação iniciada com sucesso' clicpay_reference: type: string example: CP123456789 description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 123 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: msisdn: - 'Número de telefone inválido' amount: - 'Valor deve ser entre 1 e 50000' properties: errors: type: object properties: msisdn: type: array example: - 'Número de telefone inválido' items: type: string amount: type: array example: - 'Valor deve ser entre 1 e 50000' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' tags: - 'Transações eMola' requestBody: required: true content: application/json: schema: type: object properties: msisdn: type: string description: 'Número de telefone' example: '841234567' amount: type: number description: 'Valor da transação (1-50000)' example: 1000.0 reference_description: type: string description: 'Descrição da referência (3-32 caracteres)' example: 'Pagamento de serviços' internal_notes: type: string description: 'optional Notas internas (máx 255 caracteres)' example: 'Pagamento mensal' required: - msisdn - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer '/api/v2/wallets/{wallet_id}/b2c/emola': post: summary: '' operationId: postApiV2WalletsWallet_idB2cEmola description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação iniciada com sucesso' clicpay_reference: CP123456789 status: pending transaction_id: 123 properties: message: type: string example: 'Transação iniciada com sucesso' clicpay_reference: type: string example: CP123456789 description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 123 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: msisdn: - 'Número de telefone inválido' amount: - 'Valor deve ser entre 1 e 50000' properties: errors: type: object properties: msisdn: type: array example: - 'Número de telefone inválido' items: type: string amount: type: array example: - 'Valor deve ser entre 1 e 50000' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' tags: - 'Transações eMola' requestBody: required: true content: application/json: schema: type: object properties: msisdn: type: string description: 'Número de telefone' example: '841234567' amount: type: number description: 'Valor da transação (1-50000)' example: 1000.0 reference_description: type: string description: 'Descrição da referência (3-32 caracteres)' example: 'Pagamento de serviços' internal_notes: type: string description: 'optional Notas internas (máx 255 caracteres)' example: 'Pagamento mensal' required: - msisdn - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer '/api/v2/wallets/{wallet_id}/c2b/mkesh': post: summary: '' operationId: postApiV2WalletsWallet_idC2bMkesh description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação iniciada com sucesso' clicpay_reference: CP123456789 status: pending transaction_id: 124 properties: message: type: string example: 'Transação iniciada com sucesso' clicpay_reference: type: string example: CP123456789 description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 124 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: msisdn: - 'Número de telefone inválido' amount: - 'Valor deve ser entre 1 e 50000' properties: errors: type: object properties: msisdn: type: array example: - 'Número de telefone inválido' items: type: string amount: type: array example: - 'Valor deve ser entre 1 e 50000' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' tags: - 'Transações Mkesh' requestBody: required: true content: application/json: schema: type: object properties: msisdn: type: string description: 'Número de telefone' example: '841234567' amount: type: number description: 'Valor da transação (1-50000)' example: 500.0 reference_description: type: string description: 'Descrição da referência (3-32 caracteres)' example: 'Compra online' internal_notes: type: string description: 'optional Notas internas (máx 255 caracteres)' example: 'Pedido #12345' required: - msisdn - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer '/api/v2/wallets/{wallet_id}/c2b/mkesh/direct': post: summary: '' operationId: postApiV2WalletsWallet_idC2bMkeshDirect description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação iniciada com sucesso' clicpay_reference: CP123456789 status: pending transaction_id: 124 properties: message: type: string example: 'Transação iniciada com sucesso' clicpay_reference: type: string example: CP123456789 description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 124 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: msisdn: - 'Número de telefone inválido' amount: - 'Valor deve ser entre 1 e 50000' properties: errors: type: object properties: msisdn: type: array example: - 'Número de telefone inválido' items: type: string amount: type: array example: - 'Valor deve ser entre 1 e 50000' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' tags: - 'Transações Mkesh' requestBody: required: true content: application/json: schema: type: object properties: msisdn: type: string description: 'Número de telefone' example: '841234567' amount: type: number description: 'Valor da transação (1-50000)' example: 500.0 reference_description: type: string description: 'Descrição da referência (3-32 caracteres)' example: 'Compra online' internal_notes: type: string description: 'optional Notas internas (máx 255 caracteres)' example: 'Pedido #12345' required: - msisdn - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer '/api/v2/wallets/{wallet_id}/b2c/mkesh': post: summary: '' operationId: postApiV2WalletsWallet_idB2cMkesh description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação iniciada com sucesso' clicpay_reference: CP123456789 status: pending transaction_id: 124 properties: message: type: string example: 'Transação iniciada com sucesso' clicpay_reference: type: string example: CP123456789 description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 124 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: msisdn: - 'Número de telefone inválido' amount: - 'Valor deve ser entre 1 e 50000' properties: errors: type: object properties: msisdn: type: array example: - 'Número de telefone inválido' items: type: string amount: type: array example: - 'Valor deve ser entre 1 e 50000' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' tags: - 'Transações Mkesh' requestBody: required: true content: application/json: schema: type: object properties: msisdn: type: string description: 'Número de telefone' example: '841234567' amount: type: number description: 'Valor da transação (1-50000)' example: 500.0 reference_description: type: string description: 'Descrição da referência (3-32 caracteres)' example: 'Compra online' internal_notes: type: string description: 'optional Notas internas (máx 255 caracteres)' example: 'Pedido #12345' required: - msisdn - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer '/api/v2/wallets/{wallet_id}/card-payment': post: summary: '' operationId: postApiV2WalletsWallet_idCardPayment description: '' parameters: [] responses: 201: description: '' content: application/json: schema: type: object example: message: 'Sessão criada.' clicpay_reference: '123456789' status: pending provider_reference: '123456789' provider_response_code: '200' provider_status_text: Pending initiated_at: '2023-01-01T00:00:00Z' completed_at: null transaction_id: 123 checkout_url: 'https://netshop.example.com/checkout/abc123' session_id: abc123 success_indicator: indicator123 properties: message: type: string example: 'Sessão criada.' description: 'Mensagem descritiva do status' enum: [] clicpay_reference: type: string example: '123456789' description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] provider_reference: type: string example: '123456789' description: 'Referência do provedor de pagamento' enum: [] provider_response_code: type: string example: '200' description: 'Código de resposta do provedor' enum: [] provider_status_text: type: string example: Pending description: 'Descrição do status do provedor' enum: [] initiated_at: type: string example: '2023-01-01T00:00:00Z' description: 'Data e hora de início da transação (ISO 8601)' enum: [] completed_at: type: string example: null description: 'Data e hora de conclusão da transação (ISO 8601)' enum: [] transaction_id: type: integer example: 123 description: 'ID interno da transação' enum: [] checkout_url: type: string example: 'https://netshop.example.com/checkout/abc123' description: 'URL do checkout NetShop' enum: [] session_id: type: string example: abc123 description: 'ID da sessão NetShop' enum: [] success_indicator: type: string example: indicator123 description: 'Indicador de sucesso da sessão NetShop' enum: [] 400: description: '' content: application/json: schema: type: object example: message: 'Erro ao criar a sessão.' clicpay_reference: '123456789' status: failed transaction_id: 123 provider_response_code: '400' properties: message: type: string example: 'Erro ao criar a sessão.' description: 'Mensagem descritiva do status' enum: [] clicpay_reference: type: string example: '123456789' description: 'Referência única da transação' enum: [] status: type: string example: failed description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 123 description: 'ID interno da transação' enum: [] provider_response_code: type: string example: '400' description: 'Código de resposta do provedor' enum: [] 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. description: 'Mensagem descritiva do status' enum: [] 403: description: '' content: application/json: schema: type: object example: message: 'Acesso negado à carteira' properties: message: type: string example: 'Acesso negado à carteira' description: 'Mensagem descritiva do status' enum: [] 422: description: '' content: application/json: schema: type: object example: errors: amount: - 'O campo valor é obrigatório.' reference_description: - 'O campo descrição da referência é obrigatório.' properties: errors: type: object properties: amount: type: array example: - 'O campo valor é obrigatório.' items: type: string reference_description: type: array example: - 'O campo descrição da referência é obrigatório.' items: type: string tags: - 'Transações NetShop' requestBody: required: true content: application/json: schema: type: object properties: amount: type: number description: 'Valor do pagamento' example: 1500.0 reference_description: type: string description: 'Descrição da referência (máx 100 caracteres)' example: 'Pagamento de fatura' first_name: type: string description: 'optional Primeiro nome do pagador' example: João nullable: true last_name: type: string description: 'optional Último nome do pagador' example: Silva nullable: true email: type: string description: 'optional Email do pagador' example: QYvHk@example.com nullable: true phone: type: string description: 'optional Telefone do pagador' example: '84 123 4567' nullable: true callback_url: type: url description: 'optional URL de retorno' example: 'https://example.com/callback' nullable: true required: - amount - reference_description parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer - in: path name: wallet description: 'ID da carteira NetShop' example: 1234 required: true schema: type: integer '/api/v2/transactions/{clicpay_reference}/status': get: summary: '' operationId: getApiV2TransactionsClicpay_referenceStatus description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: clicpay_reference: CP123456789 status: successful amount: 1000.0 message: 'Transação concluída com sucesso' properties: clicpay_reference: type: string example: CP123456789 description: 'Referência da transação' enum: [] status: type: string example: successful description: 'Status atual (pending/successful/failed/cancelled)' enum: [] amount: type: number example: 1000.0 description: 'Valor da transação' enum: [] message: type: string example: 'Transação concluída com sucesso' description: 'Mensagem descritiva do status' enum: [] 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. description: 'Mensagem descritiva do status' enum: [] 404: description: '' content: application/json: schema: type: object example: message: 'Transação não encontrada' properties: message: type: string example: 'Transação não encontrada' description: 'Mensagem descritiva do status' enum: [] tags: - 'Estado de Transações' parameters: - in: path name: clicpay_reference description: 'Referência ClicPay da transação' example: CP123456789 required: true schema: type: string '/api/v2/wallets/{wallet_id}/split/collect': post: summary: '' operationId: postApiV2WalletsWallet_idSplitCollect description: '' parameters: [] responses: 200: description: '' content: application/json: schema: type: object example: message: 'Transação encontrada' clicpay_reference: CP123456789 status: pending transaction_id: 124 properties: message: type: string example: 'Transação encontrada' clicpay_reference: type: string example: CP123456789 description: 'Referência única da transação' enum: [] status: type: string example: pending description: 'Status atual (pending/successful/failed)' enum: [] transaction_id: type: integer example: 124 description: 'ID interno da transação' enum: [] 400: description: '' content: application/json: schema: type: object example: errors: clicpay_reference: - 'Referência ClicPay inválida' properties: errors: type: object properties: clicpay_reference: type: array example: - 'Referência ClicPay inválida' items: type: string 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - 'Estado de Transações' parameters: - in: path name: wallet_id description: 'The ID of the wallet.' example: 107219 required: true schema: type: integer - in: path name: clicpay_reference description: 'Referência ClicPay da transação' example: CP123456789 required: true schema: type: string /api/v2/me/wallets: get: summary: '' operationId: getApiV2MeWallets description: '' parameters: - in: query name: payment_method_id description: 'optional Filtrar por método de pagamento' example: 1 required: false schema: type: integer description: 'optional Filtrar por método de pagamento' example: 1 - in: query name: is_active description: 'optional Filtrar por status ativo' example: true required: false schema: type: boolean description: 'optional Filtrar por status ativo' example: true - in: query name: environment description: 'optional Filtrar por ambiente (sandbox/production)' example: production required: false schema: type: string description: 'optional Filtrar por ambiente (sandbox/production)' example: production - in: query name: include description: 'optional Incluir relacionamentos (ex: paymentMethod)' example: paymentMethod required: false schema: type: string description: 'optional Incluir relacionamentos (ex: paymentMethod)' example: paymentMethod - in: query name: sort_by description: 'optional Ordenar por campo (id, name, balance, created_at)' example: created_at required: false schema: type: string description: 'optional Ordenar por campo (id, name, balance, created_at)' example: created_at - in: query name: sort_order description: 'optional Ordem da ordenação (asc, desc)' example: desc required: false schema: type: string description: 'optional Ordem da ordenação (asc, desc)' example: desc - in: query name: per_page description: 'optional Itens por página (padrão: 10)' example: 20 required: false schema: type: integer description: 'optional Itens por página (padrão: 10)' example: 20 responses: 200: description: '' content: application/json: schema: type: object example: data: - id: 1 name: 'Minha Carteira' balance: 1000.0 payment_method: id: 1 name: eMola slug: emola links: first: ... last: ... prev: null next: null meta: current_page: 1 from: 1 last_page: 1 per_page: 20 to: 1 total: 1 properties: data: type: array example: - id: 1 name: 'Minha Carteira' balance: 1000 payment_method: id: 1 name: eMola slug: emola description: 'Lista de carteiras' enum: [] items: type: object properties: id: type: integer example: 1 name: type: string example: 'Minha Carteira' balance: type: number example: 1000.0 payment_method: type: object properties: id: type: integer example: 1 name: type: string example: eMola slug: type: string example: emola links: type: object properties: first: type: string example: ... last: type: string example: ... prev: type: string example: null next: type: string example: null meta: type: object properties: current_page: type: integer example: 1 from: type: integer example: 1 last_page: type: integer example: 1 per_page: type: integer example: 20 to: type: integer example: 1 total: type: integer example: 1 tags: - Carteiras /api/user: get: summary: 'Obter utilizador autenticado' operationId: obterUtilizadorAutenticado description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Autenticação /api/me/token: get: summary: 'Obter token de acesso' operationId: obterTokenDeAcesso description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Autenticação /api/v2/webhooks: get: summary: 'Listar webhooks do usuário (suas wallets/organizações)' operationId: listarWebhooksDoUsuriosuasWalletsorganizaes description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints post: summary: 'Criar novo webhook' operationId: criarNovoWebhook description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints requestBody: required: true content: application/json: schema: type: object properties: url: type: string description: 'Must be a valid URL. Must start with one of https:// Must not be greater than 2048 characters.' example: 'http://www.bailey.biz/quos-velit-et-fugiat-sunt-nihil-accusantium-harum.html' events_enabled: type: array description: '' example: - transaction.failed items: type: string enum: - transaction.completed - transaction.failed organization_ids: type: array description: 'The id of an existing record in the organizations table.' example: - 16 items: type: integer wallet_ids: type: array description: 'The id of an existing record in the wallets table.' example: - 16 items: type: integer required: - url '/api/v2/webhooks/{endpoint_id}': get: summary: 'Ver webhook específico' operationId: verWebhookEspecfico description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints put: summary: 'Atualizar webhook' operationId: atualizarWebhook description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints requestBody: required: false content: application/json: schema: type: object properties: url: type: string description: 'Must be a valid URL. Must start with one of https:// Must not be greater than 2048 characters.' example: 'http://www.bailey.biz/quos-velit-et-fugiat-sunt-nihil-accusantium-harum.html' events_enabled: type: array description: '' example: - transaction.failed items: type: string enum: - transaction.completed - transaction.failed active: type: boolean description: '' example: false organization_ids: type: array description: 'The id of an existing record in the organizations table.' example: - 16 items: type: integer wallet_ids: type: array description: 'The id of an existing record in the wallets table.' example: - 16 items: type: integer delete: summary: 'Deletar webhook' operationId: deletarWebhook description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints parameters: - in: path name: endpoint_id description: 'The ID of the endpoint.' example: 16 required: true schema: type: integer '/api/v2/webhooks/{endpoint_id}/toggle': patch: summary: 'Ativar/Desativar webhook' operationId: ativarDesativarWebhook description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints parameters: - in: path name: endpoint_id description: 'The ID of the endpoint.' example: 16 required: true schema: type: integer '/api/v2/webhooks/{endpoint_id}/regenerate-secret': post: summary: 'Regenerar secret do webhook' operationId: regenerarSecretDoWebhook description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints parameters: - in: path name: endpoint_id description: 'The ID of the endpoint.' example: 16 required: true schema: type: integer '/api/v2/webhooks/{endpoint_id}/test': post: summary: 'Testar webhook com payload de teste' operationId: testarWebhookComPayloadDeTeste description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints parameters: - in: path name: endpoint_id description: 'The ID of the endpoint.' example: 16 required: true schema: type: integer '/api/v2/webhooks/{endpoint_id}/events': get: summary: 'Ver eventos do webhook' operationId: verEventosDoWebhook description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints parameters: - in: path name: endpoint_id description: 'The ID of the endpoint.' example: 16 required: true schema: type: integer '/api/v2/webhooks/{endpoint_id}/events/{event_id}': get: summary: 'Ver detalhe de um evento' operationId: verDetalheDeUmEvento description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints parameters: - in: path name: endpoint_id description: 'The ID of the endpoint.' example: 16 required: true schema: type: integer - in: path name: event_id description: 'The ID of the event.' example: 16 required: true schema: type: integer '/api/v2/webhooks/{endpoint_id}/failed-events': get: summary: 'Ver eventos falhados para retry' operationId: verEventosFalhadosParaRetry description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints parameters: - in: path name: endpoint_id description: 'The ID of the endpoint.' example: 16 required: true schema: type: integer '/api/v2/webhooks/{endpoint_id}/events/{event_type}': patch: summary: 'Ativar/Desativar evento específico' operationId: ativarDesativarEventoEspecfico description: '' parameters: [] responses: 401: description: '' content: application/json: schema: type: object example: message: Unauthenticated. properties: message: type: string example: Unauthenticated. tags: - Endpoints requestBody: required: true content: application/json: schema: type: object properties: event_type: type: string description: '' example: transaction.failed enum: - transaction.completed - transaction.failed required: - event_type parameters: - in: path name: endpoint_id description: 'The ID of the endpoint.' example: 16 required: true schema: type: integer - in: path name: event_type description: '' example: architecto required: true schema: type: string