Collections
This API client was generated by Konfig.
- API version: 1.0.0
- Package version: 1.0.1 For more information, please visit https://decentro.tech
- Add
source 'https://github.com/CocoaPods/Specs.git'
to yourPodfile
- Add
pod 'Decentro', '~> 1.0.1'
to yourPodfile
Your Podfile
should look like:
# Podfile
source 'https://github.com/CocoaPods/Specs.git'
target 'Example' do
pod 'Decentro', '~> 1.0.1'
end
- Run
pod install
❯ pod install
Analyzing dependencies
Downloading dependencies
Installing Decentro 1.0.1
Generating Pods project
Integrating client project
Pod installation complete! There is 1 dependency from the Podfile and 2 total pods installed.
import Decentro
let apiKey = ProcessInfo.processInfo.environment["API_KEY"]!
DecentroAPI.customHeaders = [
"client_id": apiKey,
]
let apiKey = ProcessInfo.processInfo.environment["API_KEY"]!
DecentroAPI.customHeaders = [
"client_secret": apiKey,
]
let apiKey = ProcessInfo.processInfo.environment["API_KEY"]!
DecentroAPI.customHeaders = [
"module_secret": apiKey,
]
let apiKey = ProcessInfo.processInfo.environment["API_KEY"]!
DecentroAPI.customHeaders = [
"provider_secret": apiKey,
]
let generatePaymentLinkRequest = GeneratePaymentLinkRequest(referenceId: "referenceId_example", payeeAccount: "payeeAccount_example", amount: 123, purposeMessage: "purposeMessage_example", generateQr: 123, expiryTime: 123, customizedQrWithLogo: 123, generateUri: 123) // GeneratePaymentLinkRequest |
// Generate payment link
CollectionsAPI.generatePaymentLink(generatePaymentLinkRequest: generatePaymentLinkRequest) { (response, error) in
guard error == nil else {
print(error!)
return
}
if response != nil {
dump(response)
}
}
All URIs are relative to https://in.staging.decentro.tech
Class | Method | HTTP request | Description |
---|---|---|---|
CollectionsAPI | generatePaymentLink | POST /v2/payments/upi/link | Generate payment link |
CollectionsAPI | getTransactionStatus | GET /v2/payments/transaction/{transaction_id}/status | Get transaction status |
CollectionsAPI | issueCollectRequest | POST /v2/payments/collection | Issue collect request |
CollectionsAPI | issueUpiRefund | POST /v2/payments/upi/refund | Issue UPI Refund |
CollectionsAPI | validateUpiHandle | POST /v2/payments/vpa/validate | Validate UPI handle |
- GeneratePaymentLink400Response
- GeneratePaymentLinkRequest
- GeneratePaymentLinkResponse
- GeneratePaymentLinkResponseData
- GeneratePaymentLinkResponseDataPspUri
- GetTransactionStatusResponse
- GetTransactionStatusResponseData
- GetTransactionStatusResponseError
- IssueCollectRequest400Response
- IssueCollectRequestRequest
- IssueCollectRequestResponse
- IssueCollectRequestResponseData
- IssueUpiRefund400Response
- IssueUpiRefundRequest
- IssueUpiRefundResponse
- IssueUpiRefundResponseData
- ValidateUpiHandle400Response
- ValidateUpiHandleRequest
- ValidateUpiHandleResponse
- ValidateUpiHandleResponseData
- Type: API key
- API key parameter name: client_id
- Location: HTTP header
import Decentro
let apiKey = ProcessInfo.processInfo.environment["API_KEY"]!
DecentroAPI.customHeaders = [
"client_id": apiKey,
]
- Type: API key
- API key parameter name: client_secret
- Location: HTTP header
import Decentro
let apiKey = ProcessInfo.processInfo.environment["API_KEY"]!
DecentroAPI.customHeaders = [
"client_secret": apiKey,
]
- Type: API key
- API key parameter name: module_secret
- Location: HTTP header
import Decentro
let apiKey = ProcessInfo.processInfo.environment["API_KEY"]!
DecentroAPI.customHeaders = [
"module_secret": apiKey,
]
- Type: API key
- API key parameter name: provider_secret
- Location: HTTP header
import Decentro
let apiKey = ProcessInfo.processInfo.environment["API_KEY"]!
DecentroAPI.customHeaders = [
"provider_secret": apiKey,
]