Skip to content

Commit d1f184d

Browse files
chore: update all transaction endpoints with examples and descriptions
1 parent 027dce2 commit d1f184d

15 files changed

Lines changed: 828 additions & 898 deletions

dist/paystack.yaml

Lines changed: 797 additions & 829 deletions
Large diffs are not rendered by default.

src/assets/openapi/components/schemas/TransactionInitialize.yaml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,7 @@ properties:
99
type: string
1010
amount:
1111
description: >
12-
Amount should be in smallest denomination of the currency. For example if
13-
currency is NGN, pesewas, if currency is GHS, and cents, if currency is
14-
ZAR
12+
Amount should be in smallest denomination of the currency.
1513
type: integer
1614
currency:
1715
$ref: ./Currency.yaml

src/assets/openapi/openapi.yaml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,10 @@ tags:
140140
paths:
141141
/transaction/initialize:
142142
$ref: paths/transaction_initialize.yaml
143+
/transaction/charge_authorization:
144+
$ref: paths/transaction_charge_authorization.yaml
145+
/transaction/partial_debit:
146+
$ref: paths/transaction_partial_debit.yaml
143147
/transaction/verify/{reference}:
144148
$ref: paths/transaction_verify_{reference}.yaml
145149
/transaction:
@@ -152,14 +156,6 @@ paths:
152156
$ref: paths/transaction_totals.yaml
153157
/transaction/export:
154158
$ref: paths/transaction_export.yaml
155-
/transaction/charge_authorization:
156-
$ref: paths/transaction_charge_authorization.yaml
157-
/transaction/partial_debit:
158-
$ref: paths/transaction_partial_debit.yaml
159-
/transaction/{id}/event:
160-
$ref: paths/transaction_{id}_event.yaml
161-
/transaction/{id}/session:
162-
$ref: paths/transaction_{id}_session.yaml
163159
/split:
164160
$ref: paths/split.yaml
165161
/split/{id}:

src/assets/openapi/paths/address_verification_states.yaml

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,14 @@ get:
33
- Miscellaneous
44
summary: List States (AVS)
55
operationId: miscellaneous_avs
6+
description: Get a list of states for a country for address verification
67
parameters:
7-
- in: query
8-
name: type
9-
schema:
10-
type: string
118
- in: query
129
name: country
10+
description: The country code of the states to list. It is gotten after the charge request
1311
schema:
1412
type: string
15-
- in: query
16-
name: currency
17-
schema:
18-
type: string
13+
example: CA
1914
responses:
2015
'200':
2116
$ref: ../components/responses/MiscellaneousListStatesSuccess.yaml

src/assets/openapi/paths/apple-pay_domain.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,10 @@ post:
22
tags:
33
- Apple Pay
44
summary: Register Domain
5-
description: Register a top-level domain or subdomain for your Apple Pay integration.
5+
description: |
6+
Register a top-level domain or subdomain for your Apple Pay integration.
7+
8+
> This endpoint can only be called with one domain or subdomain at a time.
69
operationId: applePay_registerDomain
710
requestBody:
811
content:
@@ -23,7 +26,7 @@ get:
2326
tags:
2427
- Apple Pay
2528
summary: List Domains
26-
description: Lists all registered domains on your integration
29+
description: Lists all registered domains on your integration. Returns an empty array if no domains have been added.
2730
operationId: applePay_listDomain
2831
parameters:
2932
- name: use_cursor
@@ -51,7 +54,7 @@ delete:
5154
tags:
5255
- Apple Pay
5356
summary: Unregister Domain
54-
description: >-
57+
description: |
5558
Unregister a top-level domain or subdomain previously used for your Apple
5659
Pay integration.
5760
operationId: applePay_unregisterDomain

src/assets/openapi/paths/bank.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,15 @@ get:
66
parameters:
77
- in: query
88
name: country
9+
description: |
10+
The country from which to obtain the list of supported banks.
911
schema:
1012
type: string
13+
enum:
14+
- ghana
15+
- kenya
16+
- nigeria
17+
- south africa
1118
- in: query
1219
name: pay_with_bank_transfer
1320
schema:

src/assets/openapi/paths/transaction.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ get:
1010
description: A flag to indicate if cursor based pagination should be used
1111
schema:
1212
type: boolean
13+
example: true
1314
- in: query
1415
name: next
1516
description: >

src/assets/openapi/paths/transaction_charge_authorization.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ post:
33
- Transaction
44
summary: Charge Authorization
55
operationId: transaction_chargeAuthorization
6+
description: Charge all authorizations marked as reusable with this endpoint whenever you need to receive payments
67
requestBody:
78
content:
89
application/json:

src/assets/openapi/paths/transaction_export.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ get:
44
summary: Export Transactions
55
operationId: transaction_export
66
x-operationId: transaction_exportTransaction
7+
description: Download transactions that occurred on your integration for a specific timeframe
78
parameters:
89
- in: query
910
name: from

src/assets/openapi/paths/transaction_partial_debit.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ post:
33
- Transaction
44
summary: Partial Debit
55
operationId: transaction_partialDebit
6+
description: Retrieve part of a payment from a customer
67
requestBody:
78
content:
89
application/json:

0 commit comments

Comments
 (0)