*** title: Developer tools and resources subtitle: Explore the SDKs and tools available for developers description: >- Explore Payabli developer tools and resources including SDKs, the OpenAPI spec, a Postman collection, example applications, an MCP server, and a query CLI 'og:description': >- Explore Payabli developer tools and resources including SDKs, the OpenAPI spec, a Postman collection, example applications, an MCP server, and a query CLI keywords: >- embedded payments, developer tools, SDKs, payment API, Postman collection, MCP server, developer resources slug: developers/platform-developer-tools-overview icon: toolbox area: * Developer Tools audience: * developers hide-nav-links: true layout: overview max-toc-depth: 2 *** These developer tools aim to simplify the development experience and make Payabli the easiest payments platform to integrate with. Browse the API reference, SDKs, example applications, CLI tools, and AI-assisted development resources to help you integrate with Payabli. ## API reference The Payabli API reference provides comprehensive documentation for all Payabli API endpoints, including request and response formats, parameters, and example code snippets. * [API overview](/developers/api-reference/api-overview) — Learn about authentication, environments, rate limits, and best practices for using the Payabli APIs * [API changelog](/changelog/api-changelog) — See the latest updates and changes to the Payabli API. ### OpenAPI specification Download the full Payabli OpenAPI specification for use with API clients, code generators, or AI coding tools. ## SDKs The Payabli SDKs offer libraries and tools for various programming languages to help you integrate with Payabli's APIs. Each SDK includes documentation, examples, and utilities to streamline your development process. * [Use the C# SDK](/developers/platform-sdk-csharp-guide) — Learn how to install and use the C# SDK to develop apps * [Use the Go SDK](/developers/platform-sdk-go-guide) — Learn how to install and use the Go SDK to develop apps * [Use the Java SDK](/developers/platform-sdk-java-guide) — Learn how to install and use the Java SDK to develop apps * [Use the PHP SDK](/developers/platform-sdk-php-guide) — Learn how to install and use the PHP SDK to develop apps * [Use the Python SDK](/developers/platform-sdk-python-guide) — Learn how to install and use the Python SDK to develop apps * [Use the Ruby SDK](/developers/platform-sdk-ruby-guide) — Learn how to install and use the Ruby SDK to develop apps * [Use the Rust SDK](/developers/platform-sdk-rust-guide) — Learn how to install and use the Rust SDK to develop apps * [Use the TypeScript SDK](/developers/platform-sdk-typescript-guide) — Learn how to install and use the TypeScript SDK to develop apps ## MCP server The Payabli Model Context Protocol (MCP) server connects your AI agents to Payabli's documentation and SDK references. Learn how to use the Payabli MCP server to integrate with AI workflows ## Example apps and demo code We maintain a collection of example applications and demo code to help you get started with Payabli. ### Boarding examples A simple application that demonstrates how to drive merchant boarding using the Payabli API. ### Embedded components These demos and examples showcase how to use Payabli's embedded components in various frameworks and workflows. * [Temporary token flow demo](https://github.com/payabli/examples/tree/main/temp-token) — A demo application that shows how to use the temporary token flow with embedded components for sophisticated payment flows. * [Vue.js integration example](https://github.com/payabli/examples/tree/main/vue-integration) — A simple Vue.js application that demonstrates how to integrate Payabli's embedded payment components. * [React integration example](https://github.com/payabli/examples/tree/main/react-integration) — A simple React application that demonstrates how to integrate Payabli's embedded payment components. * [Embedded component playground](https://playground.payabli.com/) — An interactive playground for testing and experimenting with Payabli's embedded payment components. ## Other tools and resources These other tools can help you use Payabli's APIs more effectively. * [Postman collection](/developers/platform-postman-collection) — Download a Payabli Postman collection to get testing fast * [Query CLI app](/developers/platform-developer-query-cli) — Set up and use Payabli's Query CLI app to run queries against your Payabli data * [Subscription utility code](/guides/pay-in-developer-subscriptions-utilities) — Use example code to enhance your subscription management via the API *** title: Getting started for developers subtitle: Learn how to build a world-class payments integration with Payabli description: >- Launch your payment integration faster with this quickstart. Learn integration options, key concepts, testing tools, and the path from sandbox to production 'og:description': >- Launch your payment integration faster with this quickstart. Learn integration options, key concepts, testing tools, and the path from sandbox to production keywords: >- embedded payments, payment processing, accept payments, vendor payments, payables automation, payment operations, merchant onboarding, API integration, getting started slug: developers/platform-developer-quickstart icon: play area: * Pay Ops * Pay In * Pay Out audience: * developers *** {/* vale Payabli.We = NO */} {/* rule off for a Quickstart */} Welcome to Payabli! This guide gives you the foundational knowledge you need to get started with your Payabli integration. Taking the time to read through this page now to get oriented can help you get started even faster with Payabli. This guide starts off with the basic process between signing up with Payabli and getting your first merchant on board. Then, in [Learn the lingo](#learn-the-lingo), we cover some Payabli concepts that people new to Payabli may have trouble understanding at first. In the [Tokens and test accounts](#tokens-and-test-accounts) section, we briefly cover some tools you'll need to build and test your integration. Okay, let's get started. ## The basics, start to finish Your goal with Payabli is to go live, onboard your merchants, and start monetizing your money in and money out transactions. The process between signing up and going live looks like this: Payabli offers a couple of ways to integrate with our products. You can pick one, or you can use a hybrid approach. These options have different required resources, security implications, features, and integration challenges. **Direct access APIs** Accept payments, manage customers and subscriptions, build products, address payment disputes, and onboard merchants while maintaining total control over your user experience. This method may require more work from you to meet PCI compliance. **Prebuilt embedded UI components** Seamlessly embed intuitive payment forms that securely capture payment data to generate a token. The token replaces sensitive cardholder or bank account data you can use with the direct access APIs to make transactions. This method dramatically reduces the PCI compliance footprint, with minimal impact to the customer experience. **Reporting and statistics APIs** Use webhooks to receive near real-time notifications of events happening on a processing account. Use webhooks alongside the Query API to let software partners to pull detailed payments data from the Payabli platform. You can also use the statistics API to build rich dashboards and analytics into your system. During your integration kickoff, we give you access to the sandbox environment. You'll learn more in your integration kickoff, but the idea is to use the sandbox to build Payabli into your product and test it. The sandbox lets you: * Make test payments. * Simulate boarding paypoints and managing a portfolio. * Customize Payabli's embedded components to mimic your UX. * Set up payment devices and test card-present transactions. * Experiment with reports and notifications. The docs can really help you understand what features are available to you and how you can include them with your integration. After you've tested thoroughly, our solution engineering team certifies your integration and gives you production access. When your integration is live, you can start boarding merchants. Merchants must apply using a boarding link that's generated from a boarding template, when they submit the form, it becomes a boarding application, and Payabli works on underwriting and will either approve or deny the merchant. When approved, a boarding application converts the merchant into a paypoint, which can then process payments with Payabli. This is just barely scratching the surface of the merchant boarding process, so see [Board Merchants](/guides/pay-ops-boarding-overview) to learn more. *** ## Learn the lingo Before you start building, we recommend that you get to know some of Payabli's terminology by reading the [comprehensive glossary](/guides/platform-payment-glossary). Let's go over the terms you'll see a lot during your integration. ### Entities Entities make up Payabli's hierarchy. You add and manage entities with PartnerHub and the API. Entities include paypoints, organizations, customers, and vendors. * Paypoints are merchants. * Organizations are used group and manage paypoints. * Customers are the people spending money with your merchants. * Vendors are the folks you and your paypoints pay for goods and services (like the carpet cleaners, office supply folks, and so on). This is just a high-level overview of entities, so you can learn more about them in the [Entities guide](/guides/platform-entities-overview). ### Entrypoint Entrypoint, entry, and entry name all come up a lot during your integration journey. An entrypoint is a Payabli-generated alias that identifies a paypoint or organization. When you make an API call, we use the `entry` value to identify the paypoint or organization the request should belong to, and almost every request includes an entrypoint value. You can learn more about entrypoints and learn how to find them with the API and in PartnerHub in [Entrypoint Overview](/developers/api-reference/api-overview#entrypoint-vs-entry). ### Boarding There are some boarding terms you'll encounter during your integration. * **Boarding**: the process of enabling a merchant to make and accept payments with Payabli. At the end of a successful boarding process, the merchant becomes a paypoint. * **Boarding template**: the basic template for the form that your merchants use to apply to become a paypoint. * **Boarding link**: a link that includes a form, based off a boarding template, that you send to a merchant to have them apply. * **Boarding application**: a boarding link that has been filled out and submitted to Payabli for underwriting. This is the item that passes through the approval process. * **Underwriting**: Payabli underwrites, or vets, each merchant to make sure that they should be able to process payments with us.
Send boarding link Send merchants a boarding link that's created using your boarding template.
Merchant applies The merchant fills out and submits the application, and e-signs the agreement.
Underwriting Payabli reviews and decides on the application.
Paypoint created If the merchant's application is approved, the Payabli team converts them to a paypoint.
Learn more about the process in [Board Merchants](/guides/pay-ops-boarding-overview). *** ## Tokens and test accounts This section covers where you do all your testing, what you need to know about API tokens, and where you can find test data. ### Environments During your integration kickoff, you receive access to a sandbox environment. This is where you do all your integration work and testing before you take your integration live and get access to a production environment. Learn more about [Environments](/developers/api-reference/api-overview#environments.mdx). ### API tokens You use API tokens to authenticate with the API. There are several different kinds of tokens, but the kind you will be working with the most is called an *organization token*. You'll get your sandbox token during your integration kickoff, but you can also manage tokens in PartnerHub on the *Developers* page. Some endpoints require an application token, which you can get from our Support team if needed. Endpoints that require application tokens are noted in the API reference. Learn more about [API Tokens](/developers/api-reference/api-overview#authentication). ### Test cards and accounts Payabli provides card and account numbers to run test transactions. See the full list in [Payment Methods for Testing](/guides/test-accounts-reference). ### Test paypoints The Payabli team sets up your first paypoint in the sandbox. When you're ready to test merchant boarding flows, you need to let us know so we can move your boarding application through a mock underwriting process in sandbox. When we approve your test boarding application, it creates a new paypoint. {/* vale Payabli.We = YES */} ## Related resources See these related resources to help you get the most out of Payabli. * **[Payment glossary](/guides/platform-payment-glossary)** - Understand common terms used in Payabli and across the payments industry * **[Payment methods for testing](/guides/test-accounts-reference)** - Use these payment methods to test your integration with Payabli * **[Boarding overview](/guides/pay-ops-boarding-overview)** - Learn how merchant boarding works in Payabli * **[Entities overview](/guides/platform-entities-overview)** - Understand how entities like organizations, suborganizations, paypoints, customers, and vendors work in Payabli *** title: Integration testing guide subtitle: Learn how to test your Payabli integration description: >- Validate your Payabli integration using test credentials, sandbox environments, and simulated transaction scenarios. Cover card payments, ACH, and boarding 'og:description': >- Validate your Payabli integration using test credentials, sandbox environments, and simulated transaction scenarios. Cover card payments, ACH, and boarding keywords: >- embedded payments, integration testing, sandbox environment, test credentials, payment testing, developer tools, API testing slug: developers/platform-developer-testing-guide icon: vial area: * Pay Ops * Pay In * Pay Out audience: * developers * partners *** Test Payabli's APIs and features in the sandbox environment before going live with your Payabli integration. You need a Payabli sandbox account to do any testing. ## Pay In This section explains how to test Payabli's Pay In features in the sandbox environment. ### Process transactions You can create transactions with the API or Payabli's embedded components. To create a transaction via the API, see [Make a sale transaction](/guides/pay-in-developer-transactions-create). To create a transaction via Payabli's embedded components, see [Embedded components overview](/guides/pay-in-components-overview). You can simulate declined transactions in the sandbox environment by using Payabli's provided test cards. See [test accounts](/guides/test-accounts-reference) for more information. ### Cancel transactions You can cancel a transaction in the sandbox environment by voiding, refunding, or reversing it: * Void: If the transaction isn't settled, you can void it to prevent the transaction from settling. * Refund: If the transaction is settled, you can refund it and send the money back to the account holder. * Reversal: Automatically void or refund the transaction based on settlement status. See [Cancel a pay in transaction](/guides/pay-in-developer-transactions-cancel) for more information on cancelling transactions. By default, transactions are settled at 9:00 PM UTC daily. If you want to change the time that transactions are settled, contact your Payabli solutions engineer. ### Handle disputes Chargebacks and ACH returns are dispute events that occur when a customer disputes a transaction in a production environment. To test chargebacks and ACH returns in the sandbox environment, follow these steps: Create a webhook notification for the `ReceivedChargeback` or `ReceivedAchReturn` event. See [Manage notifications](/guides/pay-ops-developer-notifications-manage) for more information. Your app should handle the webhook notification when it's received via an HTTP request. This includes parsing the notification data and triggering behavior based on the event type. Contact your Payabli solutions engineer to trigger a chargeback or ACH return in the sandbox environment. This sends a webhook notification to your app that you can handle. In a production environment, these events are automatically triggered when a customer disputes a transaction. ### Test payment funding statuses All pay in transactions have a payment funding status. The payment funding status indicates where a transaction is in the settlement process. Transactions in the sandbox environment automatically progress through the following funding statuses: 1. Pending - This transaction is in an open batch. 2. In Transit - This transaction is in a closed batch that's being routed to the banks. 3. Transferred - The funds are being transferred to the merchant's bank account. 4. Funded (settled) - The funds are in the merchant's bank account. If you need to test how your app handles the following funding statuses, contact your Payabli solutions engineer: * Exception * ACH Return or Chargebacks * Held * Released See [Payment funding status](/guides/pay-in-status-reference#payment-funding-status) for more information. ## Pay Out This section explains how to test Payabli's Pay Out features in the sandbox environment. ### Handle payouts Payouts are expenses that you pay to your vendors. In Payabli, there are two steps for handling payouts: 1. Authorizing - Reserves funds for a payout. 2. Capturing - Flags authorized funds for batch processing. After a payout is authorized, the funds are reserved and can't be used for other payouts. After a payout is captured, the funds are transferred to the vendor's bank account during the next batch processing window. To learn more about handling payouts, see [Manage payouts with the API](/guides/pay-out-developer-payouts-manage). ### Manage vendors Vendors are entities that receive funds from your payouts. You can reference vendors in payouts and bills to organize and track expenses. Before you can reference a vendor in a payout or bill, you must create the vendor. See [Manage vendors with the API](/guides/pay-out-developer-vendors-manage) for more information on creating and managing vendors. ### Manage bills In Payabli, bills represent a bill from a vendor that a paypoint is expected to pay. To create a bill via the API, see [Create bill](/developers/api-reference/bill/add-bill). After you've created a bill, you can approve it for payment, update it, or delete it. See [Manage bills with the API](/guides/pay-out-developer-bills-manage) for more information. ## Pay Ops This section explains how to test Payabli's Pay Ops features in the sandbox environment. ### Board merchants Boarding is the process of enabling paypoints to process payments via Payabli. There are four stages in the boarding process: The paypoint must send a boarding link to the prospective merchant. To learn more about creating and sending boarding links, see [Send prefilled boarding applications](/guides/pay-ops-developer-boarding-send-prefilled-apps). The merchant fills out and submits the boarding application. The merchant also e-signs the agreement during this step. As merchants submit boarding applications in the sandbox environment, they automatically move from the "Submitted" status to the "Underwriting" status. If you need to test other boarding application statuses, or create new paypoints from boarding applications, contact your Payabli solutions engineer. In a production environment, Payabli reviews the merchant's application and decides how to proceed with it. After a merchant is approved in underwriting in a production environment, a new paypoint is created. To create paypoints from boarding applications in the sandbox environment, contact your Payabli solutions engineer. See [Board merchants](/guides/pay-ops-boarding-overview) for more information. ## Related resources See these related resources to help you get the most out of Payabli. * **[Payment methods for testing](/guides/test-accounts-reference)** - Use these payment methods to test your integration with Payabli * **[Pay In statuses](/guides/pay-in-status-reference)** - Learn about Pay In (money in) statuses * **[Pay Out statuses](/guides/pay-out-status-reference)** - Learn about Pay Out statuses * **[Boarding overview](/guides/pay-ops-boarding-overview)** - Learn how merchant boarding works in Payabli * **[Send prefilled boarding applications](/guides/pay-ops-developer-boarding-send-prefilled-apps)** - Learn how to send prefilled boarding applications to prospective merchants * **[Embedded components overview](/guides/pay-in-components-overview)** - Learn how to use Payabli's embedded components to create customized checkout experiences without handling sensitive payment information yourself * **[Manage notifications](/guides/pay-ops-developer-notifications-manage)** - Learn how to use the Payabli API to add notifications and automated reports for important events *** title: Payment methods for testing subtitle: Use these payment methods to test your integration with Payabli icon: toolbox slug: guides/test-accounts-reference area: * Pay In subArea: * Reference audience: * developers * partners description: >- Test your payment integration with sandbox card numbers, ACH accounts, and decline scenarios. Simulate successful transactions, declines, and CVV test failures 'og:description': >- Test your payment integration with sandbox card numbers, ACH accounts, and decline scenarios. Simulate successful transactions, declines, and CVV test failures keywords: >- embedded payments, payment processing, accept payments, test cards, sandbox testing, payment testing, test accounts, test data, integration testing, sandbox environment *** Use these test cards and accounts to simulate transactions in your sandbox. You can use these example cards and accounts to make test transactions via the API or any of Payabli's hosted payment solutions, like the virtual terminal or payment pages. ## Simulate a successful transaction Use these test cards and accounts for transactions in sandbox. ### Cards Use these with any future expiration date.
Payment Method Card Number CVV
Visa 4012000098765439 999
Mastercard 5146315000000055 998
Mastercard BIN 2 2223000048400011 998
Discover 6011000993026909 996
American Express 374101000000608 or 371449635392376 9997
Diner's Club 36256000000725 123
JCB 3566000000000000 123
### ACH Use this with any account type. | Payment Method | Account Number | Routing Number | | -------------- | -------------- | ------------------------------------------- | | ACH | 123123123 | Any real routing number, such as 102103407. | ## Simulate a decline You can use test cards to simulate declines. This is useful for testing how your application handles declined transactions. ### Decline rate limiting Using a test card repeatedly in a short period can sometimes cause it to be blocked. As a best practice, Payabli recommends adhering to the fraud control limits. See [fraud control](/developers/api-reference/api-overview#rate-limits) for more information. Reach out to your Payabli Solution Engineer with any questions or issues related to testing declines. ### Transaction declines You can simulate a transaction decline by using the following card in a transaction request with any future date for the expiration date:
Payment Method Card Number CVV
Visa 4532802195368947 999
The transaction request should return a decline response like this: ```json { "responseText": "Declined", "isSuccess": false, "pageIdentifier": null, "responseData": { "authCode": null, "referenceId": "124-d541b0a9d1774bf3871f1d967abaaaaaa", "resultCode": 2, "resultText": "201: Do not honor. The customer’s issuing bank is unwilling to accept the transaction.. DECLINED", "avsResponseText": null, "cvvResponseText": null, "customerId": 12345, "methodReferenceId": null } } ``` ### Stored method declines To simulate a decline when charging a stored payment method, you can store a payment method with any of the following test cards and a future expiration date. The stored payment method can be charged with an amount of **\$0.20 (20 cents)** to cause a declined transaction.
Payment Method Card Number CVV
Visa 4012000098765439 999
American Express 374101000000608 or 371449635392376 9997
The request to charge the stored payment method should return a decline response like this: ```json { "responseText": "Declined", "isSuccess": false, "pageIdentifier": null, "responseData": { "authCode": null, "referenceId": "124-d541b0a9d1774bf3871f1d967abaaaaaa", "resultCode": 2, "resultText": "201: Do not honor. The customer’s issuing bank is unwilling to accept the transaction.. DECLINED", "avsResponseText": null, "cvvResponseText": null, "customerId": 12345, "methodReferenceId": null } } ``` ### Invalid CVV declines To simulate a decline due to an invalid CVV, you can use any of the following test cards with an incorrect CVV:
Payment Method Card Number CVV
Visa 4012000098765439 Anything but 999
Mastercard 5146315000000055 Anything but 998
Mastercard BIN 2 2223000048400011 Anything but 998
Discover 6011000993026909 Anything but 996
American Express 374101000000608 or 371449635392376 Anything but 9997
The transaction request should return a decline response like this: ```json { "responseText": "Declined", "isSuccess": false, "pageIdentifier": null, "responseData": { "authCode": null, "referenceId": "226-ab732d2a1c7e4117a32133f9e92673b2", "resultCode": 2, "resultText": "850: AVS or CVV failed.. DECLINED", "avsResponseText": "AVS not available", "cvvResponseText": "CVV2/CVC2 no match", "customerId": 1799, "methodReferenceId": null } } ``` ## Related resources See these related resources to help you get the most out of Payabli. * **[Pay In schemas](/guides/pay-in-schemas-overview)** - Learn about Pay In (money in) transaction schemas * **[Pay In statuses](/guides/pay-in-status-reference)** - Learn about Pay In (money in) statuses *** title: API overview icon: code subtitle: >- Learn about authentication, environments, rate limits, and best practices for using the Payabli APIs description: >- Explore the Payabli API reference with guides on authentication, environments, rate limits, pagination, and best practices for building payment integrations keywords: >- embedded payments, payment API, API reference, API documentation, authentication, rate limits, environments, developer guide 'og:description': >- Explore the Payabli API reference with guides on authentication, environments, rate limits, pagination, and best practices for building payment integrations slug: developers/api-reference/api-overview area: * Developer Tools audience: * developers *** Welcome to the Payabli API reference. Here you'll find all the information you need for using the Payabli APIs. ## Authentication The Payabli API uses secure API tokens to authenticate requests. This guide explains how to authenticate, the different API tokens you may use, and how to create and manage basic API tokens. Note that API tokens are different than [payment method tokens](/guides/platform-tokenization-overview). API tokens are used for authentication, and payment method tokenization exchange sensitive payment method information for secure tokens. Your API tokens carry privileges, so be sure to keep them secure! **Don't share your private API tokens** in public areas such as GitHub, client-side code, or public domains. When you authenticate to the API, send the API token in the request header with the key **requestToken**. ```bash title="Example header" {5} curl --request POST \ --url 'https://api-sandbox.payabli.com/api/Endpoint'\ --header 'accept: application/json' \ --header 'content-type: application/*+json' \ --header 'requestToken: ' ``` You must make all API requests over HTTPS. API requests without authentication will fail. ### Create and manage API tokens You can create and manage your own API tokens in PartnerHub. 1. Navigate to **Developers > API Tokens**, then click **Create API Token**. 2. In the modal, configure your API token. See the configuration options table below. 3. When finished, save your work.
Configuration option Description
Token Mode **Public** tokens are for embedded components, including Creator components. **Private** tokens are for Payabli APIs and payment devices.
Token Type The organization API token type is the most commonly used, and gives partners and paypoints access to most endpoints. The application API token is more advanced, and is used for authentication and managing entities. You rarely need to use an application API token. See the [API Token Types](#api-token-types) section for more information.
Token Lifetime API tokens can have a lifetime of between 1 and 24 months. Remember that you can delete unused or compromised API tokens at any time from the dashboard.
IP Restrictions Use this option to create an allowlist of IP addresses that can make requests with this API token. Leaving this option blank allows **all** IP addresses to make requests with this API token.
Creator Token? Select **Yes** to use this API token with Creator components. The API token type must be **Public** . Creator API tokens require that you configure domain restrictions.
Domain Restrictions Only available with Creator API tokens. For security, you must add the domains that you embed Creator components on. For example, if they're embedded on `https://app.myproduct.com` , then add `https://app.myproduct` here.
Description A descriptive name for the API token. This description appears in the dashboard and helps identify the API token.
To view or delete API tokens, navigate to **Developers > API Tokens**, then click the **Action** column of a token you want to manage. ### API token types To enhance security, Payabli has several different types of API token, each with different scopes and lifetime. The organization token is the most basic and most commonly used API token used in the platform. Any organization or paypoint with an **organization token** has access to most API functions and endpoints. You can view and manage these API tokens in PartnerHub. Payabli has two kinds of organization API tokens: * **Private Token**: Private tokens are for making API calls and have the highest level of security. * **Public Token**: Public tokens are for adding Payabli's embeddable components in your user interface. These tokens are publicly readable. You can't access API endpoints related to management and authentication services for users with an organization token. To access to those services, you need an **application token**. The Payabli team generates application API tokens for partners that are using API endpoints for authentication and managing entities. For example, you need this kind of token if you are building your own portals for paypoints, or any solution that involves users authenticating to Payabli outside of PartnerHub or a PayHub. If you are working outside of a PayHub or PartnerHub, the Payabli API requires you to retrieve a user API token before performing certain actions. These tokens add an extra layer of security for managing paypoints, managing users stored in Payabli, getting access to merchant documents, and using authentication services. If you are performing these activities within PartnerHub or a PayHub, you don't need to generate this token. You need an application API token to generate a user API token. User API tokens are valid for 120 minutes after creation, but expire after 1800 seconds (30 minutes) of inactivity. How to generate a user API token To generate a [user API token](/developers/api-reference/user/authenticate-user) you need: 1. Application API token (provided by the Payabli team to the Partner or Merchant). 2. User email and user password (the user's Payabli login credentials). ```bash curl --location --request POST 'https://api-sandbox.payabli.com/api/User/auth' \ --header 'requestToken: a.thisistheapplication.token' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --data-raw '{ "email": "useremail@here.com", "psw": "xxxxxxxxxx" }' ``` Temporary API tokens are generated by services or endpoints related mainly to resetting passwords, multi-factor authentication (MFA), and activities without authentication that require approved security levels, like payment pages. Temporary tokens can be used for only one request in specific endpoints. ## Environments Payabli offers two environments: a sandbox environment for development and a production environment to bring your Payabli integration live. ### Sandbox Use the sandbox environment to build your payments integration without having to charge actual payments and settle bank accounts. Test and run unlimited transactions and play around with Payabli's tools to build your application. Payabli Client Success and Development Support give you your sandbox API token after your integration kickoff call. Sandbox API URL: `https://api-sandbox.payabli.com/api` ### Production Use the production environment to go live with your integration. Transactions in this environment charge payors and create actual settlements into bank accounts. This environment also lets you create bills and send them for actual payment. Make sure you have completed extensive testing before launching. Reach out to the Payabli team to make sure you're ready to launch. Production API URL: `https://api.payabli.com/api` ## Rate limits For security and fraud prevention, Payabli applies two different kinds of rate limits: request limits, and transaction limits (also known as fraud controls). Payabli reserves the right to alter rate limits in case of security concerns, and will communicate changes to impacted accounts. ### Request limits Payabli has request velocity limits in place to give optimal system performance, security, and fair usage. Request limits govern the number of requests a single API token can make to endpoints in a given period. Reach out to the Payabli team if you have a use case that requires limit changes.
Number of requests Period
200 Minute
3000 15 Minutes
10000 Hourly
### Fraud controls Fraud controls, also known as transaction limits, dictate the number of declines and transactions a paypoint may process within a specified period. Reach out to the Payabli team to customize transaction limits for individual paypoints.
Description Default Limit
Max number of declines per card, hourly 3
Max number of declines per IP address, hourly 3
Max declines per paypoint, hourly 10
Max declines per payor, hourly 3
Max transactions per paypoint in 15 minutes 250
Max transactions per card hourly 10
## Request timeouts The Payabli API has request timeouts. Write requests (POST, PUT, DELETE) time out after 30 seconds, and read requests (GET) time out after 90 seconds. If a request takes longer than the timeout, the API returns a `504 Gateway Timeout` error.
Request type Timeout
Write requests (POST, PUT, DELETE) 30 seconds
Read requests (GET) 90 seconds
## Preventing duplicate requests Payabli's idempotencyKey header parameter lets you give your POST requests a unique identifier so you can safely retry a request that timed out without worrying about creating duplicate objects or transactions. Using them is optional, but is a best practice to avoid creating duplicate transactions. The idempotency key is something that you must generate and include as a header parameter in POST requests. Payabli recommends using a [UUID](https://en.wikipedia.org/wiki/Universally_unique_identifier) for your tokens. When using idempotency keys, keep these considerations in mind. * Payabli retains the idempotency key for 2 minutes. After 2 minutes, you can reuse the key if needed. * If a transaction is declined because of a bad payment method, you can't correct the payment information and retry the transaction with the same idempotency key value, it fails with a `409 Conflict` error. When using an idempotency key, your request header looks something like this: ```curl curl --request POST \ --url https://api.payabli.com/api/MoneyIn/getpaid \ --header "accept: application/json" \ --header "content-type: application/*+json" \ --header "idempotencyKey: dc125696-0c78-11ee-be56-0242ac120002" \ --header "requestToken: " ``` ### 409 conflict If you send an idempotencyKey more than once before it expires, you get a `409 Conflict` response: ```bash HTTP Response: 409 Conflict Duplicated idempotencyKey: 12345 ``` If you get this error when running a payment transaction, you can [query a list of transactions](/developers/api-reference/query/get-list-of-transactions-for-an-entrypoint) to pull in any information about a transaction that was approved but timed out. ### Use webhooks to avoid duplicate transactions \[#idempotency-webhooks] Payabli recommends using webhooks to help avoid duplicate transactions. All of the [Money In webhooks](/guides/pay-ops-notifications-webhooks-overview#pay-in-events) are helpful, and the ApprovedTransaction notification will let you know when a transaction has been approved. One of the main reasons you might double-charge a card is if you tried to process the payment and received a timeout error response. In that case, you don't know if the original transaction was received, processed, or approved, and the standard course of action is to resubmit the transaction request. If you have webhooks configured, you will get a copy of the approval or decline response. You can use the response sent via webhook instead of the standard response you should have received but didn't because the request timed out. ## Entrypoint vs entry An entrypoint is an alias used to identify an organization or paypoint. When you make a call via the API or with embedded components, the entrypoint value indicates which paypoint account to use for a payment, subscription, or storing a payment method. Sometimes the terms "paypoint" and "entrypoint" are used seemingly interchangeably. A paypoint is a merchant. An entrypoint is an alias used to identify an organization or a paypoint. Sometimes the entrypoint is referred to as `entry` or `entryname` in the APIs and as Entry Name in PartnerHub and PayHub. You can get the list of active paypoints for your organization by making a request to the [List Paypoints](/developers/api-reference/paypoint/get-list-of-paypoints-for-an-organization) endpoint. You need the `entry` ID for the parent *organization* to make the request. Payabli gives you this ID in your onboarding documents. A paypoint's entrypoint is returned as `EntryName` in the response. This is the value you need to make any API calls that deal with that paypoint. ```json ... "EntryPoints": [ { "IdEntry": 100, "EntryName": "8cfec329267", ... } ] ``` You can get entrypoint names from the UI in PartnerHub. Just navigate to **Portfolio > Paypoints**, and copy the value in the **Entry Name** column for the paypoint you want to work with. *** title: API responseCode and resultCode Reference subtitle: Learn about responseCode and resultCode values returned by the API description: >- Reference guide for Payabli API responseCode and resultCode values. Understand success and error codes returned by Pay In, Pay Out, and boarding API endpoints 'og:description': >- Reference guide for Payabli API responseCode and resultCode values. Understand success and error codes returned by Pay In, Pay Out, and boarding API endpoints keywords: >- embedded payments, API response codes, error codes, payment API, result codes, API reference, troubleshooting sidebarTitle: API Responses icon: brackets-curly slug: developers/api-reference/api-responses area: * Pay In * Pay Out * Pay Ops audience: * developers * partners *** When you make an API request, a `responseCode` or `resultCode` is returned in the response, depending on the endpoint. These codes can tell you whether the action was successful, and if not, can help you troubleshoot what went wrong with your request. These codes don't cover payment errors and return codes. See [Payment Return Codes and Errors](/guides/platform-return-codes-and-errors-reference) for codes relating to payments. ## General codes
ResultCode Name Description Solution
1 Request successful The API request executed without errors There's nothing to do.
2 Request failed The API request failed due to a processor decline Check the response for the failure reason.
3 Request failed The API request failed due to a technical error Check the response for the failure reason.
10 Request initiated An asynchronous process has started successfully. There's nothing to do.
## 3000 codes
ResponseCode Name Description Solution
3001 Invalid entrypoint name Entrypoint specified in parameter doesn't exist Correct the parameter and try again.
3002 Invalid Amount Amount value is empty or negative Provide a valid amount.
3003 Invalid parameter value in request The value in parameter is incorrect Provide the correct value for parameter.
3004 Invalid TimeZone value The timezone value is invalid Provide a value between -12 and +12.
3005 Invalid paypoint ID The paypoint ID value is invalid Provide a valid paypoint ID value.
3006 Invalid user status The value provided is invalid Provide a valid status value for user (either 0, 1, or 85).
3007 The transaction cannot be refunded We can't refund this transaction because it already has an associated chargeback or return. There's no solution for this, transactions with an associated chargeback or ACH return can't be refunded. See [Chargebacks and Returns Overview](/guides/pay-ops-disputes-chargebacks-returns-overview) for more information.
3012 Invalid Amount Amount value is greater than available amount for action Provide a valid amount.
3013 Invalid Amount Amount value is different to amount in invoices Provide a valid amount.
3014 Invalid Amount Amount value is not as same as the authorized amount Please make sure that the amount in the request matches the authorized amount
3015 Invalid Total Amount Total Amount value is zero Please make sure that the total amount in the request is greater than zero
3016 Invalid Total Amount Total Amount value is less than the allowed value Please make sure that the total amount in the request is greater than 85% of the authorized amount
## 3200 codes
ResponseCode Name Description Solution
3201 Empty scope array for user The scope specified for user is empty Provide a valid scope for user.
3202 Empty access array for user The access specified for user is empty Provide a valid access array for user.
3203 Empty email address for user The email specified for user is empty Provide a valid email address for user.
3204 Duplicated email address A user with this email address exists already Provide a valid email address that isn't used in Payabli yet.
3205 Invalid scope declared by requestToken The scope provided is outside of the scope of the used API token in the request Review the scope provided in request. The platform rules don't allow scopes not included in the parent API token.
3206 Invalid access declared by requestToken The access provided is outside of the access authorized of the API token used in the request Review the access provided in request. The platform rules don't allow access not included in the parent API token.
3207 Invalid email address The email address is invalid Review the value of the email address provided in request. The email address need to follow the format specified in RFC 881.
3208 Invalid phone number The phone number is invalid Review the value of the phone number provided in request. The phone number need to satisfy the regular expression `"^[\+]?[(]?[0-9]{3}[)]?[-\s\.]?[0-9]{3}[-\s\.]?[0-9]{4,6}$"` Examples: - +1(786)111-2222 - 234.222.1234 - 111 222 2345 - 555-444-1111
3209 Invalid country code The country code is invalid Review the value of the country code provided in the request. The country code must be in ISO-3166-1-Alpha 2 format. Refer to the [ISO reference](https://www.iso.org/obp/ui/#search) for help.
3210 Invalid mail country code The mail country code is invalid Review the value of the mail country code provided in the request. The country code must be in ISO-3166-1-Alpha 2 format. Refer to the [ISO reference](https://www.iso.org/obp/ui/#search) for help.
3211 Invalid start date The start date value is invalid Provide the value in one of accepted formats: YYYY-MM-DD or MM/DD/YYYY.
3212 Invalid billing table Invalid billing table The paypoint already has a billing table. Use the update endpoint or delete the current billing table.
## 3400 codes
ResponseCode Name Description Solution
3401 Invalid Bill Number Field `BillNumber` empty Provide the `BillNumber` in the request.
3402 Duplicated Bill Number The value provided in the field `BillNumber` already exists Provide a different `BillNumber` in the request, or set the [`allowDuplicatedBills`](/developers/api-reference/moneyout/authorize-a-transaction-for-payout#request.query) query parameter to `true` to bypass validation.
3403 Missing Vendor information Vendor data missing from request Provide the minimum required data for Vendor.
3404 Invalid Vendor Number Field `VendorNumber` empty Provide the required value in request.
3405 Missing frequency value The required frequency for scheduled bill is empty Provide the required frequency value in request:- `onetime` \- `weekly` \- `every2weeks` \- `every6months` \- `monthly` \- `every3months` \- `annually`
3406 Invalid frequency value Frequency value for scheduled bill is invalid Provide the required frequency value in request:- `onetime` \- `weekly` \- `every2weeks` \- `every6months` \- `monthly` \- `every3months` \- `annually`
3407 Invalid EndDate format Date value empty or in an invalid format Provide the date value in an accepted format: YYYY-MM-DD or MM/DD/YYYY.
3408 Invalid EndDate value Date value can't before or equal to today's date Provide a valid value for `Date` field.
3409 Vendor is Inactive Can't complete the action because the Vendor status is inactive Update vendor status to active. See [Vendor Status](/guides/pay-out-developer-vendors-manage#vendor-status) for help.
3410 Invalid Bill Id The Bill identifier doesn't exist or doesn't have a valid status Provide a valid bill identifier in the request.
3411 Invalid Bill status Can't complete the action because the Bill status is invalid Verify the status of the bill before resubmitting the request. See [Bills](/guides/pay-out-schemas-overview#bill-statuses) for statuses.
3412 Bill has associated payments Can't complete the action because the bill has associated payment records Cancel the associated payments.
3413 Existing payment link for Id A payment link already exists for the provided ID Review the Payment link ID and try again.
3414 Invalid entrypoint The entrypoint associated with the bill doesn't exist Verify the entrypoint to make sure it's related to the bill.
3415 Invalid EntryPage The EntryPage associated with the paypoint doesn't exist Verify the EntryPage related to the paypoint.
3416 Missing email The vendor associated with the bill doesn't have a valid email address Verify the vendor's email address isn't empty and has a valid format.
3417 Invalid Invoice Id The Invoice identifier doesn't exist or doesn't have a valid status Provide a valid identifier value in the request.
3418 Invalid customer The Invoice doesn't have a valid customer associated with it Review the customer associated with the invoice and try again.
3419 Invoice not available The invoice status is not allowed with this action Verify the status of the invoice before resubmitting the request.
3420 Duplicated Bill Number The value provided in field `BillNumber` exists already within the Vendor Provide a different `BillNumber` in the request, or set the [`allowDuplicatedBills`](/developers/api-reference/moneyout/authorize-a-transaction-for-payout#request.query) query parameter to `true` to bypass validation.
3421 Invalid Vendor Id The Vendor identifier doesn't exist or doesn't have a valid status Provide a valid Vendor ID value in the request.
3422 Invalid Vendor Name Field `Name1` empty Provide the required value in the request.
3423 Missing address field Field `address(1)` empty Provide the required value in the request.
3424 Missing address field Field `city` in address empty Provide the required value in the request.
3425 Missing address field Field `state` in address empty Provide the required value in the request.
3426 Missing address field Field `zip` in address empty Provide the required value in the request.
3427 Invalid EIN Invalid value provided for EIN field Provide the required value in the request using the of 9 digit format.
3428 Missing email Vendor email address is required for virtual card (vCard) Verify the that vendor's email isn't empty and has a valid format.
3429 Empty transaction list List of transaction in input wasn't provided Verify that the list of transactions is provided in the request.
3430 Invalid Customer Id The Customer identifier doesn't exist or has invalid status Verify the included customer's information and try again.
3431 Empty approvals Empty approvals Provide the required value in the request.
3432 No attachments found No attachments found Provide the required attachments.
3433 Invalid orgId Invalid `orgId` Provide a valid organization ID.
3434 Invalid Level in request Invalid Level Provide a valid level for the entrypoint: `0` for partner, `2` for paypoint.
3435 Invalid Vendor Status The vendor status is invalid. Provide a valid vendor status: `0` for inactive, `1` for active, and `-99` for deleted.
3436 Duplicated vendor under entry Duplicated vendor under entry The vendor already exists under the paypoint.
3437 Invalid Year value The year value is invalid Provide the value in the accepted format: YYYY.
3438 Invalid dates The startDate cannot be greater than the endDate Provide valid `startDate` and `endDate` parameters.
3439 Invalid parameters for custom mode The custom mode must provide a valid startDate and endDate parameters Provide valid `startDate` and `endDate` parameters when using the custom mode.
## 3500 codes
ResponseCode Name Description Solution
3501 Invalid request The search field is missing, null, or empty in the request Provide a valid search field in the body request.
## 3600 codes
ResponseCode Name Description Solution
3601 Invalid payment link Id The provided payment link ID is invalid or inactive Review the payment link ID and try again.
3602 Invalid invoice/bill The provided payment link ID doesn't have a valid invoice/bill associated Review the payment link ID and try again.
3603 The entrypoint doesn't exist The provided payment link ID isn't associated to a valid entrypoint Review the payment link ID and try again.
3604 EntryPage doesn't exist The entrypoint doesn't have a valid EntryPage Verify that the entrypoint has a payment page created. Review the payment link ID and try again.
3605 Invalid vendorId or customerId A `customerId` or a `VendorId` is required for a new vCard Verify the request and provide the missing data.
3614 Subdomain doesn't exist The entrypoint doesn't have a valid subdomain Verify the entrypoint has a payment page created. Review the information in the request and try again.
## 3700 codes
ResponseCode Name Description Solution
3701 Invalid application ID Invalid application ID or doesn't exists Provide a valid application ID and try again.
3702 An error occurred while processing the request An error occurred while processing the request Try again later. If the error persists please contact your API provider.
3703 Duplicated Bank account The bank account already exists To update an existing bank account, use the edit endpoint.
3704 Invalid bank ID Invalid bank ID Provide a valid bank ID.
3705 Invalid routing number Invalid routing number Provide a valid routing number.
3706 Invalid account number Invalid account number Provide a valid account number.
3707 Invalid account type Invalid account type Provide a valid account type: Checking or Savings.
3708 Invalid bank account holder type Invalid bank accountholder type Provide a valid bank accountholder type: Personal or Business.
3709 Invalid bank account function Invalid bank account function Provide a valid bank account purpose: `0` : Deposit, `1` : Withdraw, `2` : Deposit/Withdraw
3710 Invalid bank name Invalid bank name Provide a valid bank name.
3711 Invalid account holder name Invalid accountholder name Provide a valid accountholder name.
3712 Billing ID not found Billing ID not found Provide a valid billing ID in the request.
3713 The entrypoint doesn't have a billing table The entrypoint doesn't have a billing table Create a billing table if required.
3714 Error with the billing request There is an error with the billing request Review the billing object for any missing or invalid field.
3715 Duplicated bank information The combination of bank account number, routing number and function already exists Verify the bank information or update the existing bank entity.
## 3900 codes
ResponseCode Name Description Solution
3901 Empty Text field The input field Text is empty Provide a value in required field Text.
3902 Invalid color code provided in field darkColor The hexadecimal HTML code provided is incorrect Provide a correct HTML code value. Reference [https://html-color.codes/](https://html-color.codes/)
3903 Invalid color code provided in field lightColor The hexadecimal HTML code provided is incorrect Provide a correct HTML code value. Reference [https://html-color.codes/](https://html-color.codes/)
3904 Both color codes need to be provided in fields lightColor and darkColor The hexadecimal HTML code provided is incorrect or the field is empty Provide a correct HTML code value. Reference [https://html-color.codes/](https://html-color.codes/)
3905 max length for Number field is 19 chars The string length is greater than is allowed Reduce the string length to a maximum of 19 characters.
3906 max length for Text field is 23 chars The string length is greater than is allowed Reduce the string length to a maximum of 23 characters.
3907 max length for Holder field is 30 chars The string length is greater than is allowed Reduce the string length to a maximum of 30 characters.
3908 max length for Holder1 field is 30 chars The string length is greater than is allowed Reduce the string length to a maximum of 30 characters.
3909 max length for ExpDate field is 8 chars The string length is greater than is allowed Reduce the string length to a maximum of 8 characters.
3910 max length for Cvv field is 4 chars The string length is greater than is allowed Reduce the string length to a maximum of 4 characters.
3911 Amount cannot be negative A negative value isn't accepted Provide a positive value in the input field.
3912 Invalid Theme value provided The theme name provided doesn't exists Provide a valid value in the input field.
## 4000 codes
ResponseCode Name Description Solution
4001 Invalid Xchange AccountId Invalid Xchange AccountId Provide a valid Xchange AccountId.
4002 Invalid User account Invalid User account Either the user doesn't exist or there is a problem with their token.
4003 Model cannot be null Model can't be null The entry model is null. Review and try again.
4004 The Server field cannot be null or empty The `Server` field can't be void or empty Review the `Server` field and try again.
4005 The UserId field cannot be null or empty The `UserId` field can't be void or empty Review the `UserId` field and try again.
4006 The RemotePathIn field cannot be null or empty The `RemotePathIn` field can't be void or empty Review `RemotePathIn` fields and try again.
4007 The RemotePathOut field cannot be null or empty The `RemotePathOut` field can't be void or empty Review the `RemotePathOut` field and try again.
4008 The Schedule field cannot be null or empty The `Schedule` field can't be void or empty Review the `Schedule` field and try again.
4009 The LastCheck field cannot be less than the actual date The `LastCheck` field can't be less than the actual date Review the `LastCheck` field and try again
4010 The EntryName field cannot be null or empty The `EntryName` field can't be null or empty Review the `EntryName` field and try again.
4011 The OrgType field cannot be null or empty The `OrgType` field can't be void or empty Review the `OrgType` field and try again.
4012 The Orgid field cannot be null or 0 The `Orgid` field can't be null or 0 Review the `Orgid` field and try again.
4013 The Mode field cannot be null The `Mode` field can't be void or empty Review the `Userid` field and try again.
4014 The Channel field cannot be null or 0 The `Channel` field can't be null or 0 Review the `Channel` field and try again.
4015 The content of the PKey field isn't Base64 encoded The content of the `PKey` field isn't Base64-encoded Review the `PKey` field and try again.
4016 The Organization/Paypoint has no associated token The organization or paypoint has no associated token Review the request data and try again.
4017 The data wasn't saved in the Payabli database The data wasn't saved in the Payabli database An error occurred while saving the data to the database. Contact the support team.
4018 Invalid Xchange Account Invalid Xchange account Provide a valid Xchange account and try again.
4019 The user isn't related to the organization The user isn't related to the organization The user isn't related to the organization.
4020 The configuration isn't related to the xchange account organization The configuration isn't related to the Xchange account organization The configuration isn't related to the Xchange account organization.
4021 The Type field cannot be null or different from IP, Card or PayorId The `Type` field must be `IP` , `Card` or `PayorId` and can't be null. Review the `Type` field and try again.
4022 At least one of these fields is required: Content, FraudHistoryId, or TransId At least one of these fields is required: `Content` , `FraudHistoryId` , or `TransId` Review the request and try again.
4023 The service cannot be deleted The service cannot be deleted, because there are still transactions that haven't settled yet Wait until all transactions are marked as settled, then delete the service.
4024 The service cannot be updated The service cannot be updated, because there are still transactions that haven't settled yet Wait until all transactions are marked as settled, then update the service.
4025 Purposes cannot be null Purposes is null Purposes can't be null. Review and try again.
4026 The keyword cannot be repeated A keyword is repeated Keywords can't be repeated. Review and try again.
4027 Empty input file The input file is empty The input file can't be empty. Review and try again.
4028 Empty file content Empty file content The file has no content. Review and try again.
4029 The size of the PKey File is not allowed The size of the PKey File is not allowed The size of the PKey File is not allowed. Review and try again.
4030 PKey File does not have the allowed format PKey File does not have the allowed format PKey File does not have the allowed format. Review and try again.
4031 The password and key file cannot be empty, at least one is required The password and key file cannot be empty, at least one is required The password and key file cannot be empty, at least one is required. Review and try again.
## 5000 codes
ResponseCode Name Description Solution
5004 Invalid Service Fee value Provided service fee value is less than zero Please make sure that the service fee value in the request is greater than or equal to zero.
5005 Invalid Service Fee value Provided service fee value is lesser than value agreed Review the service fee value provided in the request and try again. See [Pass-Through Fees](/guides/pay-in-fees-passthrough-overview) for more information on how fees work.
5006 Invalid Service Fee value Provided service fee value is greater than value agreed Review the service fee value provided in the request and try again. See [Pass-Through Fees](/guides/pay-in-fees-passthrough-overview) for more information on how fees work.
5009 Invalid stored method relationship The `storedMethodId` provided isn't associated with the customer provided. Review values to make sure the stored method belongs to the specified customer, and try again. See [Tokenization](/guides/platform-tokenization-overview) for more information on stored methods.
5010 Invalid chargeback ID The provided chargeback identifier does not exists in the platform. Review the value of the chargeback identifier and try again.
5011 Invalid chargeback status The chargeback status provided is not allowed Review the value of the chargeback status and try again.
5012 Invalid ACH return ID The provided ACH return identifier does not exist in the platform Verify the ACH return identifier and make sure that it's correct
5013 Invalid ACH return status The provided ACH return status is not allowed for this transaction Check the ACH return status and make sure that it's valid for this transaction
5014 Invalid transaction method The provided transaction identifier is invalid or does not correspond to a valid ACH payment Verify the transaction identifier and make sure that it corresponds to a valid ACH payment
5015 Invalid transaction ID The provided transaction identifier does not exist in the platform Verify the transaction identifier and make sure that it's correct
5016 Invalid transaction ID The transaction already has an associated return This transaction has already been returned
5017 Invalid transaction method The provided transaction identifier is invalid or does not correspond to a valid card payment Verify the transaction identifier and make sure it corresponds to a valid card payment
## 6000 codes
ResponseCode Name Description Solution
6000 Opt-in process is already pending for this customer An opt-in request has already been sent to this customer The customer must complete the opt-in process.
6001 SMS configuration is missing SMS sending isn't configured Contact Payabli Support to enable this feature.
6002 The request has failed because the user hasn't consented to communications The recipient hasn't opted-in to receiving SMS communications The customer must complete the opt-in process
6003 Invalid customer ID The provided customer identifier doesn't exist or doesn't have a valid status Provide a correct identifier value in the request.
6004 Missing or invalid phone number Phone number is required for customer consent request Verify that the customer's phone number isn't empty and has a valid format.
6005 Invalid payment link type Invalid payment link type Payment link must be for an invoice.
6006 Missing or invalid phone number Phone number is required to send a payment link Verify that the customer's phone number isn't empty and has a valid format
6007 Missing or invalid email address Email address is required to send a payment link Verify that the customer's email isn't empty and has a valid format
6008 Invalid additional email addresses One or more of the additional email addresses aren't valid Verify that the additional email addresses aren't empty and has a valid format
6009 Invalid channel Invalid communication channel value Verify that the communication channel is one of the valid options: sms or email
6010 Invalid invoice The provided payment link ID doesn't have a valid invoice associated Verify that the invoice exists and has a valid status
6101 Invalid domain ID The provided domain ID is invalid. Verify that the domain ID is correct and try again.
6103 Failed to cascade the domain An error occurred while cascading the domain. Try cascading the domain again later.
6201 No card service found for this paypoint Card service is required to enable Apple Pay. Contact Payabli for help.
6202 Cascading is not supported for this entity type. Cascading domains is allowed only for the domains owned by organizations. Use a domain owned by an organization.
6202 Card services are disabled for this paypoint Card services should be enabled to use Apple Pay. Contact Payabli for help.
6203 No card gateway found for this paypoint Card gateway is required to enable Apple Pay. Contact Payabli for help.
6204 Invalid card credentials for this paypoint Card credentials are required to enable Apple Pay. Contact Payabli for help.
6205 Apple Pay configuration update in progress for this organization There is an ApplePay configuration update in progress for this organization. Wait for the update to finish and try again.
6206 Failed to cascade organization updates An error occurred while cascading the organization updates. Try again later.
## 7000 codes
ResponseCode Name Description Solution
7001 Invalid transaction ID The provided transaction identifier doesn't exist in the platform Review the value of the transaction ID and try again.
7002 Invalid transaction status The status of the transaction doesn't allow the action requested. Verify the status of the transaction. For Void, Cancel, or Reverse the valid statuses are 1 and 11, for Refund the valid status is 1. Learn more about [Transaction Statuses](/guides/pay-out-schemas-overview#payout-transaction-statuses)
7003 Invalid payment method Stored payment methods can't be validated. Change the payment method or remove the reference to a stored payment method in the request.
7004 Invalid payment method Provided payment method can't be executed. Try a different payment method.
7005 Missing card number Field `cardnumber` in payment method object is empty Provide a valid card number in payment method object.
7006 Missing payment method The payment method object is empty Provide valid data in payment method object.
7007 Invalid payment method Stored payment method provided doesn't exist Provide valid data in payment method object.
7008 Missing payment details The payment detail object is empty Provide a valid data in payment detail object.
7009 Invalid currency code Currency code provided is invalid Provide a valid ISO 4217 currency code.
7010 Invalid card expiration date The expiration date provided is invalid Review the expiration date. Accepted formats are MM/YY and MMYY.
7011 Invalid payment method No payment instrument was provided in request Review the payment method object for any missing data.
If the payment method is card, then either a cardNumber or storedMethodId are missing.
If the payment method is ACH, then either achRouting or storedMethodId are missing or invalid.
7012 Invalid payment method Missing account or card holder in request Review the payment method object for any missing data.
7013 Invalid payment method Missing bank account number in request Review the payment method object for any missing data.
7014 Invalid payment method Invalid bank account type in request Review the payment method object for invalid data. Accepted values for bank account type are: SAVINGS or CHECKING
7015 Invalid payment method missing `achholder` or `checknumber` in check payment method Review the payment method object and payment detail object for any missing data.
7015 Invalid card number Invalid card number provided. Provide a valid card number in payment method object.
7016 Invalid CVV number Invalid CVV number provided. Provide a valid CVV number in payment method object.
7017 Invalid payment method Missing device identifier in `paymentMethod` object Review the payment method object for any missing data.
7018 Invalid payment method Invalid device identifier in `paymentMethod` object Review the payment method object for any missing data.
7019 Invalid payment method Stored payment method provided and customer don't match Provide the correct `customerId` linked to the stored payment method provided.
7020 Error in customer data Something is wrong with the customer data Review customer object for missing or invalid fields.
7021 Invalid invoice number Customer associated to payment doesn't match with referenced invoice Review customer object and invoice data provided in request.
7022 Invalid invoice action Trying to pay a scheduled Invoice Review the data provided in request and try again.
7023 Invalid invoice action Trying to pay an invoice with an invalid status Review the data provided in request and try again.
7024 Invalid invoice action Trying to pay an invoice with zero or negative amount Review the data provided in request and try again.
7025 Invalid invoice action Trying to overpay an invoice Review the data provided in request and try again.
7026 Invalid invoice number Vendor associated to payment doesn't match with referenced invoice Review vendor object and invoice data provided in request.
7027 Invalid card expiration date The expiration date provided is invalid- minimum accepted is 3 months Review the expiration date. The value must be in MM/DD/YY format.
7028 Invalid card expiration date The expiration date provided is invalid- maximum accepted is 2 years and 363 days Review the expiration date. The value must be in MM/DD/YY format.
7029 Invalid MCC value provided The MCC value is invalid Review the data provided in request and try again.
7030 Invalid TCC value provided The TCC value is invalid Review the data provided in request and try again.
7031 Invalid expense limit provided The expense limit value is invalid Review the data provided in request and try again.
7032 Invalid expense limit period provided The expense limit period value is invalid Review the data provided in request and try again.
7033 Invalid cardtoken provided The `cardtoken` value is invalid Review the data provided in request and try again.
7034 Invalid cardtoken provided The vCard is cancelled Review the data provided in request and try again.
7035 Invalid customer ID Invalid customer ID Review the data provided in request and try again.
7036 Invalid payment method Missing bank account holder or check number in request Review the payment method object for any missing data.
7037 Invalid transaction status The current status of transaction doesn't allow requested action Review status of transaction before submitting the request. Payabli doesn't accept void action for funded payments or payments with funding in transit. Refunds can't be performed for unsettled payments. Learn more about [voids and refunds](/guides/pay-in-developer-transactions-cancel#choose-a-method) .
7038 Invalid stored method type Provided stored method isn't supported by the paypoint A Universal tokenized method was provided in the request, but the target paypoint doesn't support it. Try a different payment method.
7039 Invalid stored method type Provided stored method isn't supported by the paypoint A Network tokenized method was provided in the request, but the target paypoint doesn't support it. Try a different payment method.
7040 This type of stored method cannot be used with this paypoint Review the payment method object. Only universal tokens and network tokens can be used at a payment point other than the one they belong to. Try a different payment method.
7041 Tokenization provider of stored method is incompatible with processor in paypoint Review the payment method object. The tokenization provider for needs to be the same or be compatible with payment provider Try a different payment method.
## 8000 codes
ResponseCode Name Description Solution
8001 Invalid Token in request Provided token is in use under different service Remove provided token from other services before executing the action.
8002 Invalid parameter in request Requested component type requires a valid subType Provide a valid subType in request.
8003 File system service is not available The server is not ready to handle the request Please try again, if the error persists contact your administrator.
8012 Invalid amount Invalid amount value provided for action Review amount provided. Transactions with split funding instructions don't allow partial capture.
8013 Invalid split funding instructions Missing or invalid split instructions provided for action Review the instructions provided for the action. Review amounts and recipients.
8014 Invalid split funding instructions Invalid Amount in split instruction. Amount provided greater than balance in split Review the instructions provided for the action. Review amounts and recipients.
8016 Invalid split funding instructions Invalid Amount in split instruction. Amount provided cannot be negative Review the instructions provided for the action. Review amounts and recipients.
8015 Invalid split funding instructions Invalid Amount in split instruction. Amount provided is different to sum of amounts in split instructions Review the instructions provided for the action. Review amounts and recipients.
8082 Invalid split funding instructions Empty recipient value in split funding instructions Review the instructions provided for the action. Make sure all recipients for the split are provided.
8083 Invalid split funding instructions Provided recipient value in split funding instructions is outside of scope of the origination. Review the instructions provided for the action. Review all the recipients for split are in the same level under the same parent organization.
8084 Invalid split funding instructions Invalid Amount in split instruction. Amount provided cannot be negative or zero Review the instructions provided for the action. Review amounts and recipients.
8086 Invalid split funding instructions Provided recipient does not have a configured funding account Review the instructions provided for the action. Review the recipients.
8088 Invalid split funding instructions Origination for split need to be included in split instructions Review the instructions provided for the action. Review the recipients.
8099 Invalid split funding instructions Origination entry point does not have split funding capability enabled Contact Support to have split funding enabled.
## 9000 codes
ResponseCode Name Description Solution
9001 Invalid Authorization Token Token in input doesn't have access to Entity in scope or Token isn't allowed to execute requested action. Use the authorized API token for the request. Review the reference to the entity in request parameter (entry name, paypoint ID, organization ID, signing) is correct and is within the token scope.
9002 Unauthorized Token User or Customer entity doesn't have permission to the requested action. Verify permissions assigned to the user or customer.
9003 Unauthorized Token Token type or origin IP address aren't accepted by action Use the correct API token for action. For web components the token type is different of the direct API token. Verify if your token has IP restriction. See [Authentication](/developers/api-reference/api-overview#authentication) for more information on token types and restrictions.
9004 Inactive Paypoint The paypoint isn't active in the platform. Reach out to the support team to clarify the status of your paypoint.
9005 Blocked by Fraud Control The card or the origin IP of request is blacklisted in the platform Reach out to the support team to clarify the status of your paypoint.
9006 Unauthorized Token Expected Validation code is missing or invalid Use the correct validation code for action. Verify value provided in CAPTCHA for payment pages.
9007 Invalid entryId The provided entry ID is invalid Review the data provided in request and try again.
9008 Invalid orgId parameter Invalid `orgId` parameter Provide a valid `orgId` parameter.
9009 Invalid entry point name Invalid entrypoint name Review the entry point name in the request and try again.
9010 Invalid Fraud History Id Invalid Fraud History ID Provide a valid ID parameter.
9011 Unauthorized Token Domain Origin not in scope Review your domain restrictions to see the domain originating the request is included in scope.
9012 Invalid Fraud Blacklist Id Invalid Fraud Blacklist ID Invalid Fraud Blacklist ID.
9013 Invalid Tier Id Invalid Tier Id Provide a valid ID parameter.
9014 Invalid Tier Name Invalid Tier Name Provide a valid Name parameter.
9051 Fraud alert A velocity fraud alert condition was triggered Verify your request and fraud limits with the Support team.
*** title: Pay In transaction APIs v2 description: >- Explore v2 Pay In transaction APIs with enhanced responses including unified response codes and detailed transaction data for improved processing visibility 'og:description': >- Explore v2 Pay In transaction APIs with enhanced responses including unified response codes and detailed transaction data for improved processing visibility subtitle: >- Learn how to use version 2 of Payabli's Pay In transaction APIs with enhanced standardized responses sidebarTitle: V2 Transaction APIs icon: brackets-curly slug: developers/api-reference/moneyIn/v2 keywords: >- embedded payments, transaction APIs, Pay In, payment processing, unified response codes, API v2 area: * Pay In subArea: * Making Transactions audience: * developers * partners *** The v2 Pay In transaction APIs have two major improvements over Payabli's core payment processing endpoints: unified response codes and automatic transaction details in responses. ## What's different in v2 These next sections cover the main differences between v1 and v2 transaction APIs. All v2 endpoints return responses using a standardized code format that makes it easier to understand transaction outcomes and handle them consistently across your application. ### Response code categories v2 APIs use a three-tier code structure that groups outcomes by type: * **A codes (A0000-A0099)**: Approved transactions: payment was successfully processed * **D codes (D0100-D2999)**: Declined transactions: payment was rejected by the card network or issuer * **E codes (E3000-E9999)**: Error conditions: technical or validation errors prevented processing This structure lets you handle responses at different levels of specificity. For example, you can check if a code starts with "A" for any approval, or check for specific codes like "D0225" (insufficient funds) to provide targeted messaging. See the [Pay In unified response codes reference](/guides/pay-in-unified-response-codes-reference) for the complete list of all codes for errors, approvals, and declines. You can explore realistic response examples for v2 in the individual endpoint references for each of the v2 transaction endpoints. ### Approved and Declined response format Every v2 Approval and Decline response includes four key fields that offer context about the outcome: * `code`: The standardized response code (for example, `A0000`, `D0110`, `E5001`) * `reason`: Human-readable reason for the outcome (for example, "Approved", "Insufficient Funds") * `explanation`: Detailed explanation of what happened and why * `action`: Recommended next steps for handling this outcome These fields are consistent across all v2 endpoints, making it easier to build reusable error handling and user messaging logic. This is an example of a successful v2 transaction response: ```json { "code": "A0000", "reason": "Approved", "explanation": "Approved by card network or card issuer.", "action": "No action required.", "data": { // transaction details object here }, "token": null } ``` Decline responses follow the same structure, with appropriate `code`, `reason`, `explanation`, and `action` fields. All decline and approval responses automatically include complete transaction details in the response `data` object, eliminating the need for a separate API call to retrieve transaction information. ### Error response format Error responses (E codes) follow RFC 7807 Problem Details format, providing structured information about what went wrong: * `type`: URI reference to documentation about this error type * `title`: Short error title (for example, "Bad Request") * `status`: HTTP status code (for example, 400, 500) * `detail`: Description of the specific error * `instance`: The request URL that caused the error * `errors`: Field-specific validation errors (for 400 Bad Request responses) This standardized format makes it easier to debug issues and give helpful feedback to users. When request validation fails, v2 endpoints return a 400 Bad Request response following RFC 7807 Problem Details format: ```json { "type": "https://docs.payabli.com/developers/references/pay-in-unified-response-codes", "title": "Bad Request", "status": 400, "detail": "Invalid CVV number", "instance": "/api/v2/MoneyIn/auth", "code": "E7016", "errors": { "paymentMethod.cvv": [ { "message": "Invalid CVV number provided", "suggestion": "Provide a valid CVV number in payment method object" } ] }, "token": null } ``` The `errors` field provides detailed validation information for each field that failed validation, making it easier to identify and fix issues in your request. ## Available v2 endpoints The following endpoints are available in v2: * **[POST /v2/MoneyIn/getpaid](/developers/api-reference/moneyinV2/make-a-transaction)**: Make a transaction (authorize and capture in one step) * **[POST /v2/MoneyIn/authorize](/developers/api-reference/moneyinV2/authorize-a-transaction)**: Authorize a card transaction * **[POST /v2/MoneyIn/capture/\{transId}](/developers/api-reference/moneyinV2/capture-an-authorized-transaction)**: Capture an authorized transaction (full or partial) * **[POST /v2/MoneyIn/refund/\{transId}/\{amount}](/developers/api-reference/moneyinV2/refund-a-settled-transaction)**: Refund a settled transaction (full or partial) * **[POST /v2/MoneyIn/void/\{transId}](/developers/api-reference/moneyinV2/void-a-transaction)**: Void an unsettled transaction ## Choosing v1 or v2 If you're starting a new integration or want to take advantage of the enhanced features, use the v2 transaction APIs. They return standardized response codes, immediate transaction details, and clearer error messages. **Use v2 if:** * You're starting a new integration * You want standardized, predictable response codes * You need transaction details immediately after processing * You want clearer error messages and guidance **Use v1 if:** * You need backward compatibility with legacy systems Payabli will continue to support v1 transaction APIs for now, but they will be retired in the future. We recommend planning to migrate to v2. ## Migration guide Unified response codes and the v2 transaction endpoints are available in Sandbox as of December 23, 2025, and are scheduled to be available in Production on January 20, 2026. Migrating from v1 to v2 is straightforward. All v2 endpoints use the same authentication, request bodies, and path parameters as their v1 counterparts. Only the response format has changed. 1. **Update endpoint paths**: Add `/v2` to the base path (for example `/MoneyIn/getpaid` becomes `/v2/MoneyIn/getpaid`) 2. **Update response handling**: Parse the new response structure with `code`, `reason`, `explanation`, `action`, and `data` fields 3. **Update error handling**: Map unified response codes to your application's error handling 4. **Test**: The response structure is different, so ensure your integration handles all response scenarios correctly See [Pay In unified response codes reference](/guides/pay-in-unified-response-codes-reference) for a full list of the new response codes. # Make a transaction POST https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid Content-Type: application/json Make a single transaction. This method authorizes and captures a payment in one step. This is the v2 version of the `api/MoneyIn/getpaid` endpoint, and returns the unified response format. See [Pay In unified response codes reference](/guides/pay-in-unified-response-codes-reference) for more information. Reference: https://docs.payabli.com/developers/api-reference/moneyinV2/make-a-transaction ## SDK Code Examples ```typescript CardApproval import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaidv2({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { cardcvv: "999", cardexp: "02/27", cardHolder: "John Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python CardApproval from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaidv_2( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( cardcvv="999", cardexp="02/27", card_holder="John Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp CardApproval using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Getpaidv2Async( new RequestPaymentV2 { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Cardcvv = "999", Cardexp = "02/27", CardHolder = "John Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go CardApproval package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CardApproval require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java CardApproval import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php CardApproval request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CardApproval import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript StoredMethodApproval import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaidv2({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { initiator: "payor", method: "card", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python StoredMethodApproval from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaidv_2( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( initiator="payor", method="card", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp StoredMethodApproval using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Getpaidv2Async( new RequestPaymentV2 { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Initiator = "payor", Method = "card" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go StoredMethodApproval package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"initiator\": \"payor\",\n \"method\": \"card\",\n \"storedMethodId\": \"1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440\",\n \"storedMethodUsageType\": \"unscheduled\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby StoredMethodApproval require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"initiator\": \"payor\",\n \"method\": \"card\",\n \"storedMethodId\": \"1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440\",\n \"storedMethodUsageType\": \"unscheduled\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java StoredMethodApproval import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"initiator\": \"payor\",\n \"method\": \"card\",\n \"storedMethodId\": \"1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440\",\n \"storedMethodUsageType\": \"unscheduled\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php StoredMethodApproval request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "initiator": "payor", "method": "card", "storedMethodId": "1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440", "storedMethodUsageType": "unscheduled" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift StoredMethodApproval import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "initiator": "payor", "method": "card", "storedMethodId": "1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440", "storedMethodUsageType": "unscheduled" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript ACHApproval import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaidv2({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { method: "ach", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python ACHApproval from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaidv_2( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( method="ach", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp ACHApproval using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Getpaidv2Async( new RequestPaymentV2 { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Method = "ach" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go ACHApproval package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"achAccount\": \"123123123\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Cassian\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123123123\",\n \"method\": \"ach\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ACHApproval require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"achAccount\": \"123123123\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Cassian\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123123123\",\n \"method\": \"ach\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java ACHApproval import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"achAccount\": \"123123123\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Cassian\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123123123\",\n \"method\": \"ach\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php ACHApproval request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "achAccount": "123123123", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Cassian", "achHolderType": "personal", "achRouting": "123123123", "method": "ach" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ACHApproval import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "achAccount": "123123123", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Cassian", "achHolderType": "personal", "achRouting": "123123123", "method": "ach" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript CloudApproval import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaidv2({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { method: "cloud", saveIfSuccess: true, }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python CloudApproval from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaidv_2( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( method="cloud", save_if_success=True, ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp CloudApproval using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Getpaidv2Async( new RequestPaymentV2 { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Method = "cloud", SaveIfSuccess = true }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go CloudApproval package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"device\": \"6c361c7d-674c-44cc-b790-382b75d1xxx\",\n \"method\": \"cloud\",\n \"saveIfSuccess\": true\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CloudApproval require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"device\": \"6c361c7d-674c-44cc-b790-382b75d1xxx\",\n \"method\": \"cloud\",\n \"saveIfSuccess\": true\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java CloudApproval import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"device\": \"6c361c7d-674c-44cc-b790-382b75d1xxx\",\n \"method\": \"cloud\",\n \"saveIfSuccess\": true\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php CloudApproval request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "device": "6c361c7d-674c-44cc-b790-382b75d1xxx", "method": "cloud", "saveIfSuccess": true }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CloudApproval import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "device": "6c361c7d-674c-44cc-b790-382b75d1xxx", "method": "cloud", "saveIfSuccess": true ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Authorize transaction POST https://api-sandbox.payabli.com/api/v2/MoneyIn/authorize Content-Type: application/json Authorize a card transaction. This returns an authorization code and reserves funds for the merchant. Authorized transactions aren't flagged for settlement until captured. This is the v2 version of the `api/MoneyIn/authorize` endpoint, and returns the unified response format. See [Pay In unified response codes reference](/guides/pay-in-unified-response-codes-reference) for more information. **Note**: Only card transactions can be authorized. This endpoint can't be used for ACH transactions. Reference: https://docs.payabli.com/developers/api-reference/moneyinV2/authorize-a-transaction ## SDK Code Examples ```typescript CardAuthorization import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.authorizev2({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { cardcvv: "999", cardexp: "02/27", cardHolder: "John Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python CardAuthorization from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.authorizev_2( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( cardcvv="999", cardexp="02/27", card_holder="John Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp CardAuthorization using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Authorizev2Async( new RequestPaymentAuthorizeV2 { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Cardcvv = "999", Cardexp = "02/27", CardHolder = "John Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go CardAuthorization package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/authorize" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CardAuthorization require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/authorize") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java CardAuthorization import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/authorize") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php CardAuthorization request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/authorize', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CardAuthorization import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/authorize")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Capture transaction POST https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/{transId} Content-Type: application/json Capture an authorized transaction to complete the transaction and move funds from the customer to merchant account. This is the v2 version of the `api/MoneyIn/capture/{transId}` endpoint, and returns the unified response format. See [Pay In unified response codes reference](/guides/pay-in-unified-response-codes-reference) for more information. Reference: https://docs.payabli.com/developers/api-reference/moneyinV2/capture-an-authorized-transaction ## SDK Code Examples ```typescript FullCapture import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.capturev2("10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", { paymentDetails: { totalAmount: 105, serviceFee: 5, }, }); } main(); ``` ```python FullCapture from payabli import payabli from payabli.money_in import CapturePaymentDetails client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.capturev_2( trans_id="10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", payment_details=CapturePaymentDetails( total_amount=105, service_fee=5, ), ) ``` ```csharp FullCapture using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Capturev2Async( "10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", new CaptureRequest { PaymentDetails = new CapturePaymentDetails { TotalAmount = 105, ServiceFee = 5 } } ); } } ``` ```go FullCapture package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 105,\n \"serviceFee\": 5\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby FullCapture require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 105,\n \"serviceFee\": 5\n }\n}" response = http.request(request) puts response.read_body ``` ```java FullCapture import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 105,\n \"serviceFee\": 5\n }\n}") .asString(); ``` ```php FullCapture request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13', [ 'body' => '{ "paymentDetails": { "totalAmount": 105, "serviceFee": 5 } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift FullCapture import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["paymentDetails": [ "totalAmount": 105, "serviceFee": 5 ]] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript PartialCapture import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.capturev2("10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", { paymentDetails: { totalAmount: 89, serviceFee: 4, }, }); } main(); ``` ```python PartialCapture from payabli import payabli from payabli.money_in import CapturePaymentDetails client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.capturev_2( trans_id="10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", payment_details=CapturePaymentDetails( total_amount=89, service_fee=4, ), ) ``` ```csharp PartialCapture using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Capturev2Async( "10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", new CaptureRequest { PaymentDetails = new CapturePaymentDetails { TotalAmount = 89, ServiceFee = 4 } } ); } } ``` ```go PartialCapture package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 89,\n \"serviceFee\": 4\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby PartialCapture require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 89,\n \"serviceFee\": 4\n }\n}" response = http.request(request) puts response.read_body ``` ```java PartialCapture import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 89,\n \"serviceFee\": 4\n }\n}") .asString(); ``` ```php PartialCapture request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13', [ 'body' => '{ "paymentDetails": { "totalAmount": 89, "serviceFee": 4 } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift PartialCapture import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["paymentDetails": [ "totalAmount": 89, "serviceFee": 4 ]] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Refund transaction POST https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/{transId} Give a full refund for a transaction that has settled and send money back to the account holder. To perform a partial refund, see [Partially refund a transaction](developers/api-reference/moneyinV2/partial-refund-a-settled-transaction). This is the v2 version of the refund endpoint, and returns the unified response format. See [Pay In unified response codes reference](/guides/pay-in-unified-response-codes-reference) for more information. Reference: https://docs.payabli.com/developers/api-reference/moneyinV2/refund-a-settled-transaction ## SDK Code Examples ```typescript FullRefundNoAmount import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.refundv2("10-3ffa27df-b171-44e0-b251-e95fbfc7a723"); } main(); ``` ```python FullRefundNoAmount from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.refundv_2( trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", ) ``` ```csharp FullRefundNoAmount using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Refundv2Async( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723" ); } } ``` ```go FullRefundNoAmount package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby FullRefundNoAmount require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java FullRefundNoAmount import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") .header("requestToken", "") .asString(); ``` ```php FullRefundNoAmount request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift FullRefundNoAmount import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Partially refund transaction POST https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/{transId}/{amount} Refund a transaction that has settled and send money back to the account holder. If `amount` is omitted or set to 0, performs a full refund. When a non-zero `amount` is provided, this endpoint performs a partial refund. This is the v2 version of the refund endpoint, and returns the unified response format. See [Pay In unified response codes reference](/guides/pay-in-unified-response-codes-reference) for more information. Reference: https://docs.payabli.com/developers/api-reference/moneyinV2/partial-refund-a-settled-transaction ## SDK Code Examples ```typescript FullRefundZeroAmount import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.refundv2Amount("10-3ffa27df-b171-44e0-b251-e95fbfc7a723", 0); } main(); ``` ```python FullRefundZeroAmount from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.refundv_2_amount( trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", amount=0, ) ``` ```csharp FullRefundZeroAmount using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Refundv2AmountAsync( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723", 0 ); } } ``` ```go FullRefundZeroAmount package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby FullRefundZeroAmount require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java FullRefundZeroAmount import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0") .header("requestToken", "") .asString(); ``` ```php FullRefundZeroAmount request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift FullRefundZeroAmount import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript RefundAmount import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.refundv2Amount("10-3ffa27df-b171-44e0-b251-e95fbfc7a723", 100.99); } main(); ``` ```python RefundAmount from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.refundv_2_amount( trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", amount=100.99, ) ``` ```csharp RefundAmount using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Refundv2AmountAsync( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723", 100.99 ); } } ``` ```go RefundAmount package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby RefundAmount require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java RefundAmount import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99") .header("requestToken", "") .asString(); ``` ```php RefundAmount request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift RefundAmount import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Void transaction POST https://api-sandbox.payabli.com/api/v2/MoneyIn/void/{transId} Cancel a transaction that hasn't been settled yet. Voiding non-captured authorizations prevents future captures. This is the v2 version of the `api/MoneyIn/void/{transId}` endpoint, and returns the unified response format. See [Pay In unified response codes reference](/guides/pay-in-unified-response-codes-reference) for more information. Reference: https://docs.payabli.com/developers/api-reference/moneyinV2/void-a-transaction ## SDK Code Examples ```typescript VoidTransaction import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.voidv2("10-3ffa27df-b171-44e0-b251-e95fbfc7a723"); } main(); ``` ```python VoidTransaction from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.voidv_2( trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", ) ``` ```csharp VoidTransaction using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.Voidv2Async( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723" ); } } ``` ```go VoidTransaction package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby VoidTransaction require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java VoidTransaction import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") .header("requestToken", "") .asString(); ``` ```php VoidTransaction request('POST', 'https://api-sandbox.payabli.com/api/v2/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift VoidTransaction import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Make transaction POST https://api-sandbox.payabli.com/api/MoneyIn/getpaid Content-Type: application/json Make a single transaction. This method authorizes and captures a payment in one step. Consider migrating to the [v2 Make a transaction endpoint](/developers/api-reference/moneyinV2/make-a-transaction) to take advantage of unified response codes and improved response consistency. Reference: https://docs.payabli.com/developers/api-reference/moneyin/make-a-transaction ## SDK Code Examples ```typescript Card import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaid({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { cardcvv: "999", cardexp: "02/27", cardHolder: "John Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python Card from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaid( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( cardcvv="999", cardexp="02/27", card_holder="John Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp Card using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.GetpaidAsync( new RequestPayment { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Cardcvv = "999", Cardexp = "02/27", CardHolder = "John Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go Card package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Card require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java Card import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php Card request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Card import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript StoredMethod import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaid({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { initiator: "payor", method: "card", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python StoredMethod from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaid( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( initiator="payor", method="card", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp StoredMethod using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.GetpaidAsync( new RequestPayment { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Initiator = "payor", Method = "card" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go StoredMethod package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"initiator\": \"payor\",\n \"method\": \"card\",\n \"storedMethodId\": \"1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440\",\n \"storedMethodUsageType\": \"unscheduled\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby StoredMethod require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"initiator\": \"payor\",\n \"method\": \"card\",\n \"storedMethodId\": \"1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440\",\n \"storedMethodUsageType\": \"unscheduled\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java StoredMethod import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"initiator\": \"payor\",\n \"method\": \"card\",\n \"storedMethodId\": \"1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440\",\n \"storedMethodUsageType\": \"unscheduled\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php StoredMethod request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "initiator": "payor", "method": "card", "storedMethodId": "1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440", "storedMethodUsageType": "unscheduled" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift StoredMethod import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "initiator": "payor", "method": "card", "storedMethodId": "1ec55af9-7b5a-4ff0-81ed-c12d2f95e135-4440", "storedMethodUsageType": "unscheduled" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript Cloud import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaid({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { method: "cloud", saveIfSuccess: true, }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python Cloud from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaid( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( method="cloud", save_if_success=True, ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp Cloud using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.GetpaidAsync( new RequestPayment { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Method = "cloud", SaveIfSuccess = true }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go Cloud package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"device\": \"6c361c7d-674c-44cc-b790-382b75d1xxx\",\n \"method\": \"cloud\",\n \"saveIfSuccess\": true\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Cloud require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"device\": \"6c361c7d-674c-44cc-b790-382b75d1xxx\",\n \"method\": \"cloud\",\n \"saveIfSuccess\": true\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java Cloud import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"device\": \"6c361c7d-674c-44cc-b790-382b75d1xxx\",\n \"method\": \"cloud\",\n \"saveIfSuccess\": true\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php Cloud request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "device": "6c361c7d-674c-44cc-b790-382b75d1xxx", "method": "cloud", "saveIfSuccess": true }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Cloud import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "device": "6c361c7d-674c-44cc-b790-382b75d1xxx", "method": "cloud", "saveIfSuccess": true ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript ACH import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaid({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { method: "ach", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python ACH from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaid( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( method="ach", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp ACH using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.GetpaidAsync( new RequestPayment { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Method = "ach" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go ACH package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"achAccount\": \"123123123\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Cassian\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123123123\",\n \"method\": \"ach\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ACH require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"achAccount\": \"123123123\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Cassian\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123123123\",\n \"method\": \"ach\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java ACH import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"achAccount\": \"123123123\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Cassian\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123123123\",\n \"method\": \"ach\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php ACH request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "achAccount": "123123123", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Cassian", "achHolderType": "personal", "achRouting": "123123123", "method": "ach" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ACH import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "achAccount": "123123123", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Cassian", "achHolderType": "personal", "achRouting": "123123123", "method": "ach" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript BOC import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaid({ body: { paymentDetails: { totalAmount: 125.5, serviceFee: 0, checkUniqueId: "abc123def456", }, paymentMethod: { method: "ach", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python BOC from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaid( payment_details=PaymentDetail( total_amount=125.5, service_fee=0, check_unique_id="abc123def456", ), payment_method=PayMethodCredit( method="ach", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp BOC using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.GetpaidAsync( new RequestPayment { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 125.5, ServiceFee = 0, CheckUniqueId = "abc123def456" }, PaymentMethod = new PayMethodCredit { Method = "ach" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go BOC package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 125.5,\n \"serviceFee\": 0,\n \"checkUniqueId\": \"abc123def456\"\n },\n \"paymentMethod\": {\n \"achAccount\": \"123456\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"BOC\",\n \"achHolder\": \"John Doe\",\n \"achRouting\": \"123456789\",\n \"method\": \"ach\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby BOC require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 125.5,\n \"serviceFee\": 0,\n \"checkUniqueId\": \"abc123def456\"\n },\n \"paymentMethod\": {\n \"achAccount\": \"123456\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"BOC\",\n \"achHolder\": \"John Doe\",\n \"achRouting\": \"123456789\",\n \"method\": \"ach\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java BOC import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 125.5,\n \"serviceFee\": 0,\n \"checkUniqueId\": \"abc123def456\"\n },\n \"paymentMethod\": {\n \"achAccount\": \"123456\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"BOC\",\n \"achHolder\": \"John Doe\",\n \"achRouting\": \"123456789\",\n \"method\": \"ach\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php BOC request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 125.5, "serviceFee": 0, "checkUniqueId": "abc123def456" }, "paymentMethod": { "achAccount": "123456", "achAccountType": "Checking", "achCode": "BOC", "achHolder": "John Doe", "achRouting": "123456789", "method": "ach" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift BOC import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 125.5, "serviceFee": 0, "checkUniqueId": "abc123def456" ], "paymentMethod": [ "achAccount": "123456", "achAccountType": "Checking", "achCode": "BOC", "achHolder": "John Doe", "achRouting": "123456789", "method": "ach" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript ComplexCard import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaid({ body: { paymentDetails: { totalAmount: 1000, serviceFee: 0, }, paymentMethod: { cardcvv: "123", cardexp: "02/25", cardHolder: "John Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", saveIfSuccess: true, }, customerData: { billingAddress1: "123 Walnut Street", billingCity: "Johnson City", billingCountry: "US", billingEmail: "john@email.com", billingPhone: "1234567890", billingState: "Johnson City", billingZip: "37615", customerNumber: "3456-7645A", firstName: "John", lastName: "Cassian", }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", orderDescription: "New customer package", orderId: "982-102", source: "web", }, }); } main(); ``` ```python ComplexCard from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaid( payment_details=PaymentDetail( total_amount=1000, service_fee=0, ), payment_method=PayMethodCredit( cardcvv="123", cardexp="02/25", card_holder="John Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", save_if_success=True, ), customer_data=PayorDataRequest( billing_address_1="123 Walnut Street", billing_city="Johnson City", billing_country="US", billing_email="john@email.com", billing_phone="1234567890", billing_state="Johnson City", billing_zip="37615", customer_number="3456-7645A", first_name="John", last_name="Cassian", ), entry_point="f743aed24a", ipaddress="255.255.255.255", order_description="New customer package", order_id="982-102", source="web", ) ``` ```csharp ComplexCard using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.GetpaidAsync( new RequestPayment { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 1000, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Cardcvv = "123", Cardexp = "02/25", CardHolder = "John Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card", SaveIfSuccess = true }, CustomerData = new PayorDataRequest { BillingAddress1 = "123 Walnut Street", BillingCity = "Johnson City", BillingCountry = "US", BillingEmail = "john@email.com", BillingPhone = "1234567890", BillingState = "Johnson City", BillingZip = "37615", CustomerNumber = "3456-7645A", FirstName = "John", LastName = "Cassian" }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255", OrderDescription = "New customer package", OrderId = "982-102", Source = "web" } } ); } } ``` ```go ComplexCard package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 1000,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\",\n \"saveIfSuccess\": true\n },\n \"customerData\": {\n \"billingAddress1\": \"123 Walnut Street\",\n \"billingCity\": \"Johnson City\",\n \"billingCountry\": \"US\",\n \"billingEmail\": \"john@email.com\",\n \"billingPhone\": \"1234567890\",\n \"billingState\": \"Johnson City\",\n \"billingZip\": \"37615\",\n \"customerNumber\": \"3456-7645A\",\n \"firstName\": \"John\",\n \"lastName\": \"Cassian\"\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\",\n \"orderDescription\": \"New customer package\",\n \"orderId\": \"982-102\",\n \"source\": \"web\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ComplexCard require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 1000,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\",\n \"saveIfSuccess\": true\n },\n \"customerData\": {\n \"billingAddress1\": \"123 Walnut Street\",\n \"billingCity\": \"Johnson City\",\n \"billingCountry\": \"US\",\n \"billingEmail\": \"john@email.com\",\n \"billingPhone\": \"1234567890\",\n \"billingState\": \"Johnson City\",\n \"billingZip\": \"37615\",\n \"customerNumber\": \"3456-7645A\",\n \"firstName\": \"John\",\n \"lastName\": \"Cassian\"\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\",\n \"orderDescription\": \"New customer package\",\n \"orderId\": \"982-102\",\n \"source\": \"web\"\n}" response = http.request(request) puts response.read_body ``` ```java ComplexCard import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 1000,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\",\n \"saveIfSuccess\": true\n },\n \"customerData\": {\n \"billingAddress1\": \"123 Walnut Street\",\n \"billingCity\": \"Johnson City\",\n \"billingCountry\": \"US\",\n \"billingEmail\": \"john@email.com\",\n \"billingPhone\": \"1234567890\",\n \"billingState\": \"Johnson City\",\n \"billingZip\": \"37615\",\n \"customerNumber\": \"3456-7645A\",\n \"firstName\": \"John\",\n \"lastName\": \"Cassian\"\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\",\n \"orderDescription\": \"New customer package\",\n \"orderId\": \"982-102\",\n \"source\": \"web\"\n}") .asString(); ``` ```php ComplexCard request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 1000, "serviceFee": 0 }, "paymentMethod": { "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card", "saveIfSuccess": true }, "customerData": { "billingAddress1": "123 Walnut Street", "billingCity": "Johnson City", "billingCountry": "US", "billingEmail": "john@email.com", "billingPhone": "1234567890", "billingState": "Johnson City", "billingZip": "37615", "customerNumber": "3456-7645A", "firstName": "John", "lastName": "Cassian" }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255", "orderDescription": "New customer package", "orderId": "982-102", "source": "web" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ComplexCard import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 1000, "serviceFee": 0 ], "paymentMethod": [ "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card", "saveIfSuccess": true ], "customerData": [ "billingAddress1": "123 Walnut Street", "billingCity": "Johnson City", "billingCountry": "US", "billingEmail": "john@email.com", "billingPhone": "1234567890", "billingState": "Johnson City", "billingZip": "37615", "customerNumber": "3456-7645A", "firstName": "John", "lastName": "Cassian" ], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255", "orderDescription": "New customer package", "orderId": "982-102", "source": "web" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript CADCard import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaid({ body: { paymentDetails: { totalAmount: 100, currency: "CAD", serviceFee: 0, }, paymentMethod: { cardcvv: "999", cardexp: "02/27", cardHolder: "John Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python CADCard from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaid( payment_details=PaymentDetail( total_amount=100, currency="CAD", service_fee=0, ), payment_method=PayMethodCredit( cardcvv="999", cardexp="02/27", card_holder="John Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp CADCard using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.GetpaidAsync( new RequestPayment { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, Currency = "CAD", ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Cardcvv = "999", Cardexp = "02/27", CardHolder = "John Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go CADCard package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"currency\": \"CAD\",\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CADCard require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"currency\": \"CAD\",\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java CADCard import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"currency\": \"CAD\",\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php CADCard request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "currency": "CAD", "serviceFee": 0 }, "paymentMethod": { "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CADCard import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "currency": "CAD", "serviceFee": 0 ], "paymentMethod": [ "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript Decline import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.getpaid({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { cardcvv: "999", cardexp: "02/27", cardHolder: "John Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python Decline from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.getpaid( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( cardcvv="999", cardexp="02/27", card_holder="John Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp Decline using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.GetpaidAsync( new RequestPayment { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Cardcvv = "999", Cardexp = "02/27", CardHolder = "John Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go Decline package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/getpaid" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Decline require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java Decline import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/getpaid") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php Decline request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/getpaid', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Decline import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/getpaid")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Authorize transaction POST https://api-sandbox.payabli.com/api/MoneyIn/authorize Content-Type: application/json Authorize a card transaction. This returns an authorization code and reserves funds for the merchant. Authorized transactions aren't flagged for settlement until [captured](/developers/api-reference/moneyin/capture-an-authorized-transaction). Only card transactions can be authorized. This endpoint can't be used for ACH transactions. Consider migrating to the [v2 Authorize endpoint](/developers/api-reference/moneyinV2/authorize-a-transaction) to take advantage of unified response codes and improved response consistency. Reference: https://docs.payabli.com/developers/api-reference/moneyin/authorize-a-transaction ## SDK Code Examples ```typescript AuthorizeTransaction import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.authorize({ body: { paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { cardcvv: "999", cardexp: "02/27", cardHolder: "John Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", }, customerData: { customerId: 4440, }, entryPoint: "f743aed24a", ipaddress: "255.255.255.255", }, }); } main(); ``` ```python AuthorizeTransaction from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.authorize( payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( cardcvv="999", cardexp="02/27", card_holder="John Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", ), customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", ipaddress="255.255.255.255", ) ``` ```csharp AuthorizeTransaction using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.AuthorizeAsync( new RequestPaymentAuthorize { Body = new TransRequestBody { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Cardcvv = "999", Cardexp = "02/27", CardHolder = "John Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card" }, CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", Ipaddress = "255.255.255.255" } } ); } } ``` ```go AuthorizeTransaction package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/authorize" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby AuthorizeTransaction require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/authorize") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}" response = http.request(request) puts response.read_body ``` ```java AuthorizeTransaction import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/authorize") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"999\",\n \"cardexp\": \"02/27\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"ipaddress\": \"255.255.255.255\"\n}") .asString(); ``` ```php AuthorizeTransaction request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/authorize', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" }, "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift AuthorizeTransaction import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "cardcvv": "999", "cardexp": "02/27", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "12345", "initiator": "payor", "method": "card" ], "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "ipaddress": "255.255.255.255" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/authorize")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Capture transaction POST https://api-sandbox.payabli.com/api/MoneyIn/capture/{transId} Content-Type: application/json Capture an [authorized transaction](/developers/api-reference/moneyin/authorize-a-transaction) to complete the transaction and move funds from the customer to merchant account. You can use this endpoint to capture both full and partial amounts of the original authorized transaction. See [Capture an authorized transaction](/developers/developer-guides/pay-in-auth-and-capture) for more information about this endpoint. Consider migrating to the [v2 Capture endpoint](/developers/api-reference/moneyinV2/capture-an-authorized-transaction) to take advantage of unified response codes and improved response consistency. Reference: https://docs.payabli.com/developers/api-reference/moneyin/capture-an-authorized-transaction ## SDK Code Examples ```typescript CaptureFullAmountwithFee import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.captureAuth("10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", { paymentDetails: { totalAmount: 105, serviceFee: 5, }, }); } main(); ``` ```python CaptureFullAmountwithFee from payabli import payabli from payabli.money_in import CapturePaymentDetails client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.capture_auth( trans_id="10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", payment_details=CapturePaymentDetails( total_amount=105, service_fee=5, ), ) ``` ```csharp CaptureFullAmountwithFee using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.CaptureAuthAsync( "10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", new CaptureRequest { PaymentDetails = new CapturePaymentDetails { TotalAmount = 105, ServiceFee = 5 } } ); } } ``` ```go CaptureFullAmountwithFee package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 105,\n \"serviceFee\": 5\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CaptureFullAmountwithFee require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 105,\n \"serviceFee\": 5\n }\n}" response = http.request(request) puts response.read_body ``` ```java CaptureFullAmountwithFee import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 105,\n \"serviceFee\": 5\n }\n}") .asString(); ``` ```php CaptureFullAmountwithFee request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13', [ 'body' => '{ "paymentDetails": { "totalAmount": 105, "serviceFee": 5 } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CaptureFullAmountwithFee import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["paymentDetails": [ "totalAmount": 105, "serviceFee": 5 ]] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript CapturePartialAmountwithFee import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.captureAuth("10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", { paymentDetails: { totalAmount: 89, serviceFee: 4, }, }); } main(); ``` ```python CapturePartialAmountwithFee from payabli import payabli from payabli.money_in import CapturePaymentDetails client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.capture_auth( trans_id="10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", payment_details=CapturePaymentDetails( total_amount=89, service_fee=4, ), ) ``` ```csharp CapturePartialAmountwithFee using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.CaptureAuthAsync( "10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", new CaptureRequest { PaymentDetails = new CapturePaymentDetails { TotalAmount = 89, ServiceFee = 4 } } ); } } ``` ```go CapturePartialAmountwithFee package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 89,\n \"serviceFee\": 4\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CapturePartialAmountwithFee require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 89,\n \"serviceFee\": 4\n }\n}" response = http.request(request) puts response.read_body ``` ```java CapturePartialAmountwithFee import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 89,\n \"serviceFee\": 4\n }\n}") .asString(); ``` ```php CapturePartialAmountwithFee request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13', [ 'body' => '{ "paymentDetails": { "totalAmount": 89, "serviceFee": 4 } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CapturePartialAmountwithFee import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["paymentDetails": [ "totalAmount": 89, "serviceFee": 4 ]] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript CaptureNoFee import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.captureAuth("10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", { paymentDetails: { totalAmount: 100, }, }); } main(); ``` ```python CaptureNoFee from payabli import payabli from payabli.money_in import CapturePaymentDetails client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.capture_auth( trans_id="10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", payment_details=CapturePaymentDetails( total_amount=100, ), ) ``` ```csharp CaptureNoFee using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.CaptureAuthAsync( "10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", new CaptureRequest { PaymentDetails = new CapturePaymentDetails { TotalAmount = 100 } } ); } } ``` ```go CaptureNoFee package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CaptureNoFee require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100\n }\n}" response = http.request(request) puts response.read_body ``` ```java CaptureNoFee import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100\n }\n}") .asString(); ``` ```php CaptureNoFee request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13', [ 'body' => '{ "paymentDetails": { "totalAmount": 100 } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CaptureNoFee import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["paymentDetails": ["totalAmount": 100]] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Capture transaction (deprecated) GET https://api-sandbox.payabli.com/api/MoneyIn/capture/{transId}/{amount} This endpoint is deprecated and will be sunset on November 24, 2025. Migrate to [POST `/capture/{transId}`](/developers/api-reference/moneyin/capture-an-authorized-transaction)`. Capture an [authorized transaction](/developers/api-reference/moneyin/authorize-a-transaction) to complete the transaction and move funds from the customer to merchant account. Reference: https://docs.payabli.com/developers/api-reference/moneyin/capture-an-authorized-transaction-deprecated ## SDK Code Examples ```typescript FullCapture import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.capture("10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", 0); } main(); ``` ```python FullCapture from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.capture( trans_id="10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", amount=0, ) ``` ```csharp FullCapture using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.CaptureAsync( "10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13", 0 ); } } ``` ```go FullCapture package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13/0" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby FullCapture require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13/0") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java FullCapture import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13/0") .header("requestToken", "") .asString(); ``` ```php FullCapture request('GET', 'https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13/0', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift FullCapture import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/capture/10-7d9cd67d-2d5d-4cd7-a1b7-72b8b201ec13/0")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Send receipt GET https://api-sandbox.payabli.com/api/MoneyIn/sendreceipt/{transId} Send a payment receipt for a transaction. Reference: https://docs.payabli.com/developers/api-reference/moneyin/send-receipt-for-transaction ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.sendReceipt2Trans("45-as456777hhhhhhhhhh77777777-324", { email: "example@email.com", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.send_receipt_2_trans( trans_id="45-as456777hhhhhhhhhh77777777-324", email="example@email.com", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.SendReceipt2TransAsync( "45-as456777hhhhhhhhhh77777777-324", new SendReceipt2TransRequest { Email = "example@email.com" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/sendreceipt/45-as456777hhhhhhhhhh77777777-324?email=example%40email.com" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/sendreceipt/45-as456777hhhhhhhhhh77777777-324?email=example%40email.com") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyIn/sendreceipt/45-as456777hhhhhhhhhh77777777-324?email=example%40email.com") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/MoneyIn/sendreceipt/45-as456777hhhhhhhhhh77777777-324?email=example%40email.com', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/sendreceipt/45-as456777hhhhhhhhhh77777777-324?email=example%40email.com")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Reverse transaction GET https://api-sandbox.payabli.com/api/MoneyIn/reverse/{transId}/{amount} A reversal either refunds or voids a transaction independent of the transaction's settlement status. Send a reversal request for a transaction, and Payabli automatically determines whether it's a refund or void. You don't need to know whether the transaction is settled or not. Reference: https://docs.payabli.com/developers/api-reference/moneyin/reverse-a-transaction ## SDK Code Examples ```typescript Void import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.reverse(0, "10-3ffa27df-b171-44e0-b251-e95fbfc7a723"); } main(); ``` ```python Void from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.reverse( amount=0, trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", ) ``` ```csharp Void using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.ReverseAsync( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723", 0 ); } } ``` ```go Void package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Void require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Void import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0") .header("requestToken", "") .asString(); ``` ```php Void request('GET', 'https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Void import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript Refund import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.reverse(53.76, "10-3ffa27df-b171-44e0-b251-e95fbfc7a723"); } main(); ``` ```python Refund from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.reverse( amount=53.76, trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", ) ``` ```csharp Refund using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.ReverseAsync( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723", 53.76 ); } } ``` ```go Refund package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/53.76" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Refund require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/53.76") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Refund import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/53.76") .header("requestToken", "") .asString(); ``` ```php Refund request('GET', 'https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/53.76', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Refund import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/reverse/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/53.76")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Void transaction GET https://api-sandbox.payabli.com/api/MoneyIn/void/{transId} Cancel a transaction that hasn't been settled yet. Voiding non-captured authorizations prevents future captures. If a transaction has been settled, refund it instead. Consider migrating to the [v2 Void endpoint](/developers/api-reference/moneyinV2/void-a-transaction) to take advantage of unified response codes and improved response consistency. Reference: https://docs.payabli.com/developers/api-reference/moneyin/void-a-transaction ## SDK Code Examples ```typescript Void import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.void("10-3ffa27df-b171-44e0-b251-e95fbfc7a723"); } main(); ``` ```python Void from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.void( trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", ) ``` ```csharp Void using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.VoidAsync( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723" ); } } ``` ```go Void package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Void require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Void import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") .header("requestToken", "") .asString(); ``` ```php Void request('GET', 'https://api-sandbox.payabli.com/api/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Void import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/void/10-3ffa27df-b171-44e0-b251-e95fbfc7a723")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Refund transaction GET https://api-sandbox.payabli.com/api/MoneyIn/refund/{transId}/{amount} Refund a transaction that has settled and send money back to the account holder. If a transaction hasn't been settled, void it instead. Consider migrating to the [v2 Refund endpoint](/developers/api-reference/moneyinV2/refund-a-settled-transaction) to take advantage of unified response codes and improved response consistency. Reference: https://docs.payabli.com/developers/api-reference/moneyin/refund-a-settled-transaction ## SDK Code Examples ```typescript Initiated import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.refund(0, "10-3ffa27df-b171-44e0-b251-e95fbfc7a723"); } main(); ``` ```python Initiated from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.refund( amount=0, trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", ) ``` ```csharp Initiated using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.RefundAsync( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723", 0 ); } } ``` ```go Initiated package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Initiated require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Initiated import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0") .header("requestToken", "") .asString(); ``` ```php Initiated request('GET', 'https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Initiated import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/0")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript Captured import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.refund(100.99, "10-3ffa27df-b171-44e0-b251-e95fbfc7a723"); } main(); ``` ```python Captured from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.refund( amount=100.99, trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", ) ``` ```csharp Captured using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.RefundAsync( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723", 100.99 ); } } ``` ```go Captured package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Captured require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Captured import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99") .header("requestToken", "") .asString(); ``` ```php Captured request('GET', 'https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Captured import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723/100.99")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Refund split transaction POST https://api-sandbox.payabli.com/api/MoneyIn/refund/{transId} Content-Type: application/json Refunds a settled transaction with split instructions. Reference: https://docs.payabli.com/developers/api-reference/moneyin/refund-a-settled-transaction-with-instructions ## SDK Code Examples ```typescript FullSplitRefund import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.refundWithInstructions("10-3ffa27df-b171-44e0-b251-e95fbfc7a723", { idempotencyKey: "8A29FC40-CA47-1067-B31D-00DD010662DB", amount: 100, orderDescription: "Materials deposit", refundDetails: { splitRefunding: [ { accountId: "187-342", amount: 60, description: "Refunding undelivered materials", originationEntryPoint: "7f1a381696", }, { accountId: "187-343", amount: 40, description: "Refunding deposit for undelivered materials", originationEntryPoint: "7f1a381696", }, ], }, source: "api", }); } main(); ``` ```python FullSplitRefund from payabli import payabli, RefundDetail, SplitFundingRefundContent client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.refund_with_instructions( trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", idempotency_key="8A29FC40-CA47-1067-B31D-00DD010662DB", amount=100, order_description="Materials deposit", refund_details=RefundDetail( split_refunding=[ SplitFundingRefundContent( account_id="187-342", amount=60, description="Refunding undelivered materials", origination_entry_point="7f1a381696", ), SplitFundingRefundContent( account_id="187-343", amount=40, description="Refunding deposit for undelivered materials", origination_entry_point="7f1a381696", ) ], ), source="api", ) ``` ```csharp FullSplitRefund using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.RefundWithInstructionsAsync( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723", new RequestRefund { IdempotencyKey = "8A29FC40-CA47-1067-B31D-00DD010662DB", Amount = 100, OrderDescription = "Materials deposit", RefundDetails = new RefundDetail { SplitRefunding = new List(){ new SplitFundingRefundContent { AccountId = "187-342", Amount = 60, Description = "Refunding undelivered materials", OriginationEntryPoint = "7f1a381696" }, new SplitFundingRefundContent { AccountId = "187-343", Amount = 40, Description = "Refunding deposit for undelivered materials", OriginationEntryPoint = "7f1a381696" }, } }, Source = "api" } ); } } ``` ```go FullSplitRefund package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723" payload := strings.NewReader("{\n \"amount\": 100,\n \"orderDescription\": \"Materials deposit\",\n \"refundDetails\": {\n \"splitRefunding\": [\n {\n \"accountId\": \"187-342\",\n \"amount\": 60,\n \"description\": \"Refunding undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n },\n {\n \"accountId\": \"187-343\",\n \"amount\": 40,\n \"description\": \"Refunding deposit for undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n }\n ]\n },\n \"source\": \"api\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("idempotencyKey", "8A29FC40-CA47-1067-B31D-00DD010662DB") req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby FullSplitRefund require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["idempotencyKey"] = '8A29FC40-CA47-1067-B31D-00DD010662DB' request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"amount\": 100,\n \"orderDescription\": \"Materials deposit\",\n \"refundDetails\": {\n \"splitRefunding\": [\n {\n \"accountId\": \"187-342\",\n \"amount\": 60,\n \"description\": \"Refunding undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n },\n {\n \"accountId\": \"187-343\",\n \"amount\": 40,\n \"description\": \"Refunding deposit for undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n }\n ]\n },\n \"source\": \"api\"\n}" response = http.request(request) puts response.read_body ``` ```java FullSplitRefund import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") .header("idempotencyKey", "8A29FC40-CA47-1067-B31D-00DD010662DB") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"amount\": 100,\n \"orderDescription\": \"Materials deposit\",\n \"refundDetails\": {\n \"splitRefunding\": [\n {\n \"accountId\": \"187-342\",\n \"amount\": 60,\n \"description\": \"Refunding undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n },\n {\n \"accountId\": \"187-343\",\n \"amount\": 40,\n \"description\": \"Refunding deposit for undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n }\n ]\n },\n \"source\": \"api\"\n}") .asString(); ``` ```php FullSplitRefund request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723', [ 'body' => '{ "amount": 100, "orderDescription": "Materials deposit", "refundDetails": { "splitRefunding": [ { "accountId": "187-342", "amount": 60, "description": "Refunding undelivered materials", "originationEntryPoint": "7f1a381696" }, { "accountId": "187-343", "amount": 40, "description": "Refunding deposit for undelivered materials", "originationEntryPoint": "7f1a381696" } ] }, "source": "api" }', 'headers' => [ 'Content-Type' => 'application/json', 'idempotencyKey' => '8A29FC40-CA47-1067-B31D-00DD010662DB', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift FullSplitRefund import Foundation let headers = [ "idempotencyKey": "8A29FC40-CA47-1067-B31D-00DD010662DB", "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "amount": 100, "orderDescription": "Materials deposit", "refundDetails": ["splitRefunding": [ [ "accountId": "187-342", "amount": 60, "description": "Refunding undelivered materials", "originationEntryPoint": "7f1a381696" ], [ "accountId": "187-343", "amount": 40, "description": "Refunding deposit for undelivered materials", "originationEntryPoint": "7f1a381696" ] ]], "source": "api" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript PartialSplitRefund import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.refundWithInstructions("10-3ffa27df-b171-44e0-b251-e95fbfc7a723", { idempotencyKey: "8A29FC40-CA47-1067-B31D-00DD010662DB", amount: 70, orderDescription: "Materials deposit", refundDetails: { splitRefunding: [ { accountId: "187-342", amount: 40, description: "Refunding undelivered materials", originationEntryPoint: "7f1a381696", }, { accountId: "187-343", amount: 30, description: "Refunding deposit for undelivered materials", originationEntryPoint: "7f1a381696", }, ], }, source: "api", }); } main(); ``` ```python PartialSplitRefund from payabli import payabli, RefundDetail, SplitFundingRefundContent client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.refund_with_instructions( trans_id="10-3ffa27df-b171-44e0-b251-e95fbfc7a723", idempotency_key="8A29FC40-CA47-1067-B31D-00DD010662DB", amount=70, order_description="Materials deposit", refund_details=RefundDetail( split_refunding=[ SplitFundingRefundContent( account_id="187-342", amount=40, description="Refunding undelivered materials", origination_entry_point="7f1a381696", ), SplitFundingRefundContent( account_id="187-343", amount=30, description="Refunding deposit for undelivered materials", origination_entry_point="7f1a381696", ) ], ), source="api", ) ``` ```csharp PartialSplitRefund using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.RefundWithInstructionsAsync( "10-3ffa27df-b171-44e0-b251-e95fbfc7a723", new RequestRefund { IdempotencyKey = "8A29FC40-CA47-1067-B31D-00DD010662DB", Amount = 70, OrderDescription = "Materials deposit", RefundDetails = new RefundDetail { SplitRefunding = new List(){ new SplitFundingRefundContent { AccountId = "187-342", Amount = 40, Description = "Refunding undelivered materials", OriginationEntryPoint = "7f1a381696" }, new SplitFundingRefundContent { AccountId = "187-343", Amount = 30, Description = "Refunding deposit for undelivered materials", OriginationEntryPoint = "7f1a381696" }, } }, Source = "api" } ); } } ``` ```go PartialSplitRefund package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723" payload := strings.NewReader("{\n \"amount\": 70,\n \"orderDescription\": \"Materials deposit\",\n \"refundDetails\": {\n \"splitRefunding\": [\n {\n \"accountId\": \"187-342\",\n \"amount\": 40,\n \"description\": \"Refunding undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n },\n {\n \"accountId\": \"187-343\",\n \"amount\": 30,\n \"description\": \"Refunding deposit for undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n }\n ]\n },\n \"source\": \"api\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("idempotencyKey", "8A29FC40-CA47-1067-B31D-00DD010662DB") req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby PartialSplitRefund require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["idempotencyKey"] = '8A29FC40-CA47-1067-B31D-00DD010662DB' request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"amount\": 70,\n \"orderDescription\": \"Materials deposit\",\n \"refundDetails\": {\n \"splitRefunding\": [\n {\n \"accountId\": \"187-342\",\n \"amount\": 40,\n \"description\": \"Refunding undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n },\n {\n \"accountId\": \"187-343\",\n \"amount\": 30,\n \"description\": \"Refunding deposit for undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n }\n ]\n },\n \"source\": \"api\"\n}" response = http.request(request) puts response.read_body ``` ```java PartialSplitRefund import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723") .header("idempotencyKey", "8A29FC40-CA47-1067-B31D-00DD010662DB") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"amount\": 70,\n \"orderDescription\": \"Materials deposit\",\n \"refundDetails\": {\n \"splitRefunding\": [\n {\n \"accountId\": \"187-342\",\n \"amount\": 40,\n \"description\": \"Refunding undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n },\n {\n \"accountId\": \"187-343\",\n \"amount\": 30,\n \"description\": \"Refunding deposit for undelivered materials\",\n \"originationEntryPoint\": \"7f1a381696\"\n }\n ]\n },\n \"source\": \"api\"\n}") .asString(); ``` ```php PartialSplitRefund request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723', [ 'body' => '{ "amount": 70, "orderDescription": "Materials deposit", "refundDetails": { "splitRefunding": [ { "accountId": "187-342", "amount": 40, "description": "Refunding undelivered materials", "originationEntryPoint": "7f1a381696" }, { "accountId": "187-343", "amount": 30, "description": "Refunding deposit for undelivered materials", "originationEntryPoint": "7f1a381696" } ] }, "source": "api" }', 'headers' => [ 'Content-Type' => 'application/json', 'idempotencyKey' => '8A29FC40-CA47-1067-B31D-00DD010662DB', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift PartialSplitRefund import Foundation let headers = [ "idempotencyKey": "8A29FC40-CA47-1067-B31D-00DD010662DB", "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "amount": 70, "orderDescription": "Materials deposit", "refundDetails": ["splitRefunding": [ [ "accountId": "187-342", "amount": 40, "description": "Refunding undelivered materials", "originationEntryPoint": "7f1a381696" ], [ "accountId": "187-343", "amount": 30, "description": "Refunding deposit for undelivered materials", "originationEntryPoint": "7f1a381696" ] ]], "source": "api" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/refund/10-3ffa27df-b171-44e0-b251-e95fbfc7a723")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get transaction details GET https://api-sandbox.payabli.com/api/MoneyIn/details/{transId} Retrieve a processed transaction's details. Reference: https://docs.payabli.com/developers/api-reference/moneyin/get-details-for-a-processed-transaction ## SDK Code Examples ```typescript Example Response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.details("45-as456777hhhhhhhhhh77777777-324"); } main(); ``` ```python Example Response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.details( trans_id="45-as456777hhhhhhhhhh77777777-324", ) ``` ```csharp Example Response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.DetailsAsync( "45-as456777hhhhhhhhhh77777777-324" ); } } ``` ```go Example Response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/details/45-as456777hhhhhhhhhh77777777-324" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example Response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/details/45-as456777hhhhhhhhhh77777777-324") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example Response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyIn/details/45-as456777hhhhhhhhhh77777777-324") .header("requestToken", "") .asString(); ``` ```php Example Response request('GET', 'https://api-sandbox.payabli.com/api/MoneyIn/details/45-as456777hhhhhhhhhh77777777-324', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example Response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/details/45-as456777hhhhhhhhhh77777777-324")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Make microdeposit POST https://api-sandbox.payabli.com/api/MoneyIn/makecredit Content-Type: application/json Make a temporary microdeposit in a customer account to verify the customer's ownership and access to the target account. Reverse the microdeposit with `reverseCredit`. Payabli doesn't automatically make microdeposits when you add a bank account, you must manually make the requests. This feature must be enabled by Payabli on a per-merchant basis. Contact support for help. Reference: https://docs.payabli.com/developers/api-reference/moneyin/make-an-ach-credit-transaction ## SDK Code Examples ```typescript MinimumFields import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.credit({ idempotencyKey: "6B29FC40-CA47-1067-B31D-00DD010662DA", customerData: { billingAddress1: "5127 Linkwood ave", customerNumber: "100", }, paymentDetails: { totalAmount: 1, serviceFee: 0, }, paymentMethod: { method: "ach", achAccount: "88354454", achAccountType: "Checking", achHolder: "John Smith", achRouting: "021000021", }, entrypoint: "my-entrypoint", }); } main(); ``` ```python MinimumFields from payabli import payabli, PayorDataRequest, PaymentDetailCredit from payabli.money_in import RequestCreditPaymentMethod client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.credit( idempotency_key="6B29FC40-CA47-1067-B31D-00DD010662DA", customer_data=PayorDataRequest( billing_address_1="5127 Linkwood ave", customer_number="100", ), payment_details=PaymentDetailCredit( total_amount=1, service_fee=0, ), payment_method=RequestCreditPaymentMethod( method="ach", ach_account="88354454", ach_account_type="Checking", ach_holder="John Smith", ach_routing="021000021", ), entrypoint="my-entrypoint", ) ``` ```csharp MinimumFields using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.CreditAsync( new RequestCredit { IdempotencyKey = "6B29FC40-CA47-1067-B31D-00DD010662DA", CustomerData = new PayorDataRequest { BillingAddress1 = "5127 Linkwood ave", CustomerNumber = "100" }, PaymentDetails = new PaymentDetailCredit { TotalAmount = 1, ServiceFee = 0 }, PaymentMethod = new RequestCreditPaymentMethod { Method = "ach", AchAccount = "88354454", AchAccountType = Achaccounttype.Checking, AchHolder = "John Smith", AchRouting = "021000021" }, Entrypoint = "my-entrypoint" } ); } } ``` ```go MinimumFields package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/makecredit" payload := strings.NewReader("{\n \"customerData\": {\n \"billingAddress1\": \"5127 Linkwood ave\",\n \"customerNumber\": \"100\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 1,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"achAccount\": \"88354454\",\n \"achAccountType\": \"Checking\",\n \"achHolder\": \"John Smith\",\n \"achRouting\": \"021000021\"\n },\n \"entrypoint\": \"my-entrypoint\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby MinimumFields require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/makecredit") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["idempotencyKey"] = '6B29FC40-CA47-1067-B31D-00DD010662DA' request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"billingAddress1\": \"5127 Linkwood ave\",\n \"customerNumber\": \"100\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 1,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"achAccount\": \"88354454\",\n \"achAccountType\": \"Checking\",\n \"achHolder\": \"John Smith\",\n \"achRouting\": \"021000021\"\n },\n \"entrypoint\": \"my-entrypoint\"\n}" response = http.request(request) puts response.read_body ``` ```java MinimumFields import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/makecredit") .header("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"billingAddress1\": \"5127 Linkwood ave\",\n \"customerNumber\": \"100\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 1,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"achAccount\": \"88354454\",\n \"achAccountType\": \"Checking\",\n \"achHolder\": \"John Smith\",\n \"achRouting\": \"021000021\"\n },\n \"entrypoint\": \"my-entrypoint\"\n}") .asString(); ``` ```php MinimumFields request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/makecredit', [ 'body' => '{ "customerData": { "billingAddress1": "5127 Linkwood ave", "customerNumber": "100" }, "paymentDetails": { "totalAmount": 1, "serviceFee": 0 }, "paymentMethod": { "method": "ach", "achAccount": "88354454", "achAccountType": "Checking", "achHolder": "John Smith", "achRouting": "021000021" }, "entrypoint": "my-entrypoint" }', 'headers' => [ 'Content-Type' => 'application/json', 'idempotencyKey' => '6B29FC40-CA47-1067-B31D-00DD010662DA', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift MinimumFields import Foundation let headers = [ "idempotencyKey": "6B29FC40-CA47-1067-B31D-00DD010662DA", "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": [ "billingAddress1": "5127 Linkwood ave", "customerNumber": "100" ], "paymentDetails": [ "totalAmount": 1, "serviceFee": 0 ], "paymentMethod": [ "method": "ach", "achAccount": "88354454", "achAccountType": "Checking", "achHolder": "John Smith", "achRouting": "021000021" ], "entrypoint": "my-entrypoint" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/makecredit")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript ComplexFields import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.credit({ idempotencyKey: "6B29FC40-CA47-1067-B31D-00DD010662DA", customerData: { billingAddress1: "125 Main Street", billingCity: "Kingsport", billingEmail: "johnnyp@email.com", company: "Acme, Inc", customerNumber: "100", firstName: "Johnny", lastName: "Poulsbo", }, paymentDetails: { totalAmount: 1, serviceFee: 0, }, paymentMethod: { method: "ach", achAccount: "88354554", achAccountType: "Checking", achHolder: "John Poulsbo", achRouting: "029000021", }, entrypoint: "my-entrypoint", }); } main(); ``` ```python ComplexFields from payabli import payabli, PayorDataRequest, PaymentDetailCredit from payabli.money_in import RequestCreditPaymentMethod client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.credit( idempotency_key="6B29FC40-CA47-1067-B31D-00DD010662DA", customer_data=PayorDataRequest( billing_address_1="125 Main Street", billing_city="Kingsport", billing_email="johnnyp@email.com", company="Acme, Inc", customer_number="100", first_name="Johnny", last_name="Poulsbo", ), payment_details=PaymentDetailCredit( total_amount=1, service_fee=0, ), payment_method=RequestCreditPaymentMethod( method="ach", ach_account="88354554", ach_account_type="Checking", ach_holder="John Poulsbo", ach_routing="029000021", ), entrypoint="my-entrypoint", ) ``` ```csharp ComplexFields using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.CreditAsync( new RequestCredit { IdempotencyKey = "6B29FC40-CA47-1067-B31D-00DD010662DA", CustomerData = new PayorDataRequest { BillingAddress1 = "125 Main Street", BillingCity = "Kingsport", BillingEmail = "johnnyp@email.com", Company = "Acme, Inc", CustomerNumber = "100", FirstName = "Johnny", LastName = "Poulsbo" }, PaymentDetails = new PaymentDetailCredit { TotalAmount = 1, ServiceFee = 0 }, PaymentMethod = new RequestCreditPaymentMethod { Method = "ach", AchAccount = "88354554", AchAccountType = Achaccounttype.Checking, AchHolder = "John Poulsbo", AchRouting = "029000021" }, Entrypoint = "my-entrypoint" } ); } } ``` ```go ComplexFields package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/makecredit" payload := strings.NewReader("{\n \"customerData\": {\n \"billingAddress1\": \"125 Main Street\",\n \"billingCity\": \"Kingsport\",\n \"billingEmail\": \"johnnyp@email.com\",\n \"company\": \"Acme, Inc\",\n \"customerNumber\": \"100\",\n \"firstName\": \"Johnny\",\n \"lastName\": \"Poulsbo\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 1,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"achAccount\": \"88354554\",\n \"achAccountType\": \"Checking\",\n \"achHolder\": \"John Poulsbo\",\n \"achRouting\": \"029000021\"\n },\n \"entrypoint\": \"my-entrypoint\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ComplexFields require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/makecredit") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["idempotencyKey"] = '6B29FC40-CA47-1067-B31D-00DD010662DA' request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"billingAddress1\": \"125 Main Street\",\n \"billingCity\": \"Kingsport\",\n \"billingEmail\": \"johnnyp@email.com\",\n \"company\": \"Acme, Inc\",\n \"customerNumber\": \"100\",\n \"firstName\": \"Johnny\",\n \"lastName\": \"Poulsbo\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 1,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"achAccount\": \"88354554\",\n \"achAccountType\": \"Checking\",\n \"achHolder\": \"John Poulsbo\",\n \"achRouting\": \"029000021\"\n },\n \"entrypoint\": \"my-entrypoint\"\n}" response = http.request(request) puts response.read_body ``` ```java ComplexFields import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/makecredit") .header("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"billingAddress1\": \"125 Main Street\",\n \"billingCity\": \"Kingsport\",\n \"billingEmail\": \"johnnyp@email.com\",\n \"company\": \"Acme, Inc\",\n \"customerNumber\": \"100\",\n \"firstName\": \"Johnny\",\n \"lastName\": \"Poulsbo\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 1,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"achAccount\": \"88354554\",\n \"achAccountType\": \"Checking\",\n \"achHolder\": \"John Poulsbo\",\n \"achRouting\": \"029000021\"\n },\n \"entrypoint\": \"my-entrypoint\"\n}") .asString(); ``` ```php ComplexFields request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/makecredit', [ 'body' => '{ "customerData": { "billingAddress1": "125 Main Street", "billingCity": "Kingsport", "billingEmail": "johnnyp@email.com", "company": "Acme, Inc", "customerNumber": "100", "firstName": "Johnny", "lastName": "Poulsbo" }, "paymentDetails": { "totalAmount": 1, "serviceFee": 0 }, "paymentMethod": { "method": "ach", "achAccount": "88354554", "achAccountType": "Checking", "achHolder": "John Poulsbo", "achRouting": "029000021" }, "entrypoint": "my-entrypoint" }', 'headers' => [ 'Content-Type' => 'application/json', 'idempotencyKey' => '6B29FC40-CA47-1067-B31D-00DD010662DA', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ComplexFields import Foundation let headers = [ "idempotencyKey": "6B29FC40-CA47-1067-B31D-00DD010662DA", "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": [ "billingAddress1": "125 Main Street", "billingCity": "Kingsport", "billingEmail": "johnnyp@email.com", "company": "Acme, Inc", "customerNumber": "100", "firstName": "Johnny", "lastName": "Poulsbo" ], "paymentDetails": [ "totalAmount": 1, "serviceFee": 0 ], "paymentMethod": [ "method": "ach", "achAccount": "88354554", "achAccountType": "Checking", "achHolder": "John Poulsbo", "achRouting": "029000021" ], "entrypoint": "my-entrypoint" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/makecredit")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Reverse microdeposit GET https://api-sandbox.payabli.com/api/MoneyIn/reverseCredit/{transId} Reverse microdeposits that are used to verify customer account ownership and access. The `transId` value is returned in the success response for the original credit transaction made with `api/MoneyIn/makecredit`. Reference: https://docs.payabli.com/developers/api-reference/moneyin/reverse-an-ach-credit-transaction ## SDK Code Examples ```typescript Reverse import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.reverseCredit("45-as456777hhhhhhhhhh77777777-324"); } main(); ``` ```python Reverse from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.reverse_credit( trans_id="45-as456777hhhhhhhhhh77777777-324", ) ``` ```csharp Reverse using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.ReverseCreditAsync( "45-as456777hhhhhhhhhh77777777-324" ); } } ``` ```go Reverse package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/reverseCredit/45-as456777hhhhhhhhhh77777777-324" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Reverse require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/reverseCredit/45-as456777hhhhhhhhhh77777777-324") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Reverse import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyIn/reverseCredit/45-as456777hhhhhhhhhh77777777-324") .header("requestToken", "") .asString(); ``` ```php Reverse request('GET', 'https://api-sandbox.payabli.com/api/MoneyIn/reverseCredit/45-as456777hhhhhhhhhh77777777-324', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Reverse import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/reverseCredit/45-as456777hhhhhhhhhh77777777-324")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Validate card POST https://api-sandbox.payabli.com/api/MoneyIn/validate Content-Type: application/json Validates a card number without running a transaction or authorizing a charge. Reference: https://docs.payabli.com/developers/api-reference/moneyin/validate-card ## SDK Code Examples ```typescript ValidateCard import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyIn.validate({ idempotencyKey: "6B29FC40-CA47-1067-B31D-00DD010662DA", entryPoint: "entry132", paymentMethod: { method: "card", cardnumber: "4360000001000005", cardexp: "12/29", cardzip: "14602-8328", cardHolder: "Dianne Becker-Smith", }, }); } main(); ``` ```python ValidateCard from payabli import payabli from payabli.money_in import RequestPaymentValidatePaymentMethod client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_in.validate( idempotency_key="6B29FC40-CA47-1067-B31D-00DD010662DA", entry_point="entry132", payment_method=RequestPaymentValidatePaymentMethod( method="card", cardnumber="4360000001000005", cardexp="12/29", cardzip="14602-8328", card_holder="Dianne Becker-Smith", ), ) ``` ```csharp ValidateCard using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyIn.ValidateAsync( new RequestPaymentValidate { IdempotencyKey = "6B29FC40-CA47-1067-B31D-00DD010662DA", EntryPoint = "entry132", PaymentMethod = new RequestPaymentValidatePaymentMethod { Method = RequestPaymentValidatePaymentMethodMethod.Card, Cardnumber = "4360000001000005", Cardexp = "12/29", Cardzip = "14602-8328", CardHolder = "Dianne Becker-Smith" } } ); } } ``` ```go ValidateCard package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyIn/validate" payload := strings.NewReader("{\n \"entryPoint\": \"entry132\",\n \"paymentMethod\": {\n \"method\": \"card\",\n \"cardnumber\": \"4360000001000005\",\n \"cardexp\": \"12/29\",\n \"cardzip\": \"14602-8328\",\n \"cardHolder\": \"Dianne Becker-Smith\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ValidateCard require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyIn/validate") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["idempotencyKey"] = '6B29FC40-CA47-1067-B31D-00DD010662DA' request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"entry132\",\n \"paymentMethod\": {\n \"method\": \"card\",\n \"cardnumber\": \"4360000001000005\",\n \"cardexp\": \"12/29\",\n \"cardzip\": \"14602-8328\",\n \"cardHolder\": \"Dianne Becker-Smith\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java ValidateCard import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyIn/validate") .header("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"entry132\",\n \"paymentMethod\": {\n \"method\": \"card\",\n \"cardnumber\": \"4360000001000005\",\n \"cardexp\": \"12/29\",\n \"cardzip\": \"14602-8328\",\n \"cardHolder\": \"Dianne Becker-Smith\"\n }\n}") .asString(); ``` ```php ValidateCard request('POST', 'https://api-sandbox.payabli.com/api/MoneyIn/validate', [ 'body' => '{ "entryPoint": "entry132", "paymentMethod": { "method": "card", "cardnumber": "4360000001000005", "cardexp": "12/29", "cardzip": "14602-8328", "cardHolder": "Dianne Becker-Smith" } }', 'headers' => [ 'Content-Type' => 'application/json', 'idempotencyKey' => '6B29FC40-CA47-1067-B31D-00DD010662DA', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ValidateCard import Foundation let headers = [ "idempotencyKey": "6B29FC40-CA47-1067-B31D-00DD010662DA", "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "entry132", "paymentMethod": [ "method": "card", "cardnumber": "4360000001000005", "cardexp": "12/29", "cardzip": "14602-8328", "cardHolder": "Dianne Becker-Smith" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyIn/validate")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Capture check (RDC) POST https://api-sandbox.payabli.com/api/CheckCapture/CheckProcessing Content-Type: application/json Captures a check for Remote Deposit Capture (RDC) using the provided check images and details. This endpoint handles the OCR extraction of check data including MICR, routing number, account number, and amount. See the [RDC guide](/developers/developer-guides/pay-in-rdc) for more details. Reference: https://docs.payabli.com/developers/api-reference/moneyin/check-capture ## SDK Code Examples ```typescript Capture import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.checkCapture.checkProcessing({ entryPoint: "47abcfea12", frontImage: "/9j/4AAQSkZJRgABAQEASABIAAD...", rearImage: "/9j/4AAQSkZJRgABAQEASABIAAD...", checkAmount: 12550, }); } main(); ``` ```python Capture from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.check_capture.check_processing( entry_point="47abcfea12", front_image="/9j/4AAQSkZJRgABAQEASABIAAD...", rear_image="/9j/4AAQSkZJRgABAQEASABIAAD...", check_amount=12550, ) ``` ```csharp Capture using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.CheckCapture.CheckProcessingAsync( new CheckCaptureRequestBody { EntryPoint = "47abcfea12", FrontImage = "/9j/4AAQSkZJRgABAQEASABIAAD...", RearImage = "/9j/4AAQSkZJRgABAQEASABIAAD...", CheckAmount = 12550 } ); } } ``` ```go Capture package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/CheckCapture/CheckProcessing" payload := strings.NewReader("{\n \"entryPoint\": \"47abcfea12\",\n \"frontImage\": \"/9j/4AAQSkZJRgABAQEASABIAAD...\",\n \"rearImage\": \"/9j/4AAQSkZJRgABAQEASABIAAD...\",\n \"checkAmount\": 12550\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Capture require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/CheckCapture/CheckProcessing") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"47abcfea12\",\n \"frontImage\": \"/9j/4AAQSkZJRgABAQEASABIAAD...\",\n \"rearImage\": \"/9j/4AAQSkZJRgABAQEASABIAAD...\",\n \"checkAmount\": 12550\n}" response = http.request(request) puts response.read_body ``` ```java Capture import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/CheckCapture/CheckProcessing") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"47abcfea12\",\n \"frontImage\": \"/9j/4AAQSkZJRgABAQEASABIAAD...\",\n \"rearImage\": \"/9j/4AAQSkZJRgABAQEASABIAAD...\",\n \"checkAmount\": 12550\n}") .asString(); ``` ```php Capture request('POST', 'https://api-sandbox.payabli.com/api/CheckCapture/CheckProcessing', [ 'body' => '{ "entryPoint": "47abcfea12", "frontImage": "/9j/4AAQSkZJRgABAQEASABIAAD...", "rearImage": "/9j/4AAQSkZJRgABAQEASABIAAD...", "checkAmount": 12550 }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Capture import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "47abcfea12", "frontImage": "/9j/4AAQSkZJRgABAQEASABIAAD...", "rearImage": "/9j/4AAQSkZJRgABAQEASABIAAD...", "checkAmount": 12550 ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/CheckCapture/CheckProcessing")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List transactions for paypoint GET https://api-sandbox.payabli.com/api/Query/transactions/{entry} Retrieve a list of transactions for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. By default, this endpoint returns only transactions from the last 60 days. To query transactions outside of this period, include `transactionDate` filters. For example, this request parameters filter for transactions between April 01, 2024 and April 09, 2024. ``` curl --request GET \ --url https://sandbox.payabli.com/api/Query/transactions/org/1?limitRecord=20&fromRecord=0&transactionDate(ge)=2024-04-01T00:00:00&transactionDate(le)=2024-04-09T23:59:59\ --header 'requestToken: ' ``` Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-transactions-for-an-entrypoint ## SDK Code Examples ```typescript Example import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listTransactions("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_transactions( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListTransactionsAsync( "8cfec329267", new ListTransactionsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/transactions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/transactions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/transactions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example request('GET', 'https://api-sandbox.payabli.com/api/Query/transactions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/transactions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List transactions for org GET https://api-sandbox.payabli.com/api/Query/transactions/org/{orgId} Retrieve a list of transactions for an organization. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. By default, this endpoint returns only transactions from the last 60 days. To query transactions outside of this period, include `transactionDate` filters. For example, this request parameters filter for transactions between April 01, 2024 and April 09, 2024. ``` curl --request GET \ --url https://sandbox.payabli.com/api/Query/transactions/org/1?limitRecord=20&fromRecord=0&transactionDate(ge)=2024-04-01T00:00:00&transactionDate(le)=2024-04-09T23:59:59\ --header 'requestToken: ' ``` Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-transactions-for-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listTransactionsOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_transactions_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListTransactionsOrgAsync( 123, new ListTransactionsOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/transactions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/transactions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/transactions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/transactions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/transactions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List settled transactions for paypoint GET https://api-sandbox.payabli.com/api/Query/settlements/{entry} Retrieve a list of settled transactions for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-settled-transactions-for-an-entrypoint ## SDK Code Examples ```typescript Example query response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listSettlements("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example query response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_settlements( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example query response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListSettlementsAsync( "8cfec329267", new ListSettlementsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example query response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/settlements/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example query response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/settlements/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example query response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/settlements/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example query response request('GET', 'https://api-sandbox.payabli.com/api/Query/settlements/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example query response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/settlements/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List settled transactions for org GET https://api-sandbox.payabli.com/api/Query/settlements/org/{orgId} Retrieve a list of settled transactions for an organization. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-settled-transactions-for-an-org ## SDK Code Examples ```typescript Example query response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listSettlementsOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example query response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_settlements_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example query response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListSettlementsOrgAsync( 123, new ListSettlementsOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example query response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/settlements/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example query response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/settlements/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example query response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/settlements/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example query response request('GET', 'https://api-sandbox.payabli.com/api/Query/settlements/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example query response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/settlements/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List batches for paypoint GET https://api-sandbox.payabli.com/api/Query/batches/{entry} Retrieve a list of batches for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-batches-for-an-entrypoint ## SDK Code Examples ```typescript GetBatches import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listBatches("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python GetBatches from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_batches( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp GetBatches using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListBatchesAsync( "8cfec329267", new ListBatchesRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go GetBatches package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/batches/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetBatches require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/batches/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetBatches import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/batches/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php GetBatches request('GET', 'https://api-sandbox.payabli.com/api/Query/batches/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetBatches import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/batches/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List batches for org GET https://api-sandbox.payabli.com/api/Query/batches/org/{orgId} Retrieve a list of batches for an org. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-batches-for-an-organization ## SDK Code Examples ```typescript Example Response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listBatchesOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example Response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_batches_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example Response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListBatchesOrgAsync( 123, new ListBatchesOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example Response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/batches/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example Response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/batches/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example Response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/batches/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example Response request('GET', 'https://api-sandbox.payabli.com/api/Query/batches/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example Response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/batches/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List batch details GET https://api-sandbox.payabli.com/api/Query/batchDetails/{entry} Retrieve a list of batches and their details, including settled and unsettled transactions for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-batchdetails-for-an-entrypoint ## SDK Code Examples ```typescript ListBatchExampleRecord import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listBatchDetails("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python ListBatchExampleRecord from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_batch_details( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp ListBatchExampleRecord using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListBatchDetailsAsync( "8cfec329267", new ListBatchDetailsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go ListBatchExampleRecord package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/batchDetails/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListBatchExampleRecord require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/batchDetails/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java ListBatchExampleRecord import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/batchDetails/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php ListBatchExampleRecord request('GET', 'https://api-sandbox.payabli.com/api/Query/batchDetails/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ListBatchExampleRecord import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/batchDetails/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List batch details for org GET https://api-sandbox.payabli.com/api/Query/batchDetails/org/{orgId} Retrieve a list of batches and their details, including settled and unsettled transactions for an organization. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-batchdetails-for-an-organization ## SDK Code Examples ```typescript Example query response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listBatchDetailsOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example query response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_batch_details_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example query response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListBatchDetailsOrgAsync( 123, new ListBatchDetailsOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example query response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/batchDetails/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example query response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/batchDetails/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example query response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/batchDetails/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example query response request('GET', 'https://api-sandbox.payabli.com/api/Query/batchDetails/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example query response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/batchDetails/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List transfers GET https://api-sandbox.payabli.com/api/Query/transfers/{entry} Retrieve a list of transfers for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-transfers ## SDK Code Examples ```typescript ListTransfer import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient(); await client.query.listTransfers("47862acd", { fromRecord: 0, limitRecord: 20, }); } main(); ``` ```python ListTransfer from payabli import payabli client = payabli() client.query.list_transfers( entry="47862acd", from_record=0, limit_record=20, ) ``` ```csharp ListTransfer using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient(); await client.Query.ListTransfersAsync( "47862acd", new ListTransfersRequest { FromRecord = 0, LimitRecord = 20 } ); } } ``` ```go ListTransfer package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/transfers/47862acd?fromRecord=0&limitRecord=20" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListTransfer require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/transfers/47862acd?fromRecord=0&limitRecord=20") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) response = http.request(request) puts response.read_body ``` ```java ListTransfer import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/transfers/47862acd?fromRecord=0&limitRecord=20") .asString(); ``` ```php ListTransfer request('GET', 'https://api-sandbox.payabli.com/api/Query/transfers/47862acd?fromRecord=0&limitRecord=20'); echo $response->getBody(); ``` ```swift ListTransfer import Foundation let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/transfers/47862acd?fromRecord=0&limitRecord=20")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List transfers for org GET https://api-sandbox.payabli.com/api/Query/transfers/org/{orgId} Retrieve a list of transfers for an org. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-transfers-for-an-organization ## SDK Code Examples ```typescript ListTransferOrg import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient(); await client.query.listTransfersOrg(123, { fromRecord: 0, limitRecord: 20, }); } main(); ``` ```python ListTransferOrg from payabli import payabli client = payabli() client.query.list_transfers_org( org_id=123, from_record=0, limit_record=20, ) ``` ```csharp ListTransferOrg using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient(); await client.Query.ListTransfersOrgAsync( new ListTransfersRequestOrg { OrgId = 123L, FromRecord = 0, LimitRecord = 20 } ); } } ``` ```go ListTransferOrg package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/transfers/org/123?fromRecord=0&limitRecord=20" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListTransferOrg require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/transfers/org/123?fromRecord=0&limitRecord=20") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) response = http.request(request) puts response.read_body ``` ```java ListTransferOrg import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/transfers/org/123?fromRecord=0&limitRecord=20") .asString(); ``` ```php ListTransferOrg request('GET', 'https://api-sandbox.payabli.com/api/Query/transfers/org/123?fromRecord=0&limitRecord=20'); echo $response->getBody(); ``` ```swift ListTransferOrg import Foundation let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/transfers/org/123?fromRecord=0&limitRecord=20")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get transfer details GET https://api-sandbox.payabli.com/api/Query/transferDetails/{entry}/{transferId} Retrieve a list of transfer details records for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-transfer-details ## SDK Code Examples ```typescript ListTransferDetailsPaypoint import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listTransferDetails("47862acd", 123456, {}); } main(); ``` ```python ListTransferDetailsPaypoint from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_transfer_details( entry="47862acd", transfer_id=123456, ) ``` ```csharp ListTransferDetailsPaypoint using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListTransferDetailsAsync( "47862acd", 123456, new ListTransfersPaypointRequest() ); } } ``` ```go ListTransferDetailsPaypoint package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/transferDetails/47862acd/123456" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListTransferDetailsPaypoint require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/transferDetails/47862acd/123456") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java ListTransferDetailsPaypoint import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/transferDetails/47862acd/123456") .header("requestToken", "") .asString(); ``` ```php ListTransferDetailsPaypoint request('GET', 'https://api-sandbox.payabli.com/api/Query/transferDetails/47862acd/123456', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ListTransferDetailsPaypoint import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/transferDetails/47862acd/123456")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export batches for paypoint GET https://api-sandbox.payabli.com/api/Export/batches/{format}/{entry} Export a list of batches for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-batches-for-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportBatches("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_batches( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportBatchesAsync( ExportFormat1.Csv, "8cfec329267", new ExportBatchesRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/batches/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/batches/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/batches/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/batches/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/batches/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export batches for org GET https://api-sandbox.payabli.com/api/Export/batches/{format}/org/{orgId} Export a list of batches for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-batches-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportBatchesOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_batches_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportBatchesOrgAsync( ExportFormat1.Csv, 123, new ExportBatchesOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/batches/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/batches/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/batches/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/batches/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/batches/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export batch details for paypoint GET https://api-sandbox.payabli.com/api/Export/batchDetails/{format}/{entry} This endpoint is deprecated. Export batch details for a paypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-batch-details-for-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportBatchDetails("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_batch_details( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportBatchDetailsAsync( ExportFormat1.Csv, "8cfec329267", new ExportBatchDetailsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/batchDetails/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/batchDetails/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/batchDetails/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/batchDetails/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/batchDetails/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export batch details for org GET https://api-sandbox.payabli.com/api/Export/batchDetails/{format}/org/{orgId} This endpoint is deprecated. Export batch details for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-batch-details-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportBatchDetailsOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_batch_details_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportBatchDetailsOrgAsync( ExportFormat1.Csv, 123, new ExportBatchDetailsOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/batchDetails/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/batchDetails/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/batchDetails/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/batchDetails/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/batchDetails/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export settled transactions for paypoint GET https://api-sandbox.payabli.com/api/Export/settlements/{format}/{entry} Export a list of settled transactions for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-settled-transactions-for-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportSettlements("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_settlements( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportSettlementsAsync( ExportFormat1.Csv, "8cfec329267", new ExportSettlementsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/settlements/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/settlements/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/settlements/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/settlements/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/settlements/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export settled transactions for org GET https://api-sandbox.payabli.com/api/Export/settlements/{format}/org/{orgId} Export a list of settled transactions for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-settled-transactions-for-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportSettlementsOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_settlements_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportSettlementsOrgAsync( ExportFormat1.Csv, 123, new ExportSettlementsOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/settlements/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/settlements/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/settlements/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/settlements/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/settlements/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export transactions for paypoint GET https://api-sandbox.payabli.com/api/Export/transactions/{format}/{entry} Export a list of transactions for an entrypoint in a file in XLXS or CSV format. Use filters to limit results. If you don't specify a date range in the request, the last two months of data are returned. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-transactions-for-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportTransactions("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_transactions( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportTransactionsAsync( ExportFormat1.Csv, "8cfec329267", new ExportTransactionsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/transactions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/transactions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/transactions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/transactions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/transactions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export transactions for org GET https://api-sandbox.payabli.com/api/Export/transactions/{format}/org/{orgId} Export a list of transactions for an org in a file in XLSX or CSV format. Use filters to limit results. If you don't specify a date range in the request, the last two months of data are returned. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-transactions-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportTransactionsOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_transactions_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportTransactionsOrgAsync( ExportFormat1.Csv, 123, new ExportTransactionsOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/transactions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/transactions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/transactions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/transactions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/transactions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export transfers for paypoint GET https://api-sandbox.payabli.com/api/Export/transfers/{entry} Get a list of transfers for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-transfers ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportTransfers("8cfec329267", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_transfers( entry="8cfec329267", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportTransfersAsync( "8cfec329267", new ExportTransfersRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/transfers/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/transfers/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/transfers/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/transfers/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/transfers/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export transfer details GET https://api-sandbox.payabli.com/api/Export/transferDetails/{format}/{entry}/{transferId} Export a list of transfer details for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-transferdetails ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportTransferDetails("8cfec329267", "csv", 1000000, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_transfer_details( entry="8cfec329267", format="csv", transfer_id=1000000, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportTransferDetailsAsync( ExportFormat1.Csv, "8cfec329267", 1000000L, new ExportTransferDetailsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/transferDetails/csv/8cfec329267/1000000?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/transferDetails/csv/8cfec329267/1000000?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/transferDetails/csv/8cfec329267/1000000?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/transferDetails/csv/8cfec329267/1000000?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/transferDetails/csv/8cfec329267/1000000?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create subscription POST https://api-sandbox.payabli.com/api/Subscription/add Content-Type: application/json Creates a subscription or scheduled payment to run at a specified time and frequency. Reference: https://docs.payabli.com/developers/api-reference/subscription/create-a-subscription-or-scheduled-payment ## SDK Code Examples ```typescript CardSubscription import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.subscription.newSubscription({ body: { customerData: { customerId: 4440, }, entryPoint: "f743aed24a", paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { cardcvv: "123", cardexp: "02/25", cardHolder: "John Cassian", cardnumber: "4111111111111111", cardzip: "37615", initiator: "payor", method: "card", }, scheduleDetails: { endDate: "03-20-2025", frequency: "weekly", planId: 1, startDate: "09-20-2024", }, }, }); } main(); ``` ```python CardSubscription from payabli import payabli, PayorDataRequest, PaymentDetail, PayMethodCredit, ScheduleDetail client = payabli( api_key="YOUR_API_KEY_HERE", ) client.subscription.new_subscription( customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( cardcvv="123", cardexp="02/25", card_holder="John Cassian", cardnumber="4111111111111111", cardzip="37615", initiator="payor", method="card", ), schedule_details=ScheduleDetail( end_date="03-20-2025", frequency="weekly", plan_id=1, start_date="09-20-2024", ), ) ``` ```csharp CardSubscription using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Subscription.NewSubscriptionAsync( new RequestSchedule { Body = new SubscriptionRequestBody { CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Cardcvv = "123", Cardexp = "02/25", CardHolder = "John Cassian", Cardnumber = "4111111111111111", Cardzip = "37615", Initiator = "payor", Method = "card" }, ScheduleDetails = new ScheduleDetail { EndDate = "03-20-2025", Frequency = Frequency.Weekly, PlanId = 1, StartDate = "09-20-2024" } } } ); } } ``` ```go CardSubscription package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Subscription/add" payload := strings.NewReader("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"37615\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CardSubscription require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Subscription/add") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"37615\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java CardSubscription import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Subscription/add") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Cassian\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"37615\",\n \"initiator\": \"payor\",\n \"method\": \"card\"\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}") .asString(); ``` ```php CardSubscription request('POST', 'https://api-sandbox.payabli.com/api/Subscription/add', [ 'body' => '{ "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "37615", "initiator": "payor", "method": "card" }, "scheduleDetails": { "endDate": "03-20-2025", "frequency": "weekly", "planId": 1, "startDate": "09-20-2024" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CardSubscription import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Cassian", "cardnumber": "4111111111111111", "cardzip": "37615", "initiator": "payor", "method": "card" ], "scheduleDetails": [ "endDate": "03-20-2025", "frequency": "weekly", "planId": 1, "startDate": "09-20-2024" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Subscription/add")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript ACHSubscription import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.subscription.newSubscription({ body: { customerData: { customerId: 4440, }, entryPoint: "f743aed24a", paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { method: "ach", }, scheduleDetails: { endDate: "03-20-2025", frequency: "weekly", planId: 1, startDate: "09-20-2024", }, }, }); } main(); ``` ```python ACHSubscription from payabli import payabli, PayorDataRequest, PaymentDetail, PayMethodCredit, ScheduleDetail client = payabli( api_key="YOUR_API_KEY_HERE", ) client.subscription.new_subscription( customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( method="ach", ), schedule_details=ScheduleDetail( end_date="03-20-2025", frequency="weekly", plan_id=1, start_date="09-20-2024", ), ) ``` ```csharp ACHSubscription using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Subscription.NewSubscriptionAsync( new RequestSchedule { Body = new SubscriptionRequestBody { CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Method = "ach" }, ScheduleDetails = new ScheduleDetail { EndDate = "03-20-2025", Frequency = Frequency.Weekly, PlanId = 1, StartDate = "09-20-2024" } } } ); } } ``` ```go ACHSubscription package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Subscription/add" payload := strings.NewReader("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"achAccount\": \"3453445666\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"PPD\",\n \"achHolder\": \"John Cassian\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"021000021\",\n \"method\": \"ach\"\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ACHSubscription require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Subscription/add") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"achAccount\": \"3453445666\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"PPD\",\n \"achHolder\": \"John Cassian\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"021000021\",\n \"method\": \"ach\"\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java ACHSubscription import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Subscription/add") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"achAccount\": \"3453445666\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"PPD\",\n \"achHolder\": \"John Cassian\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"021000021\",\n \"method\": \"ach\"\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}") .asString(); ``` ```php ACHSubscription request('POST', 'https://api-sandbox.payabli.com/api/Subscription/add', [ 'body' => '{ "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "achAccount": "3453445666", "achAccountType": "Checking", "achCode": "PPD", "achHolder": "John Cassian", "achHolderType": "personal", "achRouting": "021000021", "method": "ach" }, "scheduleDetails": { "endDate": "03-20-2025", "frequency": "weekly", "planId": 1, "startDate": "09-20-2024" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ACHSubscription import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "achAccount": "3453445666", "achAccountType": "Checking", "achCode": "PPD", "achHolder": "John Cassian", "achHolderType": "personal", "achRouting": "021000021", "method": "ach" ], "scheduleDetails": [ "endDate": "03-20-2025", "frequency": "weekly", "planId": 1, "startDate": "09-20-2024" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Subscription/add")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript StoredMethodSubscription import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.subscription.newSubscription({ body: { customerData: { customerId: 4440, }, entryPoint: "f743aed24a", paymentDetails: { totalAmount: 100, serviceFee: 0, }, paymentMethod: { initiator: "merchant", }, scheduleDetails: { endDate: "03-20-2025", frequency: "weekly", planId: 1, startDate: "09-20-2024", }, }, }); } main(); ``` ```python StoredMethodSubscription from payabli import payabli, PayorDataRequest, PaymentDetail, PayMethodCredit, ScheduleDetail client = payabli( api_key="YOUR_API_KEY_HERE", ) client.subscription.new_subscription( customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", payment_details=PaymentDetail( total_amount=100, service_fee=0, ), payment_method=PayMethodCredit( initiator="merchant", ), schedule_details=ScheduleDetail( end_date="03-20-2025", frequency="weekly", plan_id=1, start_date="09-20-2024", ), ) ``` ```csharp StoredMethodSubscription using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Subscription.NewSubscriptionAsync( new RequestSchedule { Body = new SubscriptionRequestBody { CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, PaymentMethod = new PayMethodCredit { Initiator = "merchant" }, ScheduleDetails = new ScheduleDetail { EndDate = "03-20-2025", Frequency = Frequency.Weekly, PlanId = 1, StartDate = "09-20-2024" } } } ); } } ``` ```go StoredMethodSubscription package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Subscription/add" payload := strings.NewReader("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"initiator\": \"merchant\",\n \"storedMethodId\": \"4000e8c6-3add-4200-8ac2-9b8a4f8b1639-1323\",\n \"storedMethodUsageType\": \"recurring\"\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby StoredMethodSubscription require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Subscription/add") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"initiator\": \"merchant\",\n \"storedMethodId\": \"4000e8c6-3add-4200-8ac2-9b8a4f8b1639-1323\",\n \"storedMethodUsageType\": \"recurring\"\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java StoredMethodSubscription import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Subscription/add") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"paymentMethod\": {\n \"initiator\": \"merchant\",\n \"storedMethodId\": \"4000e8c6-3add-4200-8ac2-9b8a4f8b1639-1323\",\n \"storedMethodUsageType\": \"recurring\"\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}") .asString(); ``` ```php StoredMethodSubscription request('POST', 'https://api-sandbox.payabli.com/api/Subscription/add', [ 'body' => '{ "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "paymentMethod": { "initiator": "merchant", "storedMethodId": "4000e8c6-3add-4200-8ac2-9b8a4f8b1639-1323", "storedMethodUsageType": "recurring" }, "scheduleDetails": { "endDate": "03-20-2025", "frequency": "weekly", "planId": 1, "startDate": "09-20-2024" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift StoredMethodSubscription import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "paymentMethod": [ "initiator": "merchant", "storedMethodId": "4000e8c6-3add-4200-8ac2-9b8a4f8b1639-1323", "storedMethodUsageType": "recurring" ], "scheduleDetails": [ "endDate": "03-20-2025", "frequency": "weekly", "planId": 1, "startDate": "09-20-2024" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Subscription/add")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get subscription GET https://api-sandbox.payabli.com/api/Subscription/{subId} Retrieves a single subscription's details. Reference: https://docs.payabli.com/developers/api-reference/subscription/get-subscription ## SDK Code Examples ```typescript GetSubscription import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.subscription.getSubscription(263); } main(); ``` ```python GetSubscription from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.subscription.get_subscription( sub_id=263, ) ``` ```csharp GetSubscription using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Subscription.GetSubscriptionAsync( 263 ); } } ``` ```go GetSubscription package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Subscription/263" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetSubscription require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Subscription/263") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetSubscription import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Subscription/263") .header("requestToken", "") .asString(); ``` ```php GetSubscription request('GET', 'https://api-sandbox.payabli.com/api/Subscription/263', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetSubscription import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Subscription/263")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update subscription PUT https://api-sandbox.payabli.com/api/Subscription/{subId} Content-Type: application/json Updates a subscription's details. Reference: https://docs.payabli.com/developers/api-reference/subscription/update-subscription ## SDK Code Examples ```typescript PauseSubscription import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.subscription.updateSubscription(231, { setPause: true, }); } main(); ``` ```python PauseSubscription from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.subscription.update_subscription( sub_id=231, set_pause=True, ) ``` ```csharp PauseSubscription using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Subscription.UpdateSubscriptionAsync( 231, new RequestUpdateSchedule { SetPause = true } ); } } ``` ```go PauseSubscription package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Subscription/231" payload := strings.NewReader("{\n \"setPause\": true\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby PauseSubscription require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Subscription/231") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"setPause\": true\n}" response = http.request(request) puts response.read_body ``` ```java PauseSubscription import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Subscription/231") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"setPause\": true\n}") .asString(); ``` ```php PauseSubscription request('PUT', 'https://api-sandbox.payabli.com/api/Subscription/231', [ 'body' => '{ "setPause": true }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift PauseSubscription import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["setPause": true] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Subscription/231")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript UnpauseSubscription import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.subscription.updateSubscription(231, { setPause: false, }); } main(); ``` ```python UnpauseSubscription from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.subscription.update_subscription( sub_id=231, set_pause=False, ) ``` ```csharp UnpauseSubscription using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Subscription.UpdateSubscriptionAsync( 231, new RequestUpdateSchedule { SetPause = false } ); } } ``` ```go UnpauseSubscription package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Subscription/231" payload := strings.NewReader("{\n \"setPause\": false\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UnpauseSubscription require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Subscription/231") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"setPause\": false\n}" response = http.request(request) puts response.read_body ``` ```java UnpauseSubscription import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Subscription/231") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"setPause\": false\n}") .asString(); ``` ```php UnpauseSubscription request('PUT', 'https://api-sandbox.payabli.com/api/Subscription/231', [ 'body' => '{ "setPause": false }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UnpauseSubscription import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["setPause": false] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Subscription/231")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript UpdateSubscription import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.subscription.updateSubscription(231, { paymentDetails: { totalAmount: 100, serviceFee: 0, }, scheduleDetails: { endDate: "03-20-2025", frequency: "weekly", planId: 1, startDate: "09-20-2024", }, }); } main(); ``` ```python UpdateSubscription from payabli import payabli, PaymentDetail, ScheduleDetail client = payabli( api_key="YOUR_API_KEY_HERE", ) client.subscription.update_subscription( sub_id=231, payment_details=PaymentDetail( total_amount=100, service_fee=0, ), schedule_details=ScheduleDetail( end_date="03-20-2025", frequency="weekly", plan_id=1, start_date="09-20-2024", ), ) ``` ```csharp UpdateSubscription using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Subscription.UpdateSubscriptionAsync( 231, new RequestUpdateSchedule { PaymentDetails = new PaymentDetail { TotalAmount = 100, ServiceFee = 0 }, ScheduleDetails = new ScheduleDetail { EndDate = "03-20-2025", Frequency = Frequency.Weekly, PlanId = 1, StartDate = "09-20-2024" } } ); } } ``` ```go UpdateSubscription package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Subscription/231" payload := strings.NewReader("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdateSubscription require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Subscription/231") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdateSubscription import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Subscription/231") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentDetails\": {\n \"totalAmount\": 100,\n \"serviceFee\": 0\n },\n \"scheduleDetails\": {\n \"endDate\": \"03-20-2025\",\n \"frequency\": \"weekly\",\n \"planId\": 1,\n \"startDate\": \"09-20-2024\"\n }\n}") .asString(); ``` ```php UpdateSubscription request('PUT', 'https://api-sandbox.payabli.com/api/Subscription/231', [ 'body' => '{ "paymentDetails": { "totalAmount": 100, "serviceFee": 0 }, "scheduleDetails": { "endDate": "03-20-2025", "frequency": "weekly", "planId": 1, "startDate": "09-20-2024" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdateSubscription import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentDetails": [ "totalAmount": 100, "serviceFee": 0 ], "scheduleDetails": [ "endDate": "03-20-2025", "frequency": "weekly", "planId": 1, "startDate": "09-20-2024" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Subscription/231")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete subscription DELETE https://api-sandbox.payabli.com/api/Subscription/{subId} Deletes a subscription, autopay, or recurring payment and prevents future charges. Reference: https://docs.payabli.com/developers/api-reference/subscription/remove-a-subscription ## SDK Code Examples ```typescript DeleteSubscription import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.subscription.removeSubscription(396); } main(); ``` ```python DeleteSubscription from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.subscription.remove_subscription( sub_id=396, ) ``` ```csharp DeleteSubscription using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Subscription.RemoveSubscriptionAsync( 396 ); } } ``` ```go DeleteSubscription package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Subscription/396" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby DeleteSubscription require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Subscription/396") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java DeleteSubscription import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Subscription/396") .header("requestToken", "") .asString(); ``` ```php DeleteSubscription request('DELETE', 'https://api-sandbox.payabli.com/api/Subscription/396', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift DeleteSubscription import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Subscription/396")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List subscriptions by paypoint GET https://api-sandbox.payabli.com/api/Query/subscriptions/{entry} Returns a list of subscriptions for a single paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/subscription/get-list-of-subscriptions-for-an-entrypoint ## SDK Code Examples ```typescript Example import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listSubscriptions("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_subscriptions( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListSubscriptionsAsync( "8cfec329267", new ListSubscriptionsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/subscriptions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/subscriptions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/subscriptions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example request('GET', 'https://api-sandbox.payabli.com/api/Query/subscriptions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/subscriptions/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List subscriptions by organization GET https://api-sandbox.payabli.com/api/Query/subscriptions/org/{orgId} Returns a list of subscriptions for a single org. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/subscription/get-list-of-subscriptions-for-an-org ## SDK Code Examples ```typescript Example import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listSubscriptionsOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_subscriptions_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListSubscriptionsOrgAsync( 123, new ListSubscriptionsOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/subscriptions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/subscriptions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/subscriptions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example request('GET', 'https://api-sandbox.payabli.com/api/Query/subscriptions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/subscriptions/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export subscriptions by paypoint GET https://api-sandbox.payabli.com/api/Export/subscriptions/{format}/{entry} Export a list of subscriptions for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/subscription/export-list-of-subscriptions-for-an-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportSubscriptions("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_subscriptions( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportSubscriptionsAsync( ExportFormat1.Csv, "8cfec329267", new ExportSubscriptionsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/subscriptions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/subscriptions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/subscriptions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/subscriptions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/subscriptions/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export subscriptions by org GET https://api-sandbox.payabli.com/api/Export/subscriptions/{format}/org/{orgId} Export a list of subscriptions for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/subscription/export-list-of-subscriptions-for-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportSubscriptionsOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_subscriptions_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportSubscriptionsOrgAsync( ExportFormat1.Csv, 123, new ExportSubscriptionsOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/subscriptions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/subscriptions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/subscriptions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/subscriptions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/subscriptions/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get subscription stats GET https://api-sandbox.payabli.com/api/Statistic/subscriptions/{interval}/{level}/{entryId} Retrieves the subscription statistics for a given interval for a paypoint or organization. Reference: https://docs.payabli.com/developers/api-reference/subscription/get-subscription-statistics-for-a-paypoint-or-organization ## SDK Code Examples ```typescript SubStatsExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.statistic.subStats(1000000, "30", 1, {}); } main(); ``` ```python SubStatsExample from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.statistic.sub_stats( entry_id=1000000, interval="30", level=1, ) ``` ```csharp SubStatsExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Statistic.SubStatsAsync( "30", 1, 1000000L, new SubStatsRequest() ); } } ``` ```go SubStatsExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Statistic/subscriptions/30/1/1000000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby SubStatsExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Statistic/subscriptions/30/1/1000000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java SubStatsExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Statistic/subscriptions/30/1/1000000") .header("requestToken", "") .asString(); ``` ```php SubStatsExample request('GET', 'https://api-sandbox.payabli.com/api/Statistic/subscriptions/30/1/1000000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift SubStatsExample import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Statistic/subscriptions/30/1/1000000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Tokenize payment method POST https://api-sandbox.payabli.com/api/TokenStorage/add Content-Type: application/json Saves a payment method for reuse. This call exchanges sensitive payment information for a token that can be used to process future transactions. The `ReferenceId` value in the response is the `storedMethodId` to use with transactions. Reference: https://docs.payabli.com/developers/api-reference/tokenstorage/save-a-payment-method-tokenize ## SDK Code Examples ```typescript TokenizeCard import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.addMethod({ body: { customerData: { customerId: 4440, }, entryPoint: "f743aed24a", fallbackAuth: true, fallbackAuthAmount: 100, methodDescription: "Primary Visa card", paymentMethod: { cardcvv: "123", cardexp: "02/25", cardHolder: "John Doe", cardnumber: "4111111111111111", cardzip: "12345", method: "card", }, source: "api", }, }); } main(); ``` ```python TokenizeCard from payabli import payabli, PayorDataRequest from payabli.token_storage import TokenizeCard client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.add_method( customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", fallback_auth=True, fallback_auth_amount=100, method_description="Primary Visa card", payment_method=TokenizeCard( cardcvv="123", cardexp="02/25", card_holder="John Doe", cardnumber="4111111111111111", cardzip="12345", method="card", ), source="api", ) ``` ```csharp TokenizeCard using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.AddMethodAsync( new AddMethodRequest { Body = new RequestTokenStorage { CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", FallbackAuth = true, FallbackAuthAmount = 100, MethodDescription = "Primary Visa card", PaymentMethod = new TokenizeCard { Cardcvv = "123", Cardexp = "02/25", CardHolder = "John Doe", Cardnumber = "4111111111111111", Cardzip = "12345", Method = "card" }, Source = "api" } } ); } } ``` ```go TokenizeCard package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/add" payload := strings.NewReader("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"fallbackAuthAmount\": 100,\n \"methodDescription\": \"Primary Visa card\",\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Doe\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"method\": \"card\"\n },\n \"source\": \"api\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby TokenizeCard require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/add") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"fallbackAuthAmount\": 100,\n \"methodDescription\": \"Primary Visa card\",\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Doe\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"method\": \"card\"\n },\n \"source\": \"api\"\n}" response = http.request(request) puts response.read_body ``` ```java TokenizeCard import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/TokenStorage/add") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"fallbackAuthAmount\": 100,\n \"methodDescription\": \"Primary Visa card\",\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Doe\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"method\": \"card\"\n },\n \"source\": \"api\"\n}") .asString(); ``` ```php TokenizeCard request('POST', 'https://api-sandbox.payabli.com/api/TokenStorage/add', [ 'body' => '{ "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "fallbackAuth": true, "fallbackAuthAmount": 100, "methodDescription": "Primary Visa card", "paymentMethod": { "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Doe", "cardnumber": "4111111111111111", "cardzip": "12345", "method": "card" }, "source": "api" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift TokenizeCard import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "fallbackAuth": true, "fallbackAuthAmount": 100, "methodDescription": "Primary Visa card", "paymentMethod": [ "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Doe", "cardnumber": "4111111111111111", "cardzip": "12345", "method": "card" ], "source": "api" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/add")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript TokenizeCardAnonymous import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.addMethod({ createAnonymous: true, body: { entryPoint: "f743aed24a", fallbackAuth: true, paymentMethod: { cardcvv: "123", cardexp: "02/25", cardHolder: "John Doe", cardnumber: "4111111111111111", cardzip: "12345", method: "card", }, }, }); } main(); ``` ```python TokenizeCardAnonymous from payabli import payabli from payabli.token_storage import TokenizeCard client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.add_method( create_anonymous=True, entry_point="f743aed24a", fallback_auth=True, payment_method=TokenizeCard( cardcvv="123", cardexp="02/25", card_holder="John Doe", cardnumber="4111111111111111", cardzip="12345", method="card", ), ) ``` ```csharp TokenizeCardAnonymous using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.AddMethodAsync( new AddMethodRequest { CreateAnonymous = true, Body = new RequestTokenStorage { EntryPoint = "f743aed24a", FallbackAuth = true, PaymentMethod = new TokenizeCard { Cardcvv = "123", Cardexp = "02/25", CardHolder = "John Doe", Cardnumber = "4111111111111111", Cardzip = "12345", Method = "card" } } } ); } } ``` ```go TokenizeCardAnonymous package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/add?createAnonymous=true" payload := strings.NewReader("{\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Doe\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"method\": \"card\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby TokenizeCardAnonymous require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/add?createAnonymous=true") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Doe\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"method\": \"card\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java TokenizeCardAnonymous import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/TokenStorage/add?createAnonymous=true") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Doe\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"method\": \"card\"\n }\n}") .asString(); ``` ```php TokenizeCardAnonymous request('POST', 'https://api-sandbox.payabli.com/api/TokenStorage/add?createAnonymous=true', [ 'body' => '{ "entryPoint": "f743aed24a", "fallbackAuth": true, "paymentMethod": { "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Doe", "cardnumber": "4111111111111111", "cardzip": "12345", "method": "card" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift TokenizeCardAnonymous import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "f743aed24a", "fallbackAuth": true, "paymentMethod": [ "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Doe", "cardnumber": "4111111111111111", "cardzip": "12345", "method": "card" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/add?createAnonymous=true")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript TemptoPermanent import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.addMethod({ body: { customerData: { customerId: 4440, }, entryPoint: "f743aed24a", fallbackAuth: true, methodDescription: "Main card", paymentMethod: { method: "card", }, }, }); } main(); ``` ```python TemptoPermanent from payabli import payabli, PayorDataRequest from payabli.token_storage import TokenizeCard client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.add_method( customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", fallback_auth=True, method_description="Main card", payment_method=TokenizeCard( method="card", ), ) ``` ```csharp TemptoPermanent using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.AddMethodAsync( new AddMethodRequest { Body = new RequestTokenStorage { CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", FallbackAuth = true, MethodDescription = "Main card", PaymentMethod = new TokenizeCard { Method = "card" } } } ); } } ``` ```go TemptoPermanent package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/add" payload := strings.NewReader("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"methodDescription\": \"Main card\",\n \"paymentMethod\": {\n \"method\": \"card\",\n \"tokenId\": \"c9700e93-b2ed-4b75-b1e4-ca4fb04fbe45-224\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby TemptoPermanent require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/add") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"methodDescription\": \"Main card\",\n \"paymentMethod\": {\n \"method\": \"card\",\n \"tokenId\": \"c9700e93-b2ed-4b75-b1e4-ca4fb04fbe45-224\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java TemptoPermanent import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/TokenStorage/add") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"methodDescription\": \"Main card\",\n \"paymentMethod\": {\n \"method\": \"card\",\n \"tokenId\": \"c9700e93-b2ed-4b75-b1e4-ca4fb04fbe45-224\"\n }\n}") .asString(); ``` ```php TemptoPermanent request('POST', 'https://api-sandbox.payabli.com/api/TokenStorage/add', [ 'body' => '{ "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "fallbackAuth": true, "methodDescription": "Main card", "paymentMethod": { "method": "card", "tokenId": "c9700e93-b2ed-4b75-b1e4-ca4fb04fbe45-224" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift TemptoPermanent import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "fallbackAuth": true, "methodDescription": "Main card", "paymentMethod": [ "method": "card", "tokenId": "c9700e93-b2ed-4b75-b1e4-ca4fb04fbe45-224" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/add")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript TokenizeACH import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.addMethod({ achValidation: true, body: { customerData: { customerId: 4440, }, entryPoint: "f743aed24a", paymentMethod: { method: "ach", }, }, }); } main(); ``` ```python TokenizeACH from payabli import payabli, PayorDataRequest from payabli.token_storage import TokenizeCard client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.add_method( ach_validation=True, customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", payment_method=TokenizeCard( method="ach", ), ) ``` ```csharp TokenizeACH using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.AddMethodAsync( new AddMethodRequest { AchValidation = true, Body = new RequestTokenStorage { CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", PaymentMethod = new TokenizeCard { Method = "ach" } } } ); } } ``` ```go TokenizeACH package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true" payload := strings.NewReader("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby TokenizeACH require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java TokenizeACH import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n }\n}") .asString(); ``` ```php TokenizeACH request('POST', 'https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true', [ 'body' => '{ "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "paymentMethod": { "achAccount": "1111111111111", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Doe", "achHolderType": "personal", "achRouting": "123456780", "method": "ach" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift TokenizeACH import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "paymentMethod": [ "achAccount": "1111111111111", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Doe", "achHolderType": "personal", "achRouting": "123456780", "method": "ach" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript TokenizeVendorACH import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.addMethod({ achValidation: true, body: { entryPoint: "f743aed24a", paymentMethod: { method: "ach", }, vendorData: { vendorId: 7890, }, }, }); } main(); ``` ```python TokenizeVendorACH from payabli import payabli from payabli.token_storage import TokenizeCard, VendorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.add_method( ach_validation=True, entry_point="f743aed24a", payment_method=TokenizeCard( method="ach", ), vendor_data=VendorDataRequest( vendor_id=7890, ), ) ``` ```csharp TokenizeVendorACH using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.AddMethodAsync( new AddMethodRequest { AchValidation = true, Body = new RequestTokenStorage { EntryPoint = "f743aed24a", PaymentMethod = new TokenizeCard { Method = "ach" }, VendorData = new VendorDataRequest { VendorId = 7890L } } } ); } } ``` ```go TokenizeVendorACH package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true" payload := strings.NewReader("{\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n },\n \"vendorData\": {\n \"vendorId\": 7890\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby TokenizeVendorACH require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n },\n \"vendorData\": {\n \"vendorId\": 7890\n }\n}" response = http.request(request) puts response.read_body ``` ```java TokenizeVendorACH import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n },\n \"vendorData\": {\n \"vendorId\": 7890\n }\n}") .asString(); ``` ```php TokenizeVendorACH request('POST', 'https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true', [ 'body' => '{ "entryPoint": "f743aed24a", "paymentMethod": { "achAccount": "1111111111111", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Doe", "achHolderType": "personal", "achRouting": "123456780", "method": "ach" }, "vendorData": { "vendorId": 7890 } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift TokenizeVendorACH import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "f743aed24a", "paymentMethod": [ "achAccount": "1111111111111", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Doe", "achHolderType": "personal", "achRouting": "123456780", "method": "ach" ], "vendorData": ["vendorId": 7890] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/add?achValidation=true")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get tokenized method details GET https://api-sandbox.payabli.com/api/TokenStorage/{methodId} Retrieves details for a saved payment method. Reference: https://docs.payabli.com/developers/api-reference/tokenstorage/get-a-payment-method ## SDK Code Examples ```typescript Example tokenstorage GET with card payment method import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.getMethod("32-8877drt00045632-678", { cardExpirationFormat: 1, includeTemporary: false, }); } main(); ``` ```python Example tokenstorage GET with card payment method from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.get_method( method_id="32-8877drt00045632-678", card_expiration_format=1, include_temporary=False, ) ``` ```csharp Example tokenstorage GET with card payment method using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.GetMethodAsync( "32-8877drt00045632-678", new GetMethodRequest { CardExpirationFormat = 1, IncludeTemporary = false } ); } } ``` ```go Example tokenstorage GET with card payment method package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example tokenstorage GET with card payment method require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example tokenstorage GET with card payment method import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false") .header("requestToken", "") .asString(); ``` ```php Example tokenstorage GET with card payment method request('GET', 'https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example tokenstorage GET with card payment method import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript Example tokenstorage GET with ACH payment method import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.getMethod("32-8877drt00045632-678", { cardExpirationFormat: 1, includeTemporary: false, }); } main(); ``` ```python Example tokenstorage GET with ACH payment method from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.get_method( method_id="32-8877drt00045632-678", card_expiration_format=1, include_temporary=False, ) ``` ```csharp Example tokenstorage GET with ACH payment method using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.GetMethodAsync( "32-8877drt00045632-678", new GetMethodRequest { CardExpirationFormat = 1, IncludeTemporary = false } ); } } ``` ```go Example tokenstorage GET with ACH payment method package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example tokenstorage GET with ACH payment method require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example tokenstorage GET with ACH payment method import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false") .header("requestToken", "") .asString(); ``` ```php Example tokenstorage GET with ACH payment method request('GET', 'https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example tokenstorage GET with ACH payment method import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678?cardExpirationFormat=1&includeTemporary=false")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript Example tokenstorage GET with vendor ACH payment method import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.getMethod("749e236c-59a3-49c7-ab47-73e06f9e94aa-199689", { cardExpirationFormat: 1, includeTemporary: false, }); } main(); ``` ```python Example tokenstorage GET with vendor ACH payment method from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.get_method( method_id="749e236c-59a3-49c7-ab47-73e06f9e94aa-199689", card_expiration_format=1, include_temporary=False, ) ``` ```csharp Example tokenstorage GET with vendor ACH payment method using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.GetMethodAsync( "749e236c-59a3-49c7-ab47-73e06f9e94aa-199689", new GetMethodRequest { CardExpirationFormat = 1, IncludeTemporary = false } ); } } ``` ```go Example tokenstorage GET with vendor ACH payment method package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/749e236c-59a3-49c7-ab47-73e06f9e94aa-199689?cardExpirationFormat=1&includeTemporary=false" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example tokenstorage GET with vendor ACH payment method require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/749e236c-59a3-49c7-ab47-73e06f9e94aa-199689?cardExpirationFormat=1&includeTemporary=false") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example tokenstorage GET with vendor ACH payment method import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/TokenStorage/749e236c-59a3-49c7-ab47-73e06f9e94aa-199689?cardExpirationFormat=1&includeTemporary=false") .header("requestToken", "") .asString(); ``` ```php Example tokenstorage GET with vendor ACH payment method request('GET', 'https://api-sandbox.payabli.com/api/TokenStorage/749e236c-59a3-49c7-ab47-73e06f9e94aa-199689?cardExpirationFormat=1&includeTemporary=false', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example tokenstorage GET with vendor ACH payment method import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/749e236c-59a3-49c7-ab47-73e06f9e94aa-199689?cardExpirationFormat=1&includeTemporary=false")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update tokenized payment method PUT https://api-sandbox.payabli.com/api/TokenStorage/{methodId} Content-Type: application/json Updates a saved payment method. Reference: https://docs.payabli.com/developers/api-reference/tokenstorage/update-a-payment-method ## SDK Code Examples ```typescript UpdateCardMethod import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.updateMethod("32-8877drt00045632-678", { body: { customerData: { customerId: 4440, }, entryPoint: "f743aed24a", fallbackAuth: true, paymentMethod: { cardcvv: "123", cardexp: "02/25", cardHolder: "John Doe", cardnumber: "4111111111111111", cardzip: "12345", method: "card", }, }, }); } main(); ``` ```python UpdateCardMethod from payabli import payabli, PayorDataRequest from payabli.token_storage import TokenizeCard client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.update_method( method_id="32-8877drt00045632-678", customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", fallback_auth=True, payment_method=TokenizeCard( cardcvv="123", cardexp="02/25", card_holder="John Doe", cardnumber="4111111111111111", cardzip="12345", method="card", ), ) ``` ```csharp UpdateCardMethod using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.UpdateMethodAsync( "32-8877drt00045632-678", new UpdateMethodRequest { Body = new RequestTokenStorage { CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", FallbackAuth = true, PaymentMethod = new TokenizeCard { Cardcvv = "123", Cardexp = "02/25", CardHolder = "John Doe", Cardnumber = "4111111111111111", Cardzip = "12345", Method = "card" } } } ); } } ``` ```go UpdateCardMethod package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678" payload := strings.NewReader("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Doe\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"method\": \"card\"\n }\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdateCardMethod require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Doe\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"method\": \"card\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdateCardMethod import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"fallbackAuth\": true,\n \"paymentMethod\": {\n \"cardcvv\": \"123\",\n \"cardexp\": \"02/25\",\n \"cardHolder\": \"John Doe\",\n \"cardnumber\": \"4111111111111111\",\n \"cardzip\": \"12345\",\n \"method\": \"card\"\n }\n}") .asString(); ``` ```php UpdateCardMethod request('PUT', 'https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678', [ 'body' => '{ "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "fallbackAuth": true, "paymentMethod": { "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Doe", "cardnumber": "4111111111111111", "cardzip": "12345", "method": "card" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdateCardMethod import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "fallbackAuth": true, "paymentMethod": [ "cardcvv": "123", "cardexp": "02/25", "cardHolder": "John Doe", "cardnumber": "4111111111111111", "cardzip": "12345", "method": "card" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript UpdateACHMethod import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.updateMethod("32-8877drt00045632-678", { body: { customerData: { customerId: 4440, }, entryPoint: "f743aed24a", paymentMethod: { method: "ach", }, }, }); } main(); ``` ```python UpdateACHMethod from payabli import payabli, PayorDataRequest from payabli.token_storage import TokenizeCard client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.update_method( method_id="32-8877drt00045632-678", customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", payment_method=TokenizeCard( method="ach", ), ) ``` ```csharp UpdateACHMethod using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.UpdateMethodAsync( "32-8877drt00045632-678", new UpdateMethodRequest { Body = new RequestTokenStorage { CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", PaymentMethod = new TokenizeCard { Method = "ach" } } } ); } } ``` ```go UpdateACHMethod package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678" payload := strings.NewReader("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n }\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdateACHMethod require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdateACHMethod import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n }\n}") .asString(); ``` ```php UpdateACHMethod request('PUT', 'https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678', [ 'body' => '{ "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "paymentMethod": { "achAccount": "1111111111111", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Doe", "achHolderType": "personal", "achRouting": "123456780", "method": "ach" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdateACHMethod import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "paymentMethod": [ "achAccount": "1111111111111", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Doe", "achHolderType": "personal", "achRouting": "123456780", "method": "ach" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript UpdateACHMethodVendor import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.updateMethod("32-8877drt00045632-678", { body: { customerData: { customerId: 4440, }, entryPoint: "f743aed24a", paymentMethod: { method: "ach", }, vendorData: { vendorId: 7890, }, }, }); } main(); ``` ```python UpdateACHMethodVendor from payabli import payabli, PayorDataRequest from payabli.token_storage import TokenizeCard, VendorDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.update_method( method_id="32-8877drt00045632-678", customer_data=PayorDataRequest( customer_id=4440, ), entry_point="f743aed24a", payment_method=TokenizeCard( method="ach", ), vendor_data=VendorDataRequest( vendor_id=7890, ), ) ``` ```csharp UpdateACHMethodVendor using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.UpdateMethodAsync( "32-8877drt00045632-678", new UpdateMethodRequest { Body = new RequestTokenStorage { CustomerData = new PayorDataRequest { CustomerId = 4440L }, EntryPoint = "f743aed24a", PaymentMethod = new TokenizeCard { Method = "ach" }, VendorData = new VendorDataRequest { VendorId = 7890L } } } ); } } ``` ```go UpdateACHMethodVendor package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678" payload := strings.NewReader("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n },\n \"vendorData\": {\n \"vendorId\": 7890\n }\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdateACHMethodVendor require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n },\n \"vendorData\": {\n \"vendorId\": 7890\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdateACHMethodVendor import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerId\": 4440\n },\n \"entryPoint\": \"f743aed24a\",\n \"paymentMethod\": {\n \"achAccount\": \"1111111111111\",\n \"achAccountType\": \"Checking\",\n \"achCode\": \"WEB\",\n \"achHolder\": \"John Doe\",\n \"achHolderType\": \"personal\",\n \"achRouting\": \"123456780\",\n \"method\": \"ach\"\n },\n \"vendorData\": {\n \"vendorId\": 7890\n }\n}") .asString(); ``` ```php UpdateACHMethodVendor request('PUT', 'https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678', [ 'body' => '{ "customerData": { "customerId": 4440 }, "entryPoint": "f743aed24a", "paymentMethod": { "achAccount": "1111111111111", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Doe", "achHolderType": "personal", "achRouting": "123456780", "method": "ach" }, "vendorData": { "vendorId": 7890 } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdateACHMethodVendor import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": ["customerId": 4440], "entryPoint": "f743aed24a", "paymentMethod": [ "achAccount": "1111111111111", "achAccountType": "Checking", "achCode": "WEB", "achHolder": "John Doe", "achHolderType": "personal", "achRouting": "123456780", "method": "ach" ], "vendorData": ["vendorId": 7890] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete tokenized payment method DELETE https://api-sandbox.payabli.com/api/TokenStorage/{methodId} Deletes a saved payment method. Reference: https://docs.payabli.com/developers/api-reference/tokenstorage/remove-a-payment-method ## SDK Code Examples ```typescript Example1 import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.tokenStorage.removeMethod("32-8877drt00045632-678"); } main(); ``` ```python Example1 from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.token_storage.remove_method( method_id="32-8877drt00045632-678", ) ``` ```csharp Example1 using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.TokenStorage.RemoveMethodAsync( "32-8877drt00045632-678" ); } } ``` ```go Example1 package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example1 require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example1 import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678") .header("requestToken", "") .asString(); ``` ```php Example1 request('DELETE', 'https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example1 import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/TokenStorage/32-8877drt00045632-678")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create customer POST https://api-sandbox.payabli.com/api/Customer/single/{entry} Content-Type: application/json Creates a customer in an entrypoint. An identifier is required to create customer records. Change your identifier settings in Settings > Custom Fields in PartnerHub. If you don't include an identifier, the record is rejected. Reference: https://docs.payabli.com/developers/api-reference/customer/add-customer ## SDK Code Examples ```typescript CreateCustomer import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.customer.addCustomer("8cfec329267", { body: { customerNumber: "12356ACB", firstname: "Irene", lastname: "Canizales", email: "irene@canizalesconcrete.com", address1: "123 Bishop's Trail", city: "Mountain City", state: "TN", zip: "37612", country: "US", timeZone: -5, identifierFields: [ "email", ], }, }); } main(); ``` ```python CreateCustomer from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.customer.add_customer( entry="8cfec329267", customer_number="12356ACB", firstname="Irene", lastname="Canizales", email="irene@canizalesconcrete.com", address_1="123 Bishop\'s Trail", city="Mountain City", state="TN", zip="37612", country="US", time_zone=-5, identifier_fields=[ "email" ], ) ``` ```csharp CreateCustomer using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Customer.AddCustomerAsync( "8cfec329267", new AddCustomerRequest { Body = new CustomerData { CustomerNumber = "12356ACB", Firstname = "Irene", Lastname = "Canizales", Email = "irene@canizalesconcrete.com", Address1 = "123 Bishop's Trail", City = "Mountain City", State = "TN", Zip = "37612", Country = "US", TimeZone = -5, IdentifierFields = new List(){ "email", } } } ); } } ``` ```go CreateCustomer package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Customer/single/8cfec329267" payload := strings.NewReader("{\n \"customerNumber\": \"12356ACB\",\n \"firstname\": \"Irene\",\n \"lastname\": \"Canizales\",\n \"email\": \"irene@canizalesconcrete.com\",\n \"address1\": \"123 Bishop's Trail\",\n \"city\": \"Mountain City\",\n \"state\": \"TN\",\n \"zip\": \"37612\",\n \"country\": \"US\",\n \"timeZone\": -5,\n \"identifierFields\": [\n \"email\"\n ]\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CreateCustomer require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Customer/single/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerNumber\": \"12356ACB\",\n \"firstname\": \"Irene\",\n \"lastname\": \"Canizales\",\n \"email\": \"irene@canizalesconcrete.com\",\n \"address1\": \"123 Bishop's Trail\",\n \"city\": \"Mountain City\",\n \"state\": \"TN\",\n \"zip\": \"37612\",\n \"country\": \"US\",\n \"timeZone\": -5,\n \"identifierFields\": [\n \"email\"\n ]\n}" response = http.request(request) puts response.read_body ``` ```java CreateCustomer import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Customer/single/8cfec329267") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerNumber\": \"12356ACB\",\n \"firstname\": \"Irene\",\n \"lastname\": \"Canizales\",\n \"email\": \"irene@canizalesconcrete.com\",\n \"address1\": \"123 Bishop's Trail\",\n \"city\": \"Mountain City\",\n \"state\": \"TN\",\n \"zip\": \"37612\",\n \"country\": \"US\",\n \"timeZone\": -5,\n \"identifierFields\": [\n \"email\"\n ]\n}") .asString(); ``` ```php CreateCustomer request('POST', 'https://api-sandbox.payabli.com/api/Customer/single/8cfec329267', [ 'body' => '{ "customerNumber": "12356ACB", "firstname": "Irene", "lastname": "Canizales", "email": "irene@canizalesconcrete.com", "address1": "123 Bishop\'s Trail", "city": "Mountain City", "state": "TN", "zip": "37612", "country": "US", "timeZone": -5, "identifierFields": [ "email" ] }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CreateCustomer import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerNumber": "12356ACB", "firstname": "Irene", "lastname": "Canizales", "email": "irene@canizalesconcrete.com", "address1": "123 Bishop's Trail", "city": "Mountain City", "state": "TN", "zip": "37612", "country": "US", "timeZone": -5, "identifierFields": ["email"] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Customer/single/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get customer GET https://api-sandbox.payabli.com/api/Customer/{customerId} Retrieves a customer's record and details. Reference: https://docs.payabli.com/developers/api-reference/customer/get-customer-record ## SDK Code Examples ```typescript GetCustomer import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.customer.getCustomer(998); } main(); ``` ```python GetCustomer from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.customer.get_customer( customer_id=998, ) ``` ```csharp GetCustomer using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Customer.GetCustomerAsync( 998 ); } } ``` ```go GetCustomer package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Customer/998" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetCustomer require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Customer/998") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetCustomer import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Customer/998") .header("requestToken", "") .asString(); ``` ```php GetCustomer request('GET', 'https://api-sandbox.payabli.com/api/Customer/998', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetCustomer import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Customer/998")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update customer PUT https://api-sandbox.payabli.com/api/Customer/{customerId} Content-Type: application/json Update a customer record. Include only the fields you want to change. Reference: https://docs.payabli.com/developers/api-reference/customer/update-customer-record ## SDK Code Examples ```typescript UpdateCustomer import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.customer.updateCustomer(998, { firstname: "Irene", lastname: "Canizales", address1: "145 Bishop's Trail", city: "Mountain City", state: "TN", zip: "37612", country: "US", }); } main(); ``` ```python UpdateCustomer from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.customer.update_customer( customer_id=998, firstname="Irene", lastname="Canizales", address_1="145 Bishop\'s Trail", city="Mountain City", state="TN", zip="37612", country="US", ) ``` ```csharp UpdateCustomer using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Customer.UpdateCustomerAsync( 998, new CustomerData { Firstname = "Irene", Lastname = "Canizales", Address1 = "145 Bishop's Trail", City = "Mountain City", State = "TN", Zip = "37612", Country = "US" } ); } } ``` ```go UpdateCustomer package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Customer/998" payload := strings.NewReader("{\n \"firstname\": \"Irene\",\n \"lastname\": \"Canizales\",\n \"address1\": \"145 Bishop's Trail\",\n \"city\": \"Mountain City\",\n \"state\": \"TN\",\n \"zip\": \"37612\",\n \"country\": \"US\"\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdateCustomer require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Customer/998") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"firstname\": \"Irene\",\n \"lastname\": \"Canizales\",\n \"address1\": \"145 Bishop's Trail\",\n \"city\": \"Mountain City\",\n \"state\": \"TN\",\n \"zip\": \"37612\",\n \"country\": \"US\"\n}" response = http.request(request) puts response.read_body ``` ```java UpdateCustomer import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Customer/998") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"firstname\": \"Irene\",\n \"lastname\": \"Canizales\",\n \"address1\": \"145 Bishop's Trail\",\n \"city\": \"Mountain City\",\n \"state\": \"TN\",\n \"zip\": \"37612\",\n \"country\": \"US\"\n}") .asString(); ``` ```php UpdateCustomer request('PUT', 'https://api-sandbox.payabli.com/api/Customer/998', [ 'body' => '{ "firstname": "Irene", "lastname": "Canizales", "address1": "145 Bishop\'s Trail", "city": "Mountain City", "state": "TN", "zip": "37612", "country": "US" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdateCustomer import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "firstname": "Irene", "lastname": "Canizales", "address1": "145 Bishop's Trail", "city": "Mountain City", "state": "TN", "zip": "37612", "country": "US" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Customer/998")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete customer DELETE https://api-sandbox.payabli.com/api/Customer/{customerId} Delete a customer record. Reference: https://docs.payabli.com/developers/api-reference/customer/delete-customer-record ## SDK Code Examples ```typescript DeleteCustomer import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.customer.deleteCustomer(998); } main(); ``` ```python DeleteCustomer from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.customer.delete_customer( customer_id=998, ) ``` ```csharp DeleteCustomer using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Customer.DeleteCustomerAsync( 998 ); } } ``` ```go DeleteCustomer package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Customer/998" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby DeleteCustomer require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Customer/998") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java DeleteCustomer import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Customer/998") .header("requestToken", "") .asString(); ``` ```php DeleteCustomer request('DELETE', 'https://api-sandbox.payabli.com/api/Customer/998', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift DeleteCustomer import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Customer/998")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Link transaction to customer GET https://api-sandbox.payabli.com/api/Customer/link/{customerId}/{transId} Links a customer to a transaction by ID. Reference: https://docs.payabli.com/developers/api-reference/customer/link-customer-to-transaction ## SDK Code Examples ```typescript LinkCustomerTransaction import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.customer.linkCustomerTransaction(998, "45-as456777hhhhhhhhhh77777777-324"); } main(); ``` ```python LinkCustomerTransaction from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.customer.link_customer_transaction( customer_id=998, trans_id="45-as456777hhhhhhhhhh77777777-324", ) ``` ```csharp LinkCustomerTransaction using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Customer.LinkCustomerTransactionAsync( 998, "45-as456777hhhhhhhhhh77777777-324" ); } } ``` ```go LinkCustomerTransaction package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Customer/link/998/45-as456777hhhhhhhhhh77777777-324" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby LinkCustomerTransaction require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Customer/link/998/45-as456777hhhhhhhhhh77777777-324") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java LinkCustomerTransaction import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Customer/link/998/45-as456777hhhhhhhhhh77777777-324") .header("requestToken", "") .asString(); ``` ```php LinkCustomerTransaction request('GET', 'https://api-sandbox.payabli.com/api/Customer/link/998/45-as456777hhhhhhhhhh77777777-324', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift LinkCustomerTransaction import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Customer/link/998/45-as456777hhhhhhhhhh77777777-324")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Send opt-in POST https://api-sandbox.payabli.com/api/Customer/{customerId}/consent Sends the consent opt-in email to the customer email address in the customer record. Reference: https://docs.payabli.com/developers/api-reference/customer/customer-consent ## SDK Code Examples ```typescript Success example import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.customer.requestConsent(998); } main(); ``` ```python Success example from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.customer.request_consent( customer_id=998, ) ``` ```csharp Success example using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Customer.RequestConsentAsync( 998 ); } } ``` ```go Success example package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Customer/998/consent" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Success example require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Customer/998/consent") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Success example import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Customer/998/consent") .header("requestToken", "") .asString(); ``` ```php Success example request('POST', 'https://api-sandbox.payabli.com/api/Customer/998/consent', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Success example import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Customer/998/consent")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Import customers POST https://api-sandbox.payabli.com/api/Import/customersForm/{entry} Content-Type: multipart/form-data Import a list of customers from a CSV file. See the [Import Guide](/developers/developer-guides/entities-customers#import-customers) for more help and example files. Reference: https://docs.payabli.com/developers/api-reference/customer/import-list-of-customers ## SDK Code Examples ```typescript ImportCustomer import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.import.importCustomer("8cfec329267", , {}); } main(); ``` ```python ImportCustomer from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.import_.import_customer( entry="8cfec329267", file="example_file", ) ``` ```csharp ImportCustomer using PayabliPayabliApi; using System.Threading.Tasks; using System.IO; using System.Text; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Import.ImportCustomerAsync( "8cfec329267", new ImportCustomerRequest { File = new FileParameter(){ Stream = new MemoryStream(Encoding.UTF8.GetBytes("[bytes]")) } } ); } } ``` ```go ImportCustomer package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Import/customersForm/8cfec329267" payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"\"\r\nContent-Type: application/octet-stream\r\n\r\n\r\n-----011000010111000001101001--\r\n") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "multipart/form-data; boundary=---011000010111000001101001") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ImportCustomer require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Import/customersForm/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'multipart/form-data; boundary=---011000010111000001101001' request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"\"\r\nContent-Type: application/octet-stream\r\n\r\n\r\n-----011000010111000001101001--\r\n" response = http.request(request) puts response.read_body ``` ```java ImportCustomer import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Import/customersForm/8cfec329267") .header("requestToken", "") .header("Content-Type", "multipart/form-data; boundary=---011000010111000001101001") .body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"\"\r\nContent-Type: application/octet-stream\r\n\r\n\r\n-----011000010111000001101001--\r\n") .asString(); ``` ```php ImportCustomer request('POST', 'https://api-sandbox.payabli.com/api/Import/customersForm/8cfec329267', [ 'multipart' => [ [ 'name' => 'file', 'filename' => '', 'contents' => null ] ] 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ImportCustomer import Foundation let headers = [ "requestToken": "", "Content-Type": "multipart/form-data; boundary=---011000010111000001101001" ] let parameters = [ [ "name": "file", "fileName": "" ] ] let boundary = "---011000010111000001101001" var body = "" var error: NSError? = nil for param in parameters { let paramName = param["name"]! body += "--\(boundary)\r\n" body += "Content-Disposition:form-data; name=\"\(paramName)\"" if let filename = param["fileName"] { let contentType = param["content-type"]! let fileContent = String(contentsOfFile: filename, encoding: String.Encoding.utf8) if (error != nil) { print(error as Any) } body += "; filename=\"\(filename)\"\r\n" body += "Content-Type: \(contentType)\r\n\r\n" body += fileContent } else if let paramValue = param["value"] { body += "\r\n\r\n\(paramValue)" } } let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Import/customersForm/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List customers by paypoint GET https://api-sandbox.payabli.com/api/Query/customers/{entry} Retrieves a list of customers for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/customer/get-list-of-customers-for-an-entrypoint ## SDK Code Examples ```typescript example1 import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listCustomers("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python example1 from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_customers( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp example1 using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListCustomersAsync( "8cfec329267", new ListCustomersRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go example1 package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/customers/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby example1 require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/customers/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java example1 import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/customers/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php example1 request('GET', 'https://api-sandbox.payabli.com/api/Query/customers/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift example1 import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/customers/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List customers by organization GET https://api-sandbox.payabli.com/api/Query/customers/org/{orgId} Retrieves a list of customers for an org. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/customer/get-list-of-customers-for-an-organization ## SDK Code Examples ```typescript example1 import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listCustomersOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python example1 from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_customers_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp example1 using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListCustomersOrgAsync( 123, new ListCustomersOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go example1 package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/customers/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby example1 require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/customers/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java example1 import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/customers/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php example1 request('GET', 'https://api-sandbox.payabli.com/api/Query/customers/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift example1 import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/customers/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export customers for paypoint GET https://api-sandbox.payabli.com/api/Export/customers/{format}/{entry} Export a list of customers for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/customer/export-list-of-customers-for-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportCustomers("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_customers( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportCustomersAsync( ExportFormat1.Csv, "8cfec329267", new ExportCustomersRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/customers/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/customers/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/customers/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/customers/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/customers/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export customers by org GET https://api-sandbox.payabli.com/api/Export/customers/{format}/org/{orgId} Exports a list of customers for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/customer/export-list-of-customers-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportCustomersOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_customers_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportCustomersOrgAsync( ExportFormat1.Csv, 123, new ExportCustomersOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/customers/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/customers/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/customers/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/customers/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/customers/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get customer stats GET https://api-sandbox.payabli.com/api/Statistic/customerbasic/{mode}/{freq}/{customerId} Retrieves the basic statistics for a customer for a specific time period, grouped by a selected frequency. Reference: https://docs.payabli.com/developers/api-reference/customer/get-basic-statistics-for-a-customer ## SDK Code Examples ```typescript CustomerBasicStatsExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.statistic.customerBasicStats(998, "m", "ytd", {}); } main(); ``` ```python CustomerBasicStatsExample from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.statistic.customer_basic_stats( customer_id=998, freq="m", mode="ytd", ) ``` ```csharp CustomerBasicStatsExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Statistic.CustomerBasicStatsAsync( "ytd", "m", 998, new CustomerBasicStatsRequest() ); } } ``` ```go CustomerBasicStatsExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Statistic/customerbasic/ytd/m/998" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CustomerBasicStatsExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Statistic/customerbasic/ytd/m/998") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java CustomerBasicStatsExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Statistic/customerbasic/ytd/m/998") .header("requestToken", "") .asString(); ``` ```php CustomerBasicStatsExample request('GET', 'https://api-sandbox.payabli.com/api/Statistic/customerbasic/ytd/m/998', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CustomerBasicStatsExample import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Statistic/customerbasic/ytd/m/998")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Register device POST https://api-sandbox.payabli.com/api/Cloud/register/{entry} Content-Type: application/json Register a cloud device to an entrypoint. See [Devices Quickstart](/developers/developer-guides/devices-quickstart#devices-quickstart) for a complete guide. Reference: https://docs.payabli.com/developers/api-reference/cloud/register-cloud-device ## SDK Code Examples ```typescript Register import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.cloud.addDevice("8cfec329267", { description: "Front Desk POS", registrationCode: "YS7DS5", }); } main(); ``` ```python Register from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.cloud.add_device( entry="8cfec329267", description="Front Desk POS", registration_code="YS7DS5", ) ``` ```csharp Register using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Cloud.AddDeviceAsync( "8cfec329267", new DeviceEntry { Description = "Front Desk POS", RegistrationCode = "YS7DS5" } ); } } ``` ```go Register package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267" payload := strings.NewReader("{\n \"description\": \"Front Desk POS\",\n \"registrationCode\": \"YS7DS5\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Register require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"description\": \"Front Desk POS\",\n \"registrationCode\": \"YS7DS5\"\n}" response = http.request(request) puts response.read_body ``` ```java Register import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"description\": \"Front Desk POS\",\n \"registrationCode\": \"YS7DS5\"\n}") .asString(); ``` ```php Register request('POST', 'https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267', [ 'body' => '{ "description": "Front Desk POS", "registrationCode": "YS7DS5" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Register import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "description": "Front Desk POS", "registrationCode": "YS7DS5" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List devices GET https://api-sandbox.payabli.com/api/Cloud/list/{entry} Get a list of cloud devices registered to an entrypoint. Reference: https://docs.payabli.com/developers/api-reference/cloud/list-registered-devices-in-cloud ## SDK Code Examples ```typescript ListDevices import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.cloud.listDevice("8cfec329267", {}); } main(); ``` ```python ListDevices from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.cloud.list_device( entry="8cfec329267", ) ``` ```csharp ListDevices using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Cloud.ListDeviceAsync( "8cfec329267", new ListDeviceRequest() ); } } ``` ```go ListDevices package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Cloud/list/8cfec329267" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListDevices require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Cloud/list/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java ListDevices import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Cloud/list/8cfec329267") .header("requestToken", "") .asString(); ``` ```php ListDevices request('GET', 'https://api-sandbox.payabli.com/api/Cloud/list/8cfec329267', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ListDevices import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Cloud/list/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get device history GET https://api-sandbox.payabli.com/api/Cloud/history/{entry}/{deviceId} Retrieve the registration history for a device. Reference: https://docs.payabli.com/developers/api-reference/cloud/get-registration-history-for-device ## SDK Code Examples ```typescript Example response for GET requests for devices. import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.cloud.historyDevice("WXGDWB", "8cfec329267"); } main(); ``` ```python Example response for GET requests for devices. from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.cloud.history_device( device_id="WXGDWB", entry="8cfec329267", ) ``` ```csharp Example response for GET requests for devices. using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Cloud.HistoryDeviceAsync( "8cfec329267", "WXGDWB" ); } } ``` ```go Example response for GET requests for devices. package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Cloud/history/8cfec329267/WXGDWB" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example response for GET requests for devices. require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Cloud/history/8cfec329267/WXGDWB") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example response for GET requests for devices. import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Cloud/history/8cfec329267/WXGDWB") .header("requestToken", "") .asString(); ``` ```php Example response for GET requests for devices. request('GET', 'https://api-sandbox.payabli.com/api/Cloud/history/8cfec329267/WXGDWB', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example response for GET requests for devices. import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Cloud/history/8cfec329267/WXGDWB")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Unregister device DELETE https://api-sandbox.payabli.com/api/Cloud/register/{entry}/{deviceId} Remove a cloud device from an entrypoint. Reference: https://docs.payabli.com/developers/api-reference/cloud/unregister-cloud-device ## SDK Code Examples ```typescript Unregister import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.cloud.removeDevice("6c361c7d-674c-44cc-b790-382b75d1xxx", "8cfec329267"); } main(); ``` ```python Unregister from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.cloud.remove_device( device_id="6c361c7d-674c-44cc-b790-382b75d1xxx", entry="8cfec329267", ) ``` ```csharp Unregister using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Cloud.RemoveDeviceAsync( "8cfec329267", "6c361c7d-674c-44cc-b790-382b75d1xxx" ); } } ``` ```go Unregister package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267/6c361c7d-674c-44cc-b790-382b75d1xxx" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Unregister require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267/6c361c7d-674c-44cc-b790-382b75d1xxx") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Unregister import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267/6c361c7d-674c-44cc-b790-382b75d1xxx") .header("requestToken", "") .asString(); ``` ```php Unregister request('DELETE', 'https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267/6c361c7d-674c-44cc-b790-382b75d1xxx', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Unregister import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Cloud/register/8cfec329267/6c361c7d-674c-44cc-b790-382b75d1xxx")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create invoice POST https://api-sandbox.payabli.com/api/Invoice/{entry} Content-Type: application/json Creates an invoice in an entrypoint. Reference: https://docs.payabli.com/developers/api-reference/invoice/add-invoice ## SDK Code Examples ```typescript AddInvoice import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.addInvoice("8cfec329267", { body: { customerData: { customerNumber: "3", firstName: "Tamara", lastName: "Bagratoni", }, invoiceData: { discount: 10, frequency: "onetime", invoiceAmount: 982.37, invoiceDate: "2025-10-19", invoiceNumber: "INV-3", invoiceStatus: 1, invoiceType: 0, items: [ { itemCost: 100, itemDescription: "Consultation for Georgian tours", itemMode: 1, itemProductName: "Adventure Consult", itemQty: 1, itemTotalAmount: 1, }, { itemCost: 882.37, itemDescription: "Deposit for trip planning", itemProductName: "Deposit ", itemQty: 1, itemTotalAmount: 1, }, ], }, }, }); } main(); ``` ```python AddInvoice from payabli import payabli, PayorDataRequest, BillData, BillItem import datetime client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.add_invoice( entry="8cfec329267", customer_data=PayorDataRequest( customer_number="3", first_name="Tamara", last_name="Bagratoni", ), invoice_data=BillData( discount=10, frequency="onetime", invoice_amount=982.37, invoice_date=datetime.date.fromisoformat("2025-10-19"), invoice_number="INV-3", invoice_status=1, invoice_type=0, items=[ BillItem( item_cost=100, item_description="Consultation for Georgian tours", item_mode=1, item_product_name="Adventure Consult", item_qty=1, item_total_amount=1, ), BillItem( item_cost=882.37, item_description="Deposit for trip planning", item_product_name="Deposit ", item_qty=1, item_total_amount=1, ) ], ), ) ``` ```csharp AddInvoice using PayabliPayabliApi; using System.Threading.Tasks; using System; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.AddInvoiceAsync( "8cfec329267", new AddInvoiceRequest { Body = new InvoiceDataRequest { CustomerData = new PayorDataRequest { CustomerNumber = "3", FirstName = "Tamara", LastName = "Bagratoni" }, InvoiceData = new BillData { Discount = 10, Frequency = Frequency.OneTime, InvoiceAmount = 982.37, InvoiceDate = DateOnly.Parse("2025-10-19"), InvoiceNumber = "INV-3", InvoiceStatus = 1, InvoiceType = 0, Items = new List(){ new BillItem { ItemCost = 100, ItemDescription = "Consultation for Georgian tours", ItemMode = 1, ItemProductName = "Adventure Consult", ItemQty = 1, ItemTotalAmount = 1 }, new BillItem { ItemCost = 882.37, ItemDescription = "Deposit for trip planning", ItemProductName = "Deposit ", ItemQty = 1, ItemTotalAmount = 1 }, } } } } ); } } ``` ```go AddInvoice package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Invoice/8cfec329267" payload := strings.NewReader("{\n \"customerData\": {\n \"customerNumber\": \"3\",\n \"firstName\": \"Tamara\",\n \"lastName\": \"Bagratoni\"\n },\n \"invoiceData\": {\n \"discount\": 10,\n \"frequency\": \"onetime\",\n \"invoiceAmount\": 982.37,\n \"invoiceDate\": \"2025-10-19\",\n \"invoiceNumber\": \"INV-3\",\n \"invoiceStatus\": 1,\n \"invoiceType\": 0,\n \"items\": [\n {\n \"itemCost\": 100,\n \"itemDescription\": \"Consultation for Georgian tours\",\n \"itemMode\": 1,\n \"itemProductName\": \"Adventure Consult\",\n \"itemQty\": 1,\n \"itemTotalAmount\": 1\n },\n {\n \"itemCost\": 882.37,\n \"itemDescription\": \"Deposit for trip planning\",\n \"itemProductName\": \"Deposit \",\n \"itemQty\": 1,\n \"itemTotalAmount\": 1\n }\n ]\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby AddInvoice require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Invoice/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"customerData\": {\n \"customerNumber\": \"3\",\n \"firstName\": \"Tamara\",\n \"lastName\": \"Bagratoni\"\n },\n \"invoiceData\": {\n \"discount\": 10,\n \"frequency\": \"onetime\",\n \"invoiceAmount\": 982.37,\n \"invoiceDate\": \"2025-10-19\",\n \"invoiceNumber\": \"INV-3\",\n \"invoiceStatus\": 1,\n \"invoiceType\": 0,\n \"items\": [\n {\n \"itemCost\": 100,\n \"itemDescription\": \"Consultation for Georgian tours\",\n \"itemMode\": 1,\n \"itemProductName\": \"Adventure Consult\",\n \"itemQty\": 1,\n \"itemTotalAmount\": 1\n },\n {\n \"itemCost\": 882.37,\n \"itemDescription\": \"Deposit for trip planning\",\n \"itemProductName\": \"Deposit \",\n \"itemQty\": 1,\n \"itemTotalAmount\": 1\n }\n ]\n }\n}" response = http.request(request) puts response.read_body ``` ```java AddInvoice import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Invoice/8cfec329267") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"customerData\": {\n \"customerNumber\": \"3\",\n \"firstName\": \"Tamara\",\n \"lastName\": \"Bagratoni\"\n },\n \"invoiceData\": {\n \"discount\": 10,\n \"frequency\": \"onetime\",\n \"invoiceAmount\": 982.37,\n \"invoiceDate\": \"2025-10-19\",\n \"invoiceNumber\": \"INV-3\",\n \"invoiceStatus\": 1,\n \"invoiceType\": 0,\n \"items\": [\n {\n \"itemCost\": 100,\n \"itemDescription\": \"Consultation for Georgian tours\",\n \"itemMode\": 1,\n \"itemProductName\": \"Adventure Consult\",\n \"itemQty\": 1,\n \"itemTotalAmount\": 1\n },\n {\n \"itemCost\": 882.37,\n \"itemDescription\": \"Deposit for trip planning\",\n \"itemProductName\": \"Deposit \",\n \"itemQty\": 1,\n \"itemTotalAmount\": 1\n }\n ]\n }\n}") .asString(); ``` ```php AddInvoice request('POST', 'https://api-sandbox.payabli.com/api/Invoice/8cfec329267', [ 'body' => '{ "customerData": { "customerNumber": "3", "firstName": "Tamara", "lastName": "Bagratoni" }, "invoiceData": { "discount": 10, "frequency": "onetime", "invoiceAmount": 982.37, "invoiceDate": "2025-10-19", "invoiceNumber": "INV-3", "invoiceStatus": 1, "invoiceType": 0, "items": [ { "itemCost": 100, "itemDescription": "Consultation for Georgian tours", "itemMode": 1, "itemProductName": "Adventure Consult", "itemQty": 1, "itemTotalAmount": 1 }, { "itemCost": 882.37, "itemDescription": "Deposit for trip planning", "itemProductName": "Deposit ", "itemQty": 1, "itemTotalAmount": 1 } ] } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift AddInvoice import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "customerData": [ "customerNumber": "3", "firstName": "Tamara", "lastName": "Bagratoni" ], "invoiceData": [ "discount": 10, "frequency": "onetime", "invoiceAmount": 982.37, "invoiceDate": "2025-10-19", "invoiceNumber": "INV-3", "invoiceStatus": 1, "invoiceType": 0, "items": [ [ "itemCost": 100, "itemDescription": "Consultation for Georgian tours", "itemMode": 1, "itemProductName": "Adventure Consult", "itemQty": 1, "itemTotalAmount": 1 ], [ "itemCost": 882.37, "itemDescription": "Deposit for trip planning", "itemProductName": "Deposit ", "itemQty": 1, "itemTotalAmount": 1 ] ] ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Invoice/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get invoice GET https://api-sandbox.payabli.com/api/Invoice/{idInvoice} Retrieves a single invoice by ID. Reference: https://docs.payabli.com/developers/api-reference/invoice/get-invoice ## SDK Code Examples ```typescript GetDetails import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.getInvoice(23548884); } main(); ``` ```python GetDetails from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.get_invoice( id_invoice=23548884, ) ``` ```csharp GetDetails using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.GetInvoiceAsync( 23548884 ); } } ``` ```go GetDetails package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Invoice/23548884" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetDetails require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Invoice/23548884") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetDetails import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Invoice/23548884") .header("requestToken", "") .asString(); ``` ```php GetDetails request('GET', 'https://api-sandbox.payabli.com/api/Invoice/23548884', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetDetails import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Invoice/23548884")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update invoice PUT https://api-sandbox.payabli.com/api/Invoice/{idInvoice} Content-Type: application/json Updates details for a single invoice in an entrypoint. Reference: https://docs.payabli.com/developers/api-reference/invoice/update-invoice ## SDK Code Examples ```typescript UpdateInvoice import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.editInvoice(332, { body: { invoiceData: { invoiceAmount: 982.37, invoiceDate: "2025-10-19", invoiceNumber: "INV-6", items: [ { itemCost: 882.37, itemDescription: "Deposit for trip planning", itemProductName: "Deposit", itemQty: 1, }, ], }, }, }); } main(); ``` ```python UpdateInvoice from payabli import payabli, BillData, BillItem import datetime client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.edit_invoice( id_invoice=332, invoice_data=BillData( invoice_amount=982.37, invoice_date=datetime.date.fromisoformat("2025-10-19"), invoice_number="INV-6", items=[ BillItem( item_cost=882.37, item_description="Deposit for trip planning", item_product_name="Deposit", item_qty=1, ) ], ), ) ``` ```csharp UpdateInvoice using PayabliPayabliApi; using System.Threading.Tasks; using System; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.EditInvoiceAsync( 332, new EditInvoiceRequest { Body = new InvoiceDataRequest { InvoiceData = new BillData { InvoiceAmount = 982.37, InvoiceDate = DateOnly.Parse("2025-10-19"), InvoiceNumber = "INV-6", Items = new List(){ new BillItem { ItemCost = 882.37, ItemDescription = "Deposit for trip planning", ItemProductName = "Deposit", ItemQty = 1 }, } } } } ); } } ``` ```go UpdateInvoice package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Invoice/332" payload := strings.NewReader("{\n \"invoiceData\": {\n \"invoiceAmount\": 982.37,\n \"invoiceDate\": \"2025-10-19\",\n \"invoiceNumber\": \"INV-6\",\n \"items\": [\n {\n \"itemCost\": 882.37,\n \"itemDescription\": \"Deposit for trip planning\",\n \"itemProductName\": \"Deposit\",\n \"itemQty\": 1\n }\n ]\n }\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdateInvoice require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Invoice/332") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"invoiceData\": {\n \"invoiceAmount\": 982.37,\n \"invoiceDate\": \"2025-10-19\",\n \"invoiceNumber\": \"INV-6\",\n \"items\": [\n {\n \"itemCost\": 882.37,\n \"itemDescription\": \"Deposit for trip planning\",\n \"itemProductName\": \"Deposit\",\n \"itemQty\": 1\n }\n ]\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdateInvoice import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Invoice/332") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"invoiceData\": {\n \"invoiceAmount\": 982.37,\n \"invoiceDate\": \"2025-10-19\",\n \"invoiceNumber\": \"INV-6\",\n \"items\": [\n {\n \"itemCost\": 882.37,\n \"itemDescription\": \"Deposit for trip planning\",\n \"itemProductName\": \"Deposit\",\n \"itemQty\": 1\n }\n ]\n }\n}") .asString(); ``` ```php UpdateInvoice request('PUT', 'https://api-sandbox.payabli.com/api/Invoice/332', [ 'body' => '{ "invoiceData": { "invoiceAmount": 982.37, "invoiceDate": "2025-10-19", "invoiceNumber": "INV-6", "items": [ { "itemCost": 882.37, "itemDescription": "Deposit for trip planning", "itemProductName": "Deposit", "itemQty": 1 } ] } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdateInvoice import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["invoiceData": [ "invoiceAmount": 982.37, "invoiceDate": "2025-10-19", "invoiceNumber": "INV-6", "items": [ [ "itemCost": 882.37, "itemDescription": "Deposit for trip planning", "itemProductName": "Deposit", "itemQty": 1 ] ] ]] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Invoice/332")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete invoice DELETE https://api-sandbox.payabli.com/api/Invoice/{idInvoice} Deletes a single invoice from an entrypoint. Reference: https://docs.payabli.com/developers/api-reference/invoice/delete-invoice ## SDK Code Examples ```typescript DeleteInvoice import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.deleteInvoice(23548884); } main(); ``` ```python DeleteInvoice from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.delete_invoice( id_invoice=23548884, ) ``` ```csharp DeleteInvoice using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.DeleteInvoiceAsync( 23548884 ); } } ``` ```go DeleteInvoice package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Invoice/23548884" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby DeleteInvoice require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Invoice/23548884") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java DeleteInvoice import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Invoice/23548884") .header("requestToken", "") .asString(); ``` ```php DeleteInvoice request('DELETE', 'https://api-sandbox.payabli.com/api/Invoice/23548884', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift DeleteInvoice import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Invoice/23548884")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Send invoice GET https://api-sandbox.payabli.com/api/Invoice/send/{idInvoice} Sends an invoice from an entrypoint via email. Reference: https://docs.payabli.com/developers/api-reference/invoice/send-invoice-via-email ## SDK Code Examples ```typescript SendInvoice import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.sendInvoice(23548884, { attachfile: true, mail2: "tamara@example.com", }); } main(); ``` ```python SendInvoice from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.send_invoice( id_invoice=23548884, attachfile=True, mail_2="tamara@example.com", ) ``` ```csharp SendInvoice using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.SendInvoiceAsync( 23548884, new SendInvoiceRequest { Attachfile = true, Mail2 = "tamara@example.com" } ); } } ``` ```go SendInvoice package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Invoice/send/23548884?attachfile=true&mail2=tamara%40example.com" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby SendInvoice require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Invoice/send/23548884?attachfile=true&mail2=tamara%40example.com") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java SendInvoice import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Invoice/send/23548884?attachfile=true&mail2=tamara%40example.com") .header("requestToken", "") .asString(); ``` ```php SendInvoice request('GET', 'https://api-sandbox.payabli.com/api/Invoice/send/23548884?attachfile=true&mail2=tamara%40example.com', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift SendInvoice import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Invoice/send/23548884?attachfile=true&mail2=tamara%40example.com")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get invoice attachment GET https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/{idInvoice}/{filename} Retrieves a file attached to an invoice. Reference: https://docs.payabli.com/developers/api-reference/invoice/get-attached-file-from-an-invoice ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.getAttachedFileFromInvoice(1, "filename", {}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.get_attached_file_from_invoice( id_invoice=1, filename="filename", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.GetAttachedFileFromInvoiceAsync( 1, "filename", new GetAttachedFileFromInvoiceRequest() ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/1/filename" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/1/filename") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/1/filename") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/1/filename', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/1/filename")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete invoice attachment DELETE https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/{idInvoice}/{filename} Deletes an invoice that's attached to a file. Reference: https://docs.payabli.com/developers/api-reference/invoice/delete-attached-file-from-invoice ## SDK Code Examples ```typescript DeleteAttachedFromInvoice import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.deleteAttachedFromInvoice("0_Bill.pdf", 23548884); } main(); ``` ```python DeleteAttachedFromInvoice from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.delete_attached_from_invoice( filename="0_Bill.pdf", id_invoice=23548884, ) ``` ```csharp DeleteAttachedFromInvoice using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.DeleteAttachedFromInvoiceAsync( 23548884, "0_Bill.pdf" ); } } ``` ```go DeleteAttachedFromInvoice package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/23548884/0_Bill.pdf" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby DeleteAttachedFromInvoice require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/23548884/0_Bill.pdf") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java DeleteAttachedFromInvoice import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/23548884/0_Bill.pdf") .header("requestToken", "") .asString(); ``` ```php DeleteAttachedFromInvoice request('DELETE', 'https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/23548884/0_Bill.pdf', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift DeleteAttachedFromInvoice import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Invoice/attachedFileFromInvoice/23548884/0_Bill.pdf")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get next invoice number GET https://api-sandbox.payabli.com/api/Invoice/getNumber/{entry} Retrieves the next available invoice number for a paypoint. Reference: https://docs.payabli.com/developers/api-reference/invoice/get-next-invoicenumber-for-entrypoint ## SDK Code Examples ```typescript GetNextInvoiceNumber import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.getInvoiceNumber("8cfec329267"); } main(); ``` ```python GetNextInvoiceNumber from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.get_invoice_number( entry="8cfec329267", ) ``` ```csharp GetNextInvoiceNumber using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.GetInvoiceNumberAsync( "8cfec329267" ); } } ``` ```go GetNextInvoiceNumber package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Invoice/getNumber/8cfec329267" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetNextInvoiceNumber require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Invoice/getNumber/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetNextInvoiceNumber import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Invoice/getNumber/8cfec329267") .header("requestToken", "") .asString(); ``` ```php GetNextInvoiceNumber request('GET', 'https://api-sandbox.payabli.com/api/Invoice/getNumber/8cfec329267', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetNextInvoiceNumber import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Invoice/getNumber/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List invoices by paypoint GET https://api-sandbox.payabli.com/api/Query/invoices/{entry} Returns a list of invoices for an entrypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/invoice/get-list-of-invoices-for-an-entrypoint ## SDK Code Examples ```typescript InvoiceQueryResponse import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.listInvoices("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python InvoiceQueryResponse from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.list_invoices( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp InvoiceQueryResponse using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.ListInvoicesAsync( "8cfec329267", new ListInvoicesRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go InvoiceQueryResponse package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/invoices/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby InvoiceQueryResponse require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/invoices/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java InvoiceQueryResponse import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/invoices/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php InvoiceQueryResponse request('GET', 'https://api-sandbox.payabli.com/api/Query/invoices/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift InvoiceQueryResponse import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/invoices/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List invoices by organization GET https://api-sandbox.payabli.com/api/Query/invoices/org/{orgId} Returns a list of invoices for an org. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/invoice/get-list-of-invoices-for-an-organization ## SDK Code Examples ```typescript Example response for invoice queries. import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.listInvoicesOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example response for invoice queries. from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.list_invoices_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example response for invoice queries. using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.ListInvoicesOrgAsync( 123, new ListInvoicesOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example response for invoice queries. package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/invoices/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example response for invoice queries. require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/invoices/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example response for invoice queries. import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/invoices/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example response for invoice queries. request('GET', 'https://api-sandbox.payabli.com/api/Query/invoices/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example response for invoice queries. import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/invoices/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export invoices by paypoint GET https://api-sandbox.payabli.com/api/Export/invoices/{format}/{entry} Export list of invoices for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/invoice/export-list-of-invoices-for-an-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportInvoices("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_invoices( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportInvoicesAsync( ExportFormat1.Csv, "8cfec329267", new ExportInvoicesRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/invoices/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/invoices/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/invoices/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/invoices/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/invoices/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export invoices by org GET https://api-sandbox.payabli.com/api/Export/invoices/{format}/org/{orgId} Export a list of invoices for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/invoice/export-list-of-invoices-for-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportInvoicesOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_invoices_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportInvoicesOrgAsync( ExportFormat1.Csv, 123, new ExportInvoicesOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/invoices/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/invoices/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/invoices/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/invoices/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/invoices/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get invoice PDF GET https://api-sandbox.payabli.com/api/Export/invoicePdf/{idInvoice} Export a single invoice in PDF format. Reference: https://docs.payabli.com/developers/api-reference/invoice/export-invoice-pdf ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.invoice.getInvoicePdf(23548884); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.invoice.get_invoice_pdf( id_invoice=23548884, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Invoice.GetInvoicePdfAsync( 23548884 ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/invoicePdf/23548884" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/invoicePdf/23548884") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/invoicePdf/23548884") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/invoicePdf/23548884', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/invoicePdf/23548884")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create payment page POST https://api-sandbox.payabli.com/api/Paypoint/{entry} Content-Type: application/json Creates a new payment page for a paypoint. Note: this operation doesn't create a new paypoint, just a payment page for an existing paypoint. Paypoints are created by the Payabli team when a boarding application is approved. Reference: https://docs.payabli.com/developers/api-reference/hostedpaymentpages/create-a-payment-page ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.hostedPaymentPages.newPage("8cfec329267", { idempotencyKey: "6B29FC40-CA47-1067-B31D-00DD010662DA", body: {}, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.hosted_payment_pages.new_page( entry="8cfec329267", idempotency_key="6B29FC40-CA47-1067-B31D-00DD010662DA", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.HostedPaymentPages.NewPageAsync( "8cfec329267", new NewPageRequest { IdempotencyKey = "6B29FC40-CA47-1067-B31D-00DD010662DA", Body = new PayabliPages() } ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267" payload := strings.NewReader("{}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["idempotencyKey"] = '6B29FC40-CA47-1067-B31D-00DD010662DA' request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267") .header("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/Paypoint/8cfec329267', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'idempotencyKey' => '6B29FC40-CA47-1067-B31D-00DD010662DA', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "idempotencyKey": "6B29FC40-CA47-1067-B31D-00DD010662DA", "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get payment page GET https://api-sandbox.payabli.com/api/Paypoint/{entry}/{subdomain} Gets the details for single payment page for a paypoint. Reference: https://docs.payabli.com/developers/api-reference/hostedpaymentpages/get-payment-page-details ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paypoint.getPage("8cfec329267", "pay-your-fees-1"); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.paypoint.get_page( entry="8cfec329267", subdomain="pay-your-fees-1", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Paypoint.GetPageAsync( "8cfec329267", "pay-your-fees-1" ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get all page details GET https://api-sandbox.payabli.com/api/Paypoint/load/{entry}/{subdomain} Loads all of a payment page's details including `pageIdentifier` and `validationCode`. This endpoint requires an `application` API token. Reference: https://docs.payabli.com/developers/api-reference/hostedpaymentpages/get-all-payment-page-details ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.hostedPaymentPages.loadPage("8cfec329267", "pay-your-fees-1"); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.hosted_payment_pages.load_page( entry="8cfec329267", subdomain="pay-your-fees-1", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.HostedPaymentPages.LoadPageAsync( "8cfec329267", "pay-your-fees-1" ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/load/8cfec329267/pay-your-fees-1" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/load/8cfec329267/pay-your-fees-1") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Paypoint/load/8cfec329267/pay-your-fees-1") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Paypoint/load/8cfec329267/pay-your-fees-1', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/load/8cfec329267/pay-your-fees-1")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update payment page PUT https://api-sandbox.payabli.com/api/Paypoint/{entry}/{subdomain} Content-Type: application/json Updates a payment page in a paypoint. Reference: https://docs.payabli.com/developers/api-reference/hostedpaymentpages/update-a-payment-page ## SDK Code Examples ```typescript Example import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.hostedPaymentPages.savePage("8cfec329267", "pay-your-fees-1", {}); } main(); ``` ```python Example from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.hosted_payment_pages.save_page( entry="8cfec329267", subdomain_="pay-your-fees-1", ) ``` ```csharp Example using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.HostedPaymentPages.SavePageAsync( "8cfec329267", "pay-your-fees-1", new PayabliPages() ); } } ``` ```go Example package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1" payload := strings.NewReader("{}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java Example import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php Example request('PUT', 'https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete payment page DELETE https://api-sandbox.payabli.com/api/Paypoint/{entry}/{subdomain} Deletes a payment page in a paypoint. Reference: https://docs.payabli.com/developers/api-reference/hostedpaymentpages/delete-a-payment-page ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paypoint.removePage("8cfec329267", "pay-your-fees-1"); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.paypoint.remove_page( entry="8cfec329267", subdomain="pay-your-fees-1", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Paypoint.RemovePageAsync( "8cfec329267", "pay-your-fees-1" ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1") .header("requestToken", "") .asString(); ``` ```php request('DELETE', 'https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267/pay-your-fees-1")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get dispute record GET https://api-sandbox.payabli.com/api/ChargeBacks/read/{Id} Retrieves a chargeback record and its details. Reference: https://docs.payabli.com/developers/api-reference/chargebacks/get-chargeback-record ## SDK Code Examples ```typescript GetChargeback import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.chargeBacks.getChargeback(1000000); } main(); ``` ```python GetChargeback from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.charge_backs.get_chargeback( id=1000000, ) ``` ```csharp GetChargeback using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.ChargeBacks.GetChargebackAsync( 1000000L ); } } ``` ```go GetChargeback package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/ChargeBacks/read/1000000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetChargeback require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/ChargeBacks/read/1000000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetChargeback import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/ChargeBacks/read/1000000") .header("requestToken", "") .asString(); ``` ```php GetChargeback request('GET', 'https://api-sandbox.payabli.com/api/ChargeBacks/read/1000000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetChargeback import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/ChargeBacks/read/1000000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Add response to dispute POST https://api-sandbox.payabli.com/api/ChargeBacks/response/{Id} Content-Type: application/json Add a response to a chargeback or ACH return. Reference: https://docs.payabli.com/developers/api-reference/chargebacks/add-response-to-chargeback-or-return ## SDK Code Examples ```typescript General success response example for chargebacks. import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.chargeBacks.addResponse(1000000, { idempotencyKey: "6B29FC40-CA47-1067-B31D-00DD010662DA", }); } main(); ``` ```python General success response example for chargebacks. from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.charge_backs.add_response( id=1000000, idempotency_key="6B29FC40-CA47-1067-B31D-00DD010662DA", ) ``` ```csharp General success response example for chargebacks. using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.ChargeBacks.AddResponseAsync( 1000000L, new ResponseChargeBack { IdempotencyKey = "6B29FC40-CA47-1067-B31D-00DD010662DA" } ); } } ``` ```go General success response example for chargebacks. package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/ChargeBacks/response/1000000" payload := strings.NewReader("{}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby General success response example for chargebacks. require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/ChargeBacks/response/1000000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["idempotencyKey"] = '6B29FC40-CA47-1067-B31D-00DD010662DA' request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java General success response example for chargebacks. import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/ChargeBacks/response/1000000") .header("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php General success response example for chargebacks. request('POST', 'https://api-sandbox.payabli.com/api/ChargeBacks/response/1000000', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'idempotencyKey' => '6B29FC40-CA47-1067-B31D-00DD010662DA', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift General success response example for chargebacks. import Foundation let headers = [ "idempotencyKey": "6B29FC40-CA47-1067-B31D-00DD010662DA", "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/ChargeBacks/response/1000000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get dispute attachment GET https://api-sandbox.payabli.com/api/ChargeBacks/getChargebackAttachments/{Id}/{fileName} Retrieves a chargeback attachment file by its file name. Reference: https://docs.payabli.com/developers/api-reference/chargebacks/get-attachments-from-chargeback ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.chargeBacks.getChargebackAttachment(1000000, "fileName"); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.charge_backs.get_chargeback_attachment( id=1000000, file_name="fileName", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.ChargeBacks.GetChargebackAttachmentAsync( 1000000L, "fileName" ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/ChargeBacks/getChargebackAttachments/1000000/fileName" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/ChargeBacks/getChargebackAttachments/1000000/fileName") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/ChargeBacks/getChargebackAttachments/1000000/fileName") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/ChargeBacks/getChargebackAttachments/1000000/fileName', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/ChargeBacks/getChargebackAttachments/1000000/fileName")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List disputes by paypoint GET https://api-sandbox.payabli.com/api/Query/chargebacks/{entry} Retrieves a list of chargebacks and returned transactions for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/chargebacks/get-list-of-chargebacks-and-returned-transactions-for-an-entrypoint ## SDK Code Examples ```typescript Example1 import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listChargebacks("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example1 from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_chargebacks( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example1 using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListChargebacksAsync( "8cfec329267", new ListChargebacksRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example1 package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/chargebacks/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example1 require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/chargebacks/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example1 import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/chargebacks/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example1 request('GET', 'https://api-sandbox.payabli.com/api/Query/chargebacks/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example1 import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/chargebacks/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export disputes by paypoint GET https://api-sandbox.payabli.com/api/Export/chargebacks/{format}/{entry} Export a list of chargebacks and ACH returns for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/chargebacks/export-list-of-chargebacks-and-returned-transactions-for-an-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportChargebacks("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_chargebacks( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportChargebacksAsync( ExportFormat1.Csv, "8cfec329267", new ExportChargebacksRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/chargebacks/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/chargebacks/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/chargebacks/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/chargebacks/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/chargebacks/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export disputes by org GET https://api-sandbox.payabli.com/api/Export/chargebacks/{format}/org/{orgId} Export a list of chargebacks and ACH returns for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/chargebacks/export-list-of-chargebacks-and-returned-transactions-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportChargebacksOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_chargebacks_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportChargebacksOrgAsync( ExportFormat1.Csv, 123, new ExportChargebacksOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/chargebacks/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/chargebacks/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/chargebacks/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/chargebacks/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/chargebacks/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Configure Apple Pay for org POST https://api-sandbox.payabli.com/api/Wallet/applepay/configure-organization Content-Type: application/json Configure and activate Apple Pay for a Payabli organization Reference: https://docs.payabli.com/developers/api-reference/wallet/applepay/applepay-configure-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.wallet.configureApplePayOrganization({ cascade: true, isEnabled: true, orgId: 901, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.wallet.configure_apple_pay_organization( cascade=True, is_enabled=True, org_id=901, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Wallet.ConfigureApplePayOrganizationAsync( new ConfigureOrganizationRequestApplePay { Cascade = true, IsEnabled = true, OrgId = 901L } ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Wallet/applepay/configure-organization" payload := strings.NewReader("{\n \"cascade\": true,\n \"isEnabled\": true,\n \"orgId\": 901\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Wallet/applepay/configure-organization") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"cascade\": true,\n \"isEnabled\": true,\n \"orgId\": 901\n}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Wallet/applepay/configure-organization") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"cascade\": true,\n \"isEnabled\": true,\n \"orgId\": 901\n}") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/Wallet/applepay/configure-organization', [ 'body' => '{ "cascade": true, "isEnabled": true, "orgId": 901 }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "cascade": true, "isEnabled": true, "orgId": 901 ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Wallet/applepay/configure-organization")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Configure Apple Pay for paypoint POST https://api-sandbox.payabli.com/api/Wallet/applepay/configure-paypoint Content-Type: application/json Configure and activate Apple Pay for a Payabli paypoint Reference: https://docs.payabli.com/developers/api-reference/wallet/applepay/applepay-configure-paypoint ## SDK Code Examples ```typescript Paypoint import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.wallet.configureApplePayPaypoint({ entry: "8cfec329267", isEnabled: true, }); } main(); ``` ```python Paypoint from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.wallet.configure_apple_pay_paypoint( entry="8cfec329267", is_enabled=True, ) ``` ```csharp Paypoint using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Wallet.ConfigureApplePayPaypointAsync( new ConfigurePaypointRequestApplePay { Entry = "8cfec329267", IsEnabled = true } ); } } ``` ```go Paypoint package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Wallet/applepay/configure-paypoint" payload := strings.NewReader("{\n \"entry\": \"8cfec329267\",\n \"isEnabled\": true\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Paypoint require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Wallet/applepay/configure-paypoint") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entry\": \"8cfec329267\",\n \"isEnabled\": true\n}" response = http.request(request) puts response.read_body ``` ```java Paypoint import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Wallet/applepay/configure-paypoint") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entry\": \"8cfec329267\",\n \"isEnabled\": true\n}") .asString(); ``` ```php Paypoint request('POST', 'https://api-sandbox.payabli.com/api/Wallet/applepay/configure-paypoint', [ 'body' => '{ "entry": "8cfec329267", "isEnabled": true }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Paypoint import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entry": "8cfec329267", "isEnabled": true ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Wallet/applepay/configure-paypoint")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Configure Google Pay™ for org POST https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-organization Content-Type: application/json Configure and activate Google Pay for a Payabli organization Reference: https://docs.payabli.com/developers/api-reference/wallet/googlepay/googlepay-configure-organization ## SDK Code Examples ```typescript ConfigureOrganization import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.wallet.configureGooglePayOrganization({ cascade: true, isEnabled: true, orgId: 901, }); } main(); ``` ```python ConfigureOrganization from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.wallet.configure_google_pay_organization( cascade=True, is_enabled=True, org_id=901, ) ``` ```csharp ConfigureOrganization using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Wallet.ConfigureGooglePayOrganizationAsync( new ConfigureOrganizationRequestGooglePay { Cascade = true, IsEnabled = true, OrgId = 901L } ); } } ``` ```go ConfigureOrganization package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-organization" payload := strings.NewReader("{\n \"cascade\": true,\n \"isEnabled\": true,\n \"orgId\": 901\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ConfigureOrganization require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-organization") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"cascade\": true,\n \"isEnabled\": true,\n \"orgId\": 901\n}" response = http.request(request) puts response.read_body ``` ```java ConfigureOrganization import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-organization") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"cascade\": true,\n \"isEnabled\": true,\n \"orgId\": 901\n}") .asString(); ``` ```php ConfigureOrganization request('POST', 'https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-organization', [ 'body' => '{ "cascade": true, "isEnabled": true, "orgId": 901 }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ConfigureOrganization import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "cascade": true, "isEnabled": true, "orgId": 901 ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-organization")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Configure Google Pay™ for paypoint POST https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-paypoint Content-Type: application/json Configure and activate Google Pay for a Payabli paypoint Reference: https://docs.payabli.com/developers/api-reference/wallet/googlepay/googlepay-configure-paypoint ## SDK Code Examples ```typescript ConfigurePaypoint import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.wallet.configureGooglePayPaypoint({ entry: "8cfec329267", isEnabled: true, }); } main(); ``` ```python ConfigurePaypoint from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.wallet.configure_google_pay_paypoint( entry="8cfec329267", is_enabled=True, ) ``` ```csharp ConfigurePaypoint using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Wallet.ConfigureGooglePayPaypointAsync( new ConfigurePaypointRequestGooglePay { Entry = "8cfec329267", IsEnabled = true } ); } } ``` ```go ConfigurePaypoint package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-paypoint" payload := strings.NewReader("{\n \"entry\": \"8cfec329267\",\n \"isEnabled\": true\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ConfigurePaypoint require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-paypoint") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entry\": \"8cfec329267\",\n \"isEnabled\": true\n}" response = http.request(request) puts response.read_body ``` ```java ConfigurePaypoint import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-paypoint") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entry\": \"8cfec329267\",\n \"isEnabled\": true\n}") .asString(); ``` ```php ConfigurePaypoint request('POST', 'https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-paypoint', [ 'body' => '{ "entry": "8cfec329267", "isEnabled": true }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ConfigurePaypoint import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entry": "8cfec329267", "isEnabled": true ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Wallet/googlepay/configure-paypoint")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Add domain POST https://api-sandbox.payabli.com/api/PaymentMethodDomain Content-Type: application/json Add a payment method domain to an organization or paypoint. Reference: https://docs.payabli.com/developers/api-reference/paymentmethoddomain/paymentmethoddomain-add ## SDK Code Examples ```typescript Paypoint import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentMethodDomain.addPaymentMethodDomain({ applePay: { isEnabled: true, }, googlePay: { isEnabled: true, }, domainName: "checkout.example.com", entityId: 109, entityType: "paypoint", }); } main(); ``` ```python Paypoint from payabli import payabli from payabli.payment_method_domain import AddPaymentMethodDomainRequestApplePay, AddPaymentMethodDomainRequestGooglePay client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_method_domain.add_payment_method_domain( apple_pay=AddPaymentMethodDomainRequestApplePay( is_enabled=True, ), google_pay=AddPaymentMethodDomainRequestGooglePay( is_enabled=True, ), domain_name="checkout.example.com", entity_id=109, entity_type="paypoint", ) ``` ```csharp Paypoint using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentMethodDomain.AddPaymentMethodDomainAsync( new AddPaymentMethodDomainRequest { ApplePay = new AddPaymentMethodDomainRequestApplePay { IsEnabled = true }, GooglePay = new AddPaymentMethodDomainRequestGooglePay { IsEnabled = true }, DomainName = "checkout.example.com", EntityId = 109L, EntityType = "paypoint" } ); } } ``` ```go Paypoint package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentMethodDomain" payload := strings.NewReader("{\n \"applePay\": {\n \"isEnabled\": true\n },\n \"googlePay\": {\n \"isEnabled\": true\n },\n \"domainName\": \"checkout.example.com\",\n \"entityId\": 109,\n \"entityType\": \"paypoint\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Paypoint require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentMethodDomain") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"applePay\": {\n \"isEnabled\": true\n },\n \"googlePay\": {\n \"isEnabled\": true\n },\n \"domainName\": \"checkout.example.com\",\n \"entityId\": 109,\n \"entityType\": \"paypoint\"\n}" response = http.request(request) puts response.read_body ``` ```java Paypoint import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentMethodDomain") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"applePay\": {\n \"isEnabled\": true\n },\n \"googlePay\": {\n \"isEnabled\": true\n },\n \"domainName\": \"checkout.example.com\",\n \"entityId\": 109,\n \"entityType\": \"paypoint\"\n}") .asString(); ``` ```php Paypoint request('POST', 'https://api-sandbox.payabli.com/api/PaymentMethodDomain', [ 'body' => '{ "applePay": { "isEnabled": true }, "googlePay": { "isEnabled": true }, "domainName": "checkout.example.com", "entityId": 109, "entityType": "paypoint" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Paypoint import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "applePay": ["isEnabled": true], "googlePay": ["isEnabled": true], "domainName": "checkout.example.com", "entityId": 109, "entityType": "paypoint" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentMethodDomain")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Cascade domain POST https://api-sandbox.payabli.com/api/PaymentMethodDomain/{domainId}/cascade Cascades a payment method domain to all child entities. All paypoints and suborganization under this parent will inherit this domain and its settings. Reference: https://docs.payabli.com/developers/api-reference/paymentmethoddomain/paymentmethoddomain-cascade ## SDK Code Examples ```typescript CascadeDomains import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentMethodDomain.cascadePaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5"); } main(); ``` ```python CascadeDomains from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_method_domain.cascade_payment_method_domain( domain_id="pmd_b8237fa45c964d8a9ef27160cd42b8c5", ) ``` ```csharp CascadeDomains using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentMethodDomain.CascadePaymentMethodDomainAsync( "pmd_b8237fa45c964d8a9ef27160cd42b8c5" ); } } ``` ```go CascadeDomains package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/cascade" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CascadeDomains require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/cascade") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java CascadeDomains import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/cascade") .header("requestToken", "") .asString(); ``` ```php CascadeDomains request('POST', 'https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/cascade', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CascadeDomains import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/cascade")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Verify domain POST https://api-sandbox.payabli.com/api/PaymentMethodDomain/{domainId}/verify Verify a new payment method domain. If verification is successful, Apple Pay is automatically activated for the domain. Reference: https://docs.payabli.com/developers/api-reference/paymentmethoddomain/paymentmethoddomain-verify ## SDK Code Examples ```typescript VerifySuccess import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentMethodDomain.verifyPaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5"); } main(); ``` ```python VerifySuccess from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_method_domain.verify_payment_method_domain( domain_id="pmd_b8237fa45c964d8a9ef27160cd42b8c5", ) ``` ```csharp VerifySuccess using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentMethodDomain.VerifyPaymentMethodDomainAsync( "pmd_b8237fa45c964d8a9ef27160cd42b8c5" ); } } ``` ```go VerifySuccess package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby VerifySuccess require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java VerifySuccess import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify") .header("requestToken", "") .asString(); ``` ```php VerifySuccess request('POST', 'https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift VerifySuccess import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript VerifyFailure import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentMethodDomain.verifyPaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5"); } main(); ``` ```python VerifyFailure from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_method_domain.verify_payment_method_domain( domain_id="pmd_b8237fa45c964d8a9ef27160cd42b8c5", ) ``` ```csharp VerifyFailure using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentMethodDomain.VerifyPaymentMethodDomainAsync( "pmd_b8237fa45c964d8a9ef27160cd42b8c5" ); } } ``` ```go VerifyFailure package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby VerifyFailure require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java VerifyFailure import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify") .header("requestToken", "") .asString(); ``` ```php VerifyFailure request('POST', 'https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift VerifyFailure import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5/verify")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get payment method domain GET https://api-sandbox.payabli.com/api/PaymentMethodDomain/{domainId} Get the details for a payment method domain. Reference: https://docs.payabli.com/developers/api-reference/paymentmethoddomain/paymentmethoddomain-get ## SDK Code Examples ```typescript GetDomain import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentMethodDomain.getPaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5"); } main(); ``` ```python GetDomain from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_method_domain.get_payment_method_domain( domain_id="pmd_b8237fa45c964d8a9ef27160cd42b8c5", ) ``` ```csharp GetDomain using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentMethodDomain.GetPaymentMethodDomainAsync( "pmd_b8237fa45c964d8a9ef27160cd42b8c5" ); } } ``` ```go GetDomain package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetDomain require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetDomain import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5") .header("requestToken", "") .asString(); ``` ```php GetDomain request('GET', 'https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetDomain import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List payment method domains GET https://api-sandbox.payabli.com/api/PaymentMethodDomain/list Get a list of payment method domains that belong to a PSP, organization, or paypoint. Reference: https://docs.payabli.com/developers/api-reference/paymentmethoddomain/get-list-of-payment-method-domains ## SDK Code Examples ```typescript PaypointDomains import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentMethodDomain.listPaymentMethodDomains({ entityId: 1147, entityType: "paypoint", }); } main(); ``` ```python PaypointDomains from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_method_domain.list_payment_method_domains( entity_id=1147, entity_type="paypoint", ) ``` ```csharp PaypointDomains using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentMethodDomain.ListPaymentMethodDomainsAsync( new ListPaymentMethodDomainsRequest { EntityId = 1147L, EntityType = "paypoint" } ); } } ``` ```go PaypointDomains package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=1147&entityType=paypoint" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby PaypointDomains require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=1147&entityType=paypoint") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java PaypointDomains import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=1147&entityType=paypoint") .header("requestToken", "") .asString(); ``` ```php PaypointDomains request('GET', 'https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=1147&entityType=paypoint', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift PaypointDomains import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=1147&entityType=paypoint")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript OrgDomains import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentMethodDomain.listPaymentMethodDomains({ entityId: 39, entityType: "organization", }); } main(); ``` ```python OrgDomains from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_method_domain.list_payment_method_domains( entity_id=39, entity_type="organization", ) ``` ```csharp OrgDomains using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentMethodDomain.ListPaymentMethodDomainsAsync( new ListPaymentMethodDomainsRequest { EntityId = 39L, EntityType = "organization" } ); } } ``` ```go OrgDomains package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=39&entityType=organization" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby OrgDomains require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=39&entityType=organization") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java OrgDomains import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=39&entityType=organization") .header("requestToken", "") .asString(); ``` ```php OrgDomains request('GET', 'https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=39&entityType=organization', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift OrgDomains import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentMethodDomain/list?entityId=39&entityType=organization")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update payment method domain PATCH https://api-sandbox.payabli.com/api/PaymentMethodDomain/{domainId} Content-Type: application/json Update a payment method domain's configuration values. Reference: https://docs.payabli.com/developers/api-reference/paymentmethoddomain/paymentmethoddomain-update ## SDK Code Examples ```typescript UpdatePaymentMethodDomain import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentMethodDomain.updatePaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5", { applePay: { isEnabled: false, }, googlePay: { isEnabled: false, }, }); } main(); ``` ```python UpdatePaymentMethodDomain from payabli import payabli from payabli.payment_method_domain import UpdatePaymentMethodDomainRequestWallet client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_method_domain.update_payment_method_domain( domain_id="pmd_b8237fa45c964d8a9ef27160cd42b8c5", apple_pay=UpdatePaymentMethodDomainRequestWallet( is_enabled=False, ), google_pay=UpdatePaymentMethodDomainRequestWallet( is_enabled=False, ), ) ``` ```csharp UpdatePaymentMethodDomain using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentMethodDomain.UpdatePaymentMethodDomainAsync( "pmd_b8237fa45c964d8a9ef27160cd42b8c5", new UpdatePaymentMethodDomainRequest { ApplePay = new UpdatePaymentMethodDomainRequestWallet { IsEnabled = false }, GooglePay = new UpdatePaymentMethodDomainRequestWallet { IsEnabled = false } } ); } } ``` ```go UpdatePaymentMethodDomain package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5" payload := strings.NewReader("{\n \"applePay\": {\n \"isEnabled\": false\n },\n \"googlePay\": {\n \"isEnabled\": false\n }\n}") req, _ := http.NewRequest("PATCH", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdatePaymentMethodDomain require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"applePay\": {\n \"isEnabled\": false\n },\n \"googlePay\": {\n \"isEnabled\": false\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdatePaymentMethodDomain import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"applePay\": {\n \"isEnabled\": false\n },\n \"googlePay\": {\n \"isEnabled\": false\n }\n}") .asString(); ``` ```php UpdatePaymentMethodDomain request('PATCH', 'https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5', [ 'body' => '{ "applePay": { "isEnabled": false }, "googlePay": { "isEnabled": false } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdatePaymentMethodDomain import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "applePay": ["isEnabled": false], "googlePay": ["isEnabled": false] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete payment method domain DELETE https://api-sandbox.payabli.com/api/PaymentMethodDomain/{domainId} Delete a payment method domain. You can't delete an inherited domain, you must delete a domain at the organization level. Reference: https://docs.payabli.com/developers/api-reference/paymentmethoddomain/paymentmethoddomain-delete ## SDK Code Examples ```typescript Delete import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentMethodDomain.deletePaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5"); } main(); ``` ```python Delete from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_method_domain.delete_payment_method_domain( domain_id="pmd_b8237fa45c964d8a9ef27160cd42b8c5", ) ``` ```csharp Delete using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentMethodDomain.DeletePaymentMethodDomainAsync( "pmd_b8237fa45c964d8a9ef27160cd42b8c5" ); } } ``` ```go Delete package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Delete require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Delete import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5") .header("requestToken", "") .asString(); ``` ```php Delete request('DELETE', 'https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Delete import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentMethodDomain/pmd_b8237fa45c964d8a9ef27160cd42b8c5")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Authorize payout POST https://api-sandbox.payabli.com/api/MoneyOut/authorize Content-Type: application/json Authorizes transaction for payout. Authorized transactions aren't flagged for settlement until captured. Use `referenceId` returned in the response to capture the transaction. Reference: https://docs.payabli.com/developers/api-reference/moneyout/authorize-a-transaction-for-payout ## SDK Code Examples ```typescript AuthorizePayout import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.authorizeOut({ body: { entryPoint: "48acde49", paymentMethod: { method: "managed", }, paymentDetails: { totalAmount: 47, unbundled: false, }, vendorData: { vendorNumber: "7895433", }, invoiceData: [ { billId: 54323, }, ], orderDescription: "Window Painting", }, }); } main(); ``` ```python AuthorizePayout from payabli import payabli from payabli.money_out_types import AuthorizePaymentMethod, RequestOutAuthorizePaymentDetails, RequestOutAuthorizeVendorData, RequestOutAuthorizeInvoiceData client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.authorize_out( entry_point="48acde49", payment_method=AuthorizePaymentMethod( method="managed", ), payment_details=RequestOutAuthorizePaymentDetails( total_amount=47, unbundled=False, ), vendor_data=RequestOutAuthorizeVendorData( vendor_number="7895433", ), invoice_data=[ RequestOutAuthorizeInvoiceData( bill_id=54323, ) ], order_description="Window Painting", ) ``` ```csharp AuthorizePayout using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.AuthorizeOutAsync( new MoneyOutTypesRequestOutAuthorize { Body = new AuthorizePayoutBody { EntryPoint = "48acde49", PaymentMethod = new AuthorizePaymentMethod { Method = "managed" }, PaymentDetails = new RequestOutAuthorizePaymentDetails { TotalAmount = 47, Unbundled = false }, VendorData = new RequestOutAuthorizeVendorData { VendorNumber = "7895433" }, InvoiceData = new List(){ new RequestOutAuthorizeInvoiceData { BillId = 54323L }, } , OrderDescription = "Window Painting" } } ); } } ``` ```go AuthorizePayout package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/authorize" payload := strings.NewReader("{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"managed\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 47,\n \"unbundled\": false\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 54323\n }\n ],\n \"orderDescription\": \"Window Painting\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby AuthorizePayout require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/authorize") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"managed\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 47,\n \"unbundled\": false\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 54323\n }\n ],\n \"orderDescription\": \"Window Painting\"\n}" response = http.request(request) puts response.read_body ``` ```java AuthorizePayout import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyOut/authorize") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"managed\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 47,\n \"unbundled\": false\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 54323\n }\n ],\n \"orderDescription\": \"Window Painting\"\n}") .asString(); ``` ```php AuthorizePayout request('POST', 'https://api-sandbox.payabli.com/api/MoneyOut/authorize', [ 'body' => '{ "entryPoint": "48acde49", "paymentMethod": { "method": "managed" }, "paymentDetails": { "totalAmount": 47, "unbundled": false }, "vendorData": { "vendorNumber": "7895433" }, "invoiceData": [ { "billId": 54323 } ], "orderDescription": "Window Painting" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift AuthorizePayout import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "48acde49", "paymentMethod": ["method": "managed"], "paymentDetails": [ "totalAmount": 47, "unbundled": false ], "vendorData": ["vendorNumber": "7895433"], "invoiceData": [["billId": 54323]], "orderDescription": "Window Painting" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/authorize")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript WithImage import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.authorizeOut({ body: { entryPoint: "48acde49", paymentMethod: { method: "managed", }, paymentDetails: { totalAmount: 47, }, vendorData: { vendorNumber: "7895433", }, invoiceData: [ { billId: 123, attachments: [ { filename: "bill.pdf", ftype: "pdf", furl: "https://example.com/bill.pdf", }, ], }, ], orderDescription: "Window Painting", }, }); } main(); ``` ```python WithImage from payabli import payabli, FileContent from payabli.money_out_types import AuthorizePaymentMethod, RequestOutAuthorizePaymentDetails, RequestOutAuthorizeVendorData, RequestOutAuthorizeInvoiceData client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.authorize_out( entry_point="48acde49", payment_method=AuthorizePaymentMethod( method="managed", ), payment_details=RequestOutAuthorizePaymentDetails( total_amount=47, ), vendor_data=RequestOutAuthorizeVendorData( vendor_number="7895433", ), invoice_data=[ RequestOutAuthorizeInvoiceData( bill_id=123, attachments=[ FileContent( filename="bill.pdf", ftype="pdf", furl="https://example.com/bill.pdf", ) ], ) ], order_description="Window Painting", ) ``` ```csharp WithImage using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.AuthorizeOutAsync( new MoneyOutTypesRequestOutAuthorize { Body = new AuthorizePayoutBody { EntryPoint = "48acde49", PaymentMethod = new AuthorizePaymentMethod { Method = "managed" }, PaymentDetails = new RequestOutAuthorizePaymentDetails { TotalAmount = 47 }, VendorData = new RequestOutAuthorizeVendorData { VendorNumber = "7895433" }, InvoiceData = new List(){ new RequestOutAuthorizeInvoiceData { BillId = 123L, Attachments = new List(){ new FileContent { Filename = "bill.pdf", Ftype = FileContentFtype.Pdf, Furl = "https://example.com/bill.pdf" }, } }, } , OrderDescription = "Window Painting" } } ); } } ``` ```go WithImage package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/authorize" payload := strings.NewReader("{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"managed\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 47\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 123,\n \"attachments\": [\n {\n \"filename\": \"bill.pdf\",\n \"ftype\": \"pdf\",\n \"furl\": \"https://example.com/bill.pdf\"\n }\n ]\n }\n ],\n \"orderDescription\": \"Window Painting\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby WithImage require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/authorize") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"managed\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 47\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 123,\n \"attachments\": [\n {\n \"filename\": \"bill.pdf\",\n \"ftype\": \"pdf\",\n \"furl\": \"https://example.com/bill.pdf\"\n }\n ]\n }\n ],\n \"orderDescription\": \"Window Painting\"\n}" response = http.request(request) puts response.read_body ``` ```java WithImage import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyOut/authorize") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"managed\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 47\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 123,\n \"attachments\": [\n {\n \"filename\": \"bill.pdf\",\n \"ftype\": \"pdf\",\n \"furl\": \"https://example.com/bill.pdf\"\n }\n ]\n }\n ],\n \"orderDescription\": \"Window Painting\"\n}") .asString(); ``` ```php WithImage request('POST', 'https://api-sandbox.payabli.com/api/MoneyOut/authorize', [ 'body' => '{ "entryPoint": "48acde49", "paymentMethod": { "method": "managed" }, "paymentDetails": { "totalAmount": 47 }, "vendorData": { "vendorNumber": "7895433" }, "invoiceData": [ { "billId": 123, "attachments": [ { "filename": "bill.pdf", "ftype": "pdf", "furl": "https://example.com/bill.pdf" } ] } ], "orderDescription": "Window Painting" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift WithImage import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "48acde49", "paymentMethod": ["method": "managed"], "paymentDetails": ["totalAmount": 47], "vendorData": ["vendorNumber": "7895433"], "invoiceData": [ [ "billId": 123, "attachments": [ [ "filename": "bill.pdf", "ftype": "pdf", "furl": "https://example.com/bill.pdf" ] ] ] ], "orderDescription": "Window Painting" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/authorize")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript StoredACH import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.authorizeOut({ body: { entryPoint: "48acde49", paymentMethod: { method: "ach", storedMethodId: "4c6a4b78-72de-4bdd-9455-b9d30f991001-XXXX", }, paymentDetails: { totalAmount: 47, }, vendorData: { vendorNumber: "7895433", }, invoiceData: [ { billId: 54323, }, ], source: "api", orderDescription: "Window Painting", }, }); } main(); ``` ```python StoredACH from payabli import payabli from payabli.money_out_types import AuthorizePaymentMethod, RequestOutAuthorizePaymentDetails, RequestOutAuthorizeVendorData, RequestOutAuthorizeInvoiceData client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.authorize_out( entry_point="48acde49", payment_method=AuthorizePaymentMethod( method="ach", stored_method_id="4c6a4b78-72de-4bdd-9455-b9d30f991001-XXXX", ), payment_details=RequestOutAuthorizePaymentDetails( total_amount=47, ), vendor_data=RequestOutAuthorizeVendorData( vendor_number="7895433", ), invoice_data=[ RequestOutAuthorizeInvoiceData( bill_id=54323, ) ], source="api", order_description="Window Painting", ) ``` ```csharp StoredACH using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.AuthorizeOutAsync( new MoneyOutTypesRequestOutAuthorize { Body = new AuthorizePayoutBody { EntryPoint = "48acde49", PaymentMethod = new AuthorizePaymentMethod { Method = "ach", StoredMethodId = "4c6a4b78-72de-4bdd-9455-b9d30f991001-XXXX" }, PaymentDetails = new RequestOutAuthorizePaymentDetails { TotalAmount = 47 }, VendorData = new RequestOutAuthorizeVendorData { VendorNumber = "7895433" }, InvoiceData = new List(){ new RequestOutAuthorizeInvoiceData { BillId = 54323L }, } , Source = "api", OrderDescription = "Window Painting" } } ); } } ``` ```go StoredACH package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/authorize" payload := strings.NewReader("{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"storedMethodId\": \"4c6a4b78-72de-4bdd-9455-b9d30f991001-XXXX\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 47\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 54323\n }\n ],\n \"source\": \"api\",\n \"orderDescription\": \"Window Painting\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby StoredACH require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/authorize") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"storedMethodId\": \"4c6a4b78-72de-4bdd-9455-b9d30f991001-XXXX\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 47\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 54323\n }\n ],\n \"source\": \"api\",\n \"orderDescription\": \"Window Painting\"\n}" response = http.request(request) puts response.read_body ``` ```java StoredACH import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyOut/authorize") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"storedMethodId\": \"4c6a4b78-72de-4bdd-9455-b9d30f991001-XXXX\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 47\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 54323\n }\n ],\n \"source\": \"api\",\n \"orderDescription\": \"Window Painting\"\n}") .asString(); ``` ```php StoredACH request('POST', 'https://api-sandbox.payabli.com/api/MoneyOut/authorize', [ 'body' => '{ "entryPoint": "48acde49", "paymentMethod": { "method": "ach", "storedMethodId": "4c6a4b78-72de-4bdd-9455-b9d30f991001-XXXX" }, "paymentDetails": { "totalAmount": 47 }, "vendorData": { "vendorNumber": "7895433" }, "invoiceData": [ { "billId": 54323 } ], "source": "api", "orderDescription": "Window Painting" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift StoredACH import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "48acde49", "paymentMethod": [ "method": "ach", "storedMethodId": "4c6a4b78-72de-4bdd-9455-b9d30f991001-XXXX" ], "paymentDetails": ["totalAmount": 47], "vendorData": ["vendorNumber": "7895433"], "invoiceData": [["billId": 54323]], "source": "api", "orderDescription": "Window Painting" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/authorize")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript CheckPayout import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.authorizeOut({ body: { entryPoint: "48acde49", paymentMethod: { method: "check", }, paymentDetails: { checkNumber: "10001", totalAmount: 1500, }, vendorData: { vendorNumber: "7895433", }, invoiceData: [ { billId: 54323, }, ], orderDescription: "Office Supplies", }, }); } main(); ``` ```python CheckPayout from payabli import payabli from payabli.money_out_types import AuthorizePaymentMethod, RequestOutAuthorizePaymentDetails, RequestOutAuthorizeVendorData, RequestOutAuthorizeInvoiceData client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.authorize_out( entry_point="48acde49", payment_method=AuthorizePaymentMethod( method="check", ), payment_details=RequestOutAuthorizePaymentDetails( check_number="10001", total_amount=1500, ), vendor_data=RequestOutAuthorizeVendorData( vendor_number="7895433", ), invoice_data=[ RequestOutAuthorizeInvoiceData( bill_id=54323, ) ], order_description="Office Supplies", ) ``` ```csharp CheckPayout using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.AuthorizeOutAsync( new MoneyOutTypesRequestOutAuthorize { Body = new AuthorizePayoutBody { EntryPoint = "48acde49", PaymentMethod = new AuthorizePaymentMethod { Method = "check" }, PaymentDetails = new RequestOutAuthorizePaymentDetails { CheckNumber = "10001", TotalAmount = 1500 }, VendorData = new RequestOutAuthorizeVendorData { VendorNumber = "7895433" }, InvoiceData = new List(){ new RequestOutAuthorizeInvoiceData { BillId = 54323L }, } , OrderDescription = "Office Supplies" } } ); } } ``` ```go CheckPayout package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/authorize" payload := strings.NewReader("{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"check\"\n },\n \"paymentDetails\": {\n \"checkNumber\": \"10001\",\n \"totalAmount\": 1500\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 54323\n }\n ],\n \"orderDescription\": \"Office Supplies\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CheckPayout require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/authorize") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"check\"\n },\n \"paymentDetails\": {\n \"checkNumber\": \"10001\",\n \"totalAmount\": 1500\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 54323\n }\n ],\n \"orderDescription\": \"Office Supplies\"\n}" response = http.request(request) puts response.read_body ``` ```java CheckPayout import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyOut/authorize") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"48acde49\",\n \"paymentMethod\": {\n \"method\": \"check\"\n },\n \"paymentDetails\": {\n \"checkNumber\": \"10001\",\n \"totalAmount\": 1500\n },\n \"vendorData\": {\n \"vendorNumber\": \"7895433\"\n },\n \"invoiceData\": [\n {\n \"billId\": 54323\n }\n ],\n \"orderDescription\": \"Office Supplies\"\n}") .asString(); ``` ```php CheckPayout request('POST', 'https://api-sandbox.payabli.com/api/MoneyOut/authorize', [ 'body' => '{ "entryPoint": "48acde49", "paymentMethod": { "method": "check" }, "paymentDetails": { "checkNumber": "10001", "totalAmount": 1500 }, "vendorData": { "vendorNumber": "7895433" }, "invoiceData": [ { "billId": 54323 } ], "orderDescription": "Office Supplies" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CheckPayout import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "48acde49", "paymentMethod": ["method": "check"], "paymentDetails": [ "checkNumber": "10001", "totalAmount": 1500 ], "vendorData": ["vendorNumber": "7895433"], "invoiceData": [["billId": 54323]], "orderDescription": "Office Supplies" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/authorize")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript AddVendor import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.authorizeOut({ body: { entryPoint: "47ced57b", paymentMethod: { method: "ach", achHolder: "John Doe", achRouting: "011401533", achAccount: "123456789", achAccountType: "checking", achHolderType: "business", }, paymentDetails: { totalAmount: 978.32, }, vendorData: { vendorNumber: "Vendor3800638299609471", name1: "Heritage Pro Company", name2: "", ein: "473771889", phone: "7868342364", email: "contact570@heritagepro.com", address1: "478 Mittie Roads", city: "Jakubowskifield", state: "WI", zip: "45993", country: "US", mcc: "0763", contacts: [ { contactEmail: "Mandy65@heritagepro.com", contactName: "Dax", contactPhone: "996-325-5420 x31028", }, ], vendorStatus: 1, remitAddress1: "727 Terrell Streets", remitAddress2: "Apt. 773", remitCity: "South Nicholeside", remitState: "ID", remitZip: "72951-9790", remitCountry: "US", locationCode: "tpa", }, invoiceData: [ { invoiceNumber: "VI3BvwTG", netAmount: "1", invoiceDate: "2026-09-03", dueDate: "2026-11-04", comments: "Building Repairs - Community event setup (System updates)", }, ], }, }); } main(); ``` ```python AddVendor from payabli import payabli, Contacts from payabli.money_out_types import AuthorizePaymentMethod, RequestOutAuthorizePaymentDetails, RequestOutAuthorizeVendorData, RequestOutAuthorizeInvoiceData import datetime client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.authorize_out( entry_point="47ced57b", payment_method=AuthorizePaymentMethod( method="ach", ach_holder="John Doe", ach_routing="011401533", ach_account="123456789", ach_account_type="checking", ach_holder_type="business", ), payment_details=RequestOutAuthorizePaymentDetails( total_amount=978.32, ), vendor_data=RequestOutAuthorizeVendorData( vendor_number="Vendor3800638299609471", name_1="Heritage Pro Company", name_2="", ein="473771889", phone="7868342364", email="contact570@heritagepro.com", address_1="478 Mittie Roads", city="Jakubowskifield", state="WI", zip="45993", country="US", mcc="0763", contacts=[ Contacts( contact_email="Mandy65@heritagepro.com", contact_name="Dax", contact_phone="996-325-5420 x31028", ) ], vendor_status=1, remit_address_1="727 Terrell Streets", remit_address_2="Apt. 773", remit_city="South Nicholeside", remit_state="ID", remit_zip="72951-9790", remit_country="US", location_code="tpa", ), invoice_data=[ RequestOutAuthorizeInvoiceData( invoice_number="VI3BvwTG", net_amount="1", invoice_date=datetime.date.fromisoformat("2026-09-03"), due_date=datetime.date.fromisoformat("2026-11-04"), comments="Building Repairs - Community event setup (System updates)", ) ], ) ``` ```csharp AddVendor using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; using System; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.AuthorizeOutAsync( new MoneyOutTypesRequestOutAuthorize { Body = new AuthorizePayoutBody { EntryPoint = "47ced57b", PaymentMethod = new AuthorizePaymentMethod { Method = "ach", AchHolder = "John Doe", AchRouting = "011401533", AchAccount = "123456789", AchAccountType = "checking", AchHolderType = AchHolderType.Business }, PaymentDetails = new RequestOutAuthorizePaymentDetails { TotalAmount = 978.32 }, VendorData = new RequestOutAuthorizeVendorData { VendorNumber = "Vendor3800638299609471", Name1 = "Heritage Pro Company", Name2 = "", Ein = "473771889", Phone = "7868342364", Email = "contact570@heritagepro.com", Address1 = "478 Mittie Roads", City = "Jakubowskifield", State = "WI", Zip = "45993", Country = "US", Mcc = "0763", Contacts = new List(){ new Contacts { ContactEmail = "Mandy65@heritagepro.com", ContactName = "Dax", ContactPhone = "996-325-5420 x31028" }, } , VendorStatus = 1, RemitAddress1 = "727 Terrell Streets", RemitAddress2 = "Apt. 773", RemitCity = "South Nicholeside", RemitState = "ID", RemitZip = "72951-9790", RemitCountry = "US", LocationCode = "tpa" }, InvoiceData = new List(){ new RequestOutAuthorizeInvoiceData { InvoiceNumber = "VI3BvwTG", NetAmount = "1", InvoiceDate = DateOnly.Parse("2026-09-03"), DueDate = DateOnly.Parse("2026-11-04"), Comments = "Building Repairs - Community event setup (System updates)" }, } } } ); } } ``` ```go AddVendor package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/authorize" payload := strings.NewReader("{\n \"entryPoint\": \"47ced57b\",\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"achHolder\": \"John Doe\",\n \"achRouting\": \"011401533\",\n \"achAccount\": \"123456789\",\n \"achAccountType\": \"checking\",\n \"achHolderType\": \"business\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 978.32\n },\n \"vendorData\": {\n \"vendorNumber\": \"Vendor3800638299609471\",\n \"name1\": \"Heritage Pro Company\",\n \"name2\": \"\",\n \"ein\": \"473771889\",\n \"phone\": \"7868342364\",\n \"email\": \"contact570@heritagepro.com\",\n \"address1\": \"478 Mittie Roads\",\n \"city\": \"Jakubowskifield\",\n \"state\": \"WI\",\n \"zip\": \"45993\",\n \"country\": \"US\",\n \"mcc\": \"0763\",\n \"contacts\": [\n {\n \"contactEmail\": \"Mandy65@heritagepro.com\",\n \"contactName\": \"Dax\",\n \"contactPhone\": \"996-325-5420 x31028\"\n }\n ],\n \"vendorStatus\": 1,\n \"remitAddress1\": \"727 Terrell Streets\",\n \"remitAddress2\": \"Apt. 773\",\n \"remitCity\": \"South Nicholeside\",\n \"remitState\": \"ID\",\n \"remitZip\": \"72951-9790\",\n \"remitCountry\": \"US\",\n \"locationCode\": \"tpa\"\n },\n \"invoiceData\": [\n {\n \"invoiceNumber\": \"VI3BvwTG\",\n \"netAmount\": \"1\",\n \"invoiceDate\": \"2026-09-03\",\n \"dueDate\": \"2026-11-04\",\n \"comments\": \"Building Repairs - Community event setup (System updates)\"\n }\n ]\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby AddVendor require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/authorize") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"47ced57b\",\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"achHolder\": \"John Doe\",\n \"achRouting\": \"011401533\",\n \"achAccount\": \"123456789\",\n \"achAccountType\": \"checking\",\n \"achHolderType\": \"business\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 978.32\n },\n \"vendorData\": {\n \"vendorNumber\": \"Vendor3800638299609471\",\n \"name1\": \"Heritage Pro Company\",\n \"name2\": \"\",\n \"ein\": \"473771889\",\n \"phone\": \"7868342364\",\n \"email\": \"contact570@heritagepro.com\",\n \"address1\": \"478 Mittie Roads\",\n \"city\": \"Jakubowskifield\",\n \"state\": \"WI\",\n \"zip\": \"45993\",\n \"country\": \"US\",\n \"mcc\": \"0763\",\n \"contacts\": [\n {\n \"contactEmail\": \"Mandy65@heritagepro.com\",\n \"contactName\": \"Dax\",\n \"contactPhone\": \"996-325-5420 x31028\"\n }\n ],\n \"vendorStatus\": 1,\n \"remitAddress1\": \"727 Terrell Streets\",\n \"remitAddress2\": \"Apt. 773\",\n \"remitCity\": \"South Nicholeside\",\n \"remitState\": \"ID\",\n \"remitZip\": \"72951-9790\",\n \"remitCountry\": \"US\",\n \"locationCode\": \"tpa\"\n },\n \"invoiceData\": [\n {\n \"invoiceNumber\": \"VI3BvwTG\",\n \"netAmount\": \"1\",\n \"invoiceDate\": \"2026-09-03\",\n \"dueDate\": \"2026-11-04\",\n \"comments\": \"Building Repairs - Community event setup (System updates)\"\n }\n ]\n}" response = http.request(request) puts response.read_body ``` ```java AddVendor import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyOut/authorize") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"47ced57b\",\n \"paymentMethod\": {\n \"method\": \"ach\",\n \"achHolder\": \"John Doe\",\n \"achRouting\": \"011401533\",\n \"achAccount\": \"123456789\",\n \"achAccountType\": \"checking\",\n \"achHolderType\": \"business\"\n },\n \"paymentDetails\": {\n \"totalAmount\": 978.32\n },\n \"vendorData\": {\n \"vendorNumber\": \"Vendor3800638299609471\",\n \"name1\": \"Heritage Pro Company\",\n \"name2\": \"\",\n \"ein\": \"473771889\",\n \"phone\": \"7868342364\",\n \"email\": \"contact570@heritagepro.com\",\n \"address1\": \"478 Mittie Roads\",\n \"city\": \"Jakubowskifield\",\n \"state\": \"WI\",\n \"zip\": \"45993\",\n \"country\": \"US\",\n \"mcc\": \"0763\",\n \"contacts\": [\n {\n \"contactEmail\": \"Mandy65@heritagepro.com\",\n \"contactName\": \"Dax\",\n \"contactPhone\": \"996-325-5420 x31028\"\n }\n ],\n \"vendorStatus\": 1,\n \"remitAddress1\": \"727 Terrell Streets\",\n \"remitAddress2\": \"Apt. 773\",\n \"remitCity\": \"South Nicholeside\",\n \"remitState\": \"ID\",\n \"remitZip\": \"72951-9790\",\n \"remitCountry\": \"US\",\n \"locationCode\": \"tpa\"\n },\n \"invoiceData\": [\n {\n \"invoiceNumber\": \"VI3BvwTG\",\n \"netAmount\": \"1\",\n \"invoiceDate\": \"2026-09-03\",\n \"dueDate\": \"2026-11-04\",\n \"comments\": \"Building Repairs - Community event setup (System updates)\"\n }\n ]\n}") .asString(); ``` ```php AddVendor request('POST', 'https://api-sandbox.payabli.com/api/MoneyOut/authorize', [ 'body' => '{ "entryPoint": "47ced57b", "paymentMethod": { "method": "ach", "achHolder": "John Doe", "achRouting": "011401533", "achAccount": "123456789", "achAccountType": "checking", "achHolderType": "business" }, "paymentDetails": { "totalAmount": 978.32 }, "vendorData": { "vendorNumber": "Vendor3800638299609471", "name1": "Heritage Pro Company", "name2": "", "ein": "473771889", "phone": "7868342364", "email": "contact570@heritagepro.com", "address1": "478 Mittie Roads", "city": "Jakubowskifield", "state": "WI", "zip": "45993", "country": "US", "mcc": "0763", "contacts": [ { "contactEmail": "Mandy65@heritagepro.com", "contactName": "Dax", "contactPhone": "996-325-5420 x31028" } ], "vendorStatus": 1, "remitAddress1": "727 Terrell Streets", "remitAddress2": "Apt. 773", "remitCity": "South Nicholeside", "remitState": "ID", "remitZip": "72951-9790", "remitCountry": "US", "locationCode": "tpa" }, "invoiceData": [ { "invoiceNumber": "VI3BvwTG", "netAmount": "1", "invoiceDate": "2026-09-03", "dueDate": "2026-11-04", "comments": "Building Repairs - Community event setup (System updates)" } ] }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift AddVendor import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "47ced57b", "paymentMethod": [ "method": "ach", "achHolder": "John Doe", "achRouting": "011401533", "achAccount": "123456789", "achAccountType": "checking", "achHolderType": "business" ], "paymentDetails": ["totalAmount": 978.32], "vendorData": [ "vendorNumber": "Vendor3800638299609471", "name1": "Heritage Pro Company", "name2": "", "ein": "473771889", "phone": "7868342364", "email": "contact570@heritagepro.com", "address1": "478 Mittie Roads", "city": "Jakubowskifield", "state": "WI", "zip": "45993", "country": "US", "mcc": "0763", "contacts": [ [ "contactEmail": "Mandy65@heritagepro.com", "contactName": "Dax", "contactPhone": "996-325-5420 x31028" ] ], "vendorStatus": 1, "remitAddress1": "727 Terrell Streets", "remitAddress2": "Apt. 773", "remitCity": "South Nicholeside", "remitState": "ID", "remitZip": "72951-9790", "remitCountry": "US", "locationCode": "tpa" ], "invoiceData": [ [ "invoiceNumber": "VI3BvwTG", "netAmount": "1", "invoiceDate": "2026-09-03", "dueDate": "2026-11-04", "comments": "Building Repairs - Community event setup (System updates)" ] ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/authorize")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Capture payout GET https://api-sandbox.payabli.com/api/MoneyOut/capture/{referenceId} Captures a single authorized payout transaction by ID. Reference: https://docs.payabli.com/developers/api-reference/moneyout/capture-an-authorized-payout-transaction ## SDK Code Examples ```typescript CapturePayout import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.captureOut("129-219", {}); } main(); ``` ```python CapturePayout from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.capture_out( reference_id="129-219", ) ``` ```csharp CapturePayout using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.CaptureOutAsync( "129-219", new CaptureOutRequest() ); } } ``` ```go CapturePayout package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/capture/129-219" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CapturePayout require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/capture/129-219") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java CapturePayout import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyOut/capture/129-219") .header("requestToken", "") .asString(); ``` ```php CapturePayout request('GET', 'https://api-sandbox.payabli.com/api/MoneyOut/capture/129-219', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CapturePayout import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/capture/129-219")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Capture list of payouts POST https://api-sandbox.payabli.com/api/MoneyOut/captureAll Content-Type: application/json Captures an array of authorized payout transactions for settlement. The maximum number of transactions that can be captured in a single request is 500. Reference: https://docs.payabli.com/developers/api-reference/moneyout/capture-a-list-of-authorized-payout-transactions ## SDK Code Examples ```typescript CaptureAll import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.captureAllOut({ body: [ "2-29", "2-28", "2-27", ], }); } main(); ``` ```python CaptureAll from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.capture_all_out( request=[ "2-29", "2-28", "2-27" ], ) ``` ```csharp CaptureAll using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.CaptureAllOutAsync( new CaptureAllOutRequest { Body = new List(){ "2-29", "2-28", "2-27", } } ); } } ``` ```go CaptureAll package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/captureAll" payload := strings.NewReader("[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CaptureAll require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/captureAll") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]" response = http.request(request) puts response.read_body ``` ```java CaptureAll import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyOut/captureAll") .header("requestToken", "") .header("Content-Type", "application/json") .body("[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]") .asString(); ``` ```php CaptureAll request('POST', 'https://api-sandbox.payabli.com/api/MoneyOut/captureAll', [ 'body' => '[ "2-29", "2-28", "2-27" ]', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CaptureAll import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["2-29", "2-28", "2-27"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/captureAll")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Cancel payout DELETE https://api-sandbox.payabli.com/api/MoneyOut/cancel/{referenceId} Cancel a payout transaction by ID. Reference: https://docs.payabli.com/developers/api-reference/moneyout/cancel-a-payout-transaction ## SDK Code Examples ```typescript CancelPayout import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.cancelOutDelete("129-219"); } main(); ``` ```python CancelPayout from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.cancel_out_delete( reference_id="129-219", ) ``` ```csharp CancelPayout using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.CancelOutDeleteAsync( "129-219" ); } } ``` ```go CancelPayout package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CancelPayout require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java CancelPayout import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219") .header("requestToken", "") .asString(); ``` ```php CancelPayout request('DELETE', 'https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CancelPayout import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Cancel payout (deprecated) GET https://api-sandbox.payabli.com/api/MoneyOut/cancel/{referenceId} Cancel a payout transaction by ID. Reference: https://docs.payabli.com/developers/api-reference/moneyout/cancel-a-payout-transaction-get ## SDK Code Examples ```typescript CancelPayout import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.cancelOutGet("129-219"); } main(); ``` ```python CancelPayout from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.cancel_out_get( reference_id="129-219", ) ``` ```csharp CancelPayout using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.CancelOutGetAsync( "129-219" ); } } ``` ```go CancelPayout package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CancelPayout require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java CancelPayout import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219") .header("requestToken", "") .asString(); ``` ```php CancelPayout request('GET', 'https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CancelPayout import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/cancel/129-219")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Cancel list of payouts POST https://api-sandbox.payabli.com/api/MoneyOut/cancelAll Content-Type: application/json Cancels an array of payout transactions. Reference: https://docs.payabli.com/developers/api-reference/moneyout/cancel-list-of-payout-transactions ## SDK Code Examples ```typescript CancelAll import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.cancelAllOut([ "2-29", "2-28", "2-27", ]); } main(); ``` ```python CancelAll from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.cancel_all_out( request=[ "2-29", "2-28", "2-27" ], ) ``` ```csharp CancelAll using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.CancelAllOutAsync( new List(){ "2-29", "2-28", "2-27", } ); } } ``` ```go CancelAll package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/cancelAll" payload := strings.NewReader("[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CancelAll require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/cancelAll") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]" response = http.request(request) puts response.read_body ``` ```java CancelAll import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyOut/cancelAll") .header("requestToken", "") .header("Content-Type", "application/json") .body("[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]") .asString(); ``` ```php CancelAll request('POST', 'https://api-sandbox.payabli.com/api/MoneyOut/cancelAll', [ 'body' => '[ "2-29", "2-28", "2-27" ]', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CancelAll import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["2-29", "2-28", "2-27"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/cancelAll")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get payout details GET https://api-sandbox.payabli.com/api/MoneyOut/details/{transId} Returns details for a processed money out transaction. Reference: https://docs.payabli.com/developers/api-reference/moneyout/get-details-for-a-processed-payout-transaction ## SDK Code Examples ```typescript AuthorizedTransaction import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.payoutDetails("45-as456777hhhhhhhhhh77777777-324"); } main(); ``` ```python AuthorizedTransaction from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.payout_details( trans_id="45-as456777hhhhhhhhhh77777777-324", ) ``` ```csharp AuthorizedTransaction using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.PayoutDetailsAsync( "45-as456777hhhhhhhhhh77777777-324" ); } } ``` ```go AuthorizedTransaction package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby AuthorizedTransaction require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java AuthorizedTransaction import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324") .header("requestToken", "") .asString(); ``` ```php AuthorizedTransaction request('GET', 'https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift AuthorizedTransaction import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript AuthorizeAndCapturedTransaction import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.payoutDetails("45-as456777hhhhhhhhhh77777777-324"); } main(); ``` ```python AuthorizeAndCapturedTransaction from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.payout_details( trans_id="45-as456777hhhhhhhhhh77777777-324", ) ``` ```csharp AuthorizeAndCapturedTransaction using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.PayoutDetailsAsync( "45-as456777hhhhhhhhhh77777777-324" ); } } ``` ```go AuthorizeAndCapturedTransaction package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby AuthorizeAndCapturedTransaction require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java AuthorizeAndCapturedTransaction import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324") .header("requestToken", "") .asString(); ``` ```php AuthorizeAndCapturedTransaction request('GET', 'https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift AuthorizeAndCapturedTransaction import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/details/45-as456777hhhhhhhhhh77777777-324")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get virtual card details GET https://api-sandbox.payabli.com/api/MoneyOut/vcard/{cardToken} Retrieves vCard details for a single card in an entrypoint. Reference: https://docs.payabli.com/developers/api-reference/moneyout/get-vcard ## SDK Code Examples ```typescript GetVCard import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.vCardGet("20230403315245421165"); } main(); ``` ```python GetVCard from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.v_card_get( card_token="20230403315245421165", ) ``` ```csharp GetVCard using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.VCardGetAsync( "20230403315245421165" ); } } ``` ```go GetVCard package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/vcard/20230403315245421165" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetVCard require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/vcard/20230403315245421165") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetVCard import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyOut/vcard/20230403315245421165") .header("requestToken", "") .asString(); ``` ```php GetVCard request('GET', 'https://api-sandbox.payabli.com/api/MoneyOut/vcard/20230403315245421165', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetVCard import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/vcard/20230403315245421165")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Send virtual card link POST https://api-sandbox.payabli.com/api/vcard/send-card-link Content-Type: application/json Sends a virtual card link via email to the vendor associated with the `transId`. Reference: https://docs.payabli.com/developers/api-reference/moneyout/send-vcard-link ## SDK Code Examples ```typescript SendVCardLink import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.sendVCardLink({ transId: "01K33Z6YQZ6GD5QVKZ856MJBSC", }); } main(); ``` ```python SendVCardLink from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.send_v_card_link( trans_id="01K33Z6YQZ6GD5QVKZ856MJBSC", ) ``` ```csharp SendVCardLink using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.SendVCardLinkAsync( new SendVCardLinkRequest { TransId = "01K33Z6YQZ6GD5QVKZ856MJBSC" } ); } } ``` ```go SendVCardLink package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/vcard/send-card-link" payload := strings.NewReader("{\n \"transId\": \"01K33Z6YQZ6GD5QVKZ856MJBSC\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby SendVCardLink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/vcard/send-card-link") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"transId\": \"01K33Z6YQZ6GD5QVKZ856MJBSC\"\n}" response = http.request(request) puts response.read_body ``` ```java SendVCardLink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/vcard/send-card-link") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"transId\": \"01K33Z6YQZ6GD5QVKZ856MJBSC\"\n}") .asString(); ``` ```php SendVCardLink request('POST', 'https://api-sandbox.payabli.com/api/vcard/send-card-link', [ 'body' => '{ "transId": "01K33Z6YQZ6GD5QVKZ856MJBSC" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift SendVCardLink import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["transId": "01K33Z6YQZ6GD5QVKZ856MJBSC"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/vcard/send-card-link")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get payout check image GET https://api-sandbox.payabli.com/api/MoneyOut/checkimage/{assetName} Retrieve the image of a check associated with a processed transaction. The check image is returned in the response body as a base64-encoded string. The check image is only available for payouts that have been processed. Reference: https://docs.payabli.com/developers/api-reference/moneyout/get-payout-check-image ## SDK Code Examples ```typescript GetCheckImage import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.getCheckImage("check133832686289732320_01JKBNZ5P32JPTZY8XXXX000000.pdf"); } main(); ``` ```python GetCheckImage from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.get_check_image( asset_name="check133832686289732320_01JKBNZ5P32JPTZY8XXXX000000.pdf", ) ``` ```csharp GetCheckImage using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.GetCheckImageAsync( "check133832686289732320_01JKBNZ5P32JPTZY8XXXX000000.pdf" ); } } ``` ```go GetCheckImage package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/checkimage/check133832686289732320_01JKBNZ5P32JPTZY8XXXX000000.pdf" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetCheckImage require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/checkimage/check133832686289732320_01JKBNZ5P32JPTZY8XXXX000000.pdf") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetCheckImage import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/MoneyOut/checkimage/check133832686289732320_01JKBNZ5P32JPTZY8XXXX000000.pdf") .header("requestToken", "") .asString(); ``` ```php GetCheckImage request('GET', 'https://api-sandbox.payabli.com/api/MoneyOut/checkimage/check133832686289732320_01JKBNZ5P32JPTZY8XXXX000000.pdf', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetCheckImage import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/checkimage/check133832686289732320_01JKBNZ5P32JPTZY8XXXX000000.pdf")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update check payment status PATCH https://api-sandbox.payabli.com/api/MoneyOut/status/{transId}/{checkPaymentStatus} Updates the status of a processed check payment transaction. This endpoint handles the status transition, updates related bills, creates audit events, and triggers notifications. The transaction must meet all of the following criteria: - **Status**: Must be in Processing or Processed status. - **Payment method**: Must be a check payment method. ### Allowed status values | Value | Status | Description | |-------|--------|-------------| | `0` | Cancelled/Voided | Cancels the check transaction. Reverts associated bills to their previous state (Approved or Active), creates "Cancelled" events, and sends a `payout_transaction_voidedcancelled` notification if the notification is enabled. | | `5` | Paid | Marks the check transaction as paid. Updates associated bills to "Paid" status, creates "Paid" events, and sends a `payout_transaction_paid` notification if the notification is enabled. | Reference: https://docs.payabli.com/developers/api-reference/moneyout/update-check-payment-status ## SDK Code Examples ```typescript MarkCheckAsPaid import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.updateCheckPaymentStatus("TRANS123456", "5"); } main(); ``` ```python MarkCheckAsPaid from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.update_check_payment_status( trans_id="TRANS123456", check_payment_status="5", ) ``` ```csharp MarkCheckAsPaid using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.UpdateCheckPaymentStatusAsync( "TRANS123456", AllowedCheckPaymentStatus.Paid ); } } ``` ```go MarkCheckAsPaid package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/5" req, _ := http.NewRequest("PATCH", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby MarkCheckAsPaid require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/5") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java MarkCheckAsPaid import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/5") .header("requestToken", "") .asString(); ``` ```php MarkCheckAsPaid request('PATCH', 'https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/5', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift MarkCheckAsPaid import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/5")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript CancelCheck import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.moneyOut.updateCheckPaymentStatus("TRANS123456", "0"); } main(); ``` ```python CancelCheck from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.money_out.update_check_payment_status( trans_id="TRANS123456", check_payment_status="0", ) ``` ```csharp CancelCheck using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.MoneyOut.UpdateCheckPaymentStatusAsync( "TRANS123456", AllowedCheckPaymentStatus.Cancelled ); } } ``` ```go CancelCheck package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/0" req, _ := http.NewRequest("PATCH", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CancelCheck require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/0") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java CancelCheck import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/0") .header("requestToken", "") .asString(); ``` ```php CancelCheck request('PATCH', 'https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/0', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CancelCheck import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/status/TRANS123456/0")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List payout batches for paypoint GET https://api-sandbox.payabli.com/api/Query/batchesOut/{entry} Retrieve a list of MoneyOut batches for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-moneyout-batches-for-an-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listBatchesOut("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_batches_out( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListBatchesOutAsync( "8cfec329267", new ListBatchesOutRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/batchesOut/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/batchesOut/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/batchesOut/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/batchesOut/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/batchesOut/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List payout batches for org GET https://api-sandbox.payabli.com/api/Query/batchesOut/org/{orgId} Retrieve a list of MoneyOut batches for an org. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-moneyout-batches-for-an-org ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listBatchesOutOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_batches_out_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListBatchesOutOrgAsync( 123, new ListBatchesOutOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/batchesOut/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/batchesOut/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/batchesOut/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/batchesOut/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/batchesOut/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List payouts by paypoint GET https://api-sandbox.payabli.com/api/Query/payouts/{entry} Retrieves a list of money out transactions (payouts) for a paypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-payouts-for-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listPayout("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_payout( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListPayoutAsync( "8cfec329267", new ListPayoutRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/payouts/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/payouts/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/payouts/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/payouts/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/payouts/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List payouts by org GET https://api-sandbox.payabli.com/api/Query/payouts/org/{orgId} Retrieves a list of money out transactions (payouts) for an organization. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-payouts-for-organization ## SDK Code Examples ```typescript ListPayoutOrgExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listPayoutOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python ListPayoutOrgExample from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_payout_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp ListPayoutOrgExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListPayoutOrgAsync( 123, new ListPayoutOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go ListPayoutOrgExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/payouts/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListPayoutOrgExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/payouts/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java ListPayoutOrgExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/payouts/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php ListPayoutOrgExample request('GET', 'https://api-sandbox.payabli.com/api/Query/payouts/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ListPayoutOrgExample import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/payouts/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List vcards by paypoint GET https://api-sandbox.payabli.com/api/Query/vcards/{entry} Retrieve a list of vcards (virtual credit cards) issued for an entrypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-virtual-cards-for-entrypoint ## SDK Code Examples ```typescript ListVcardsPaypoint import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listVcards("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python ListVcardsPaypoint from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_vcards( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp ListVcardsPaypoint using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListVcardsAsync( "8cfec329267", new ListVcardsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go ListVcardsPaypoint package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/vcards/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListVcardsPaypoint require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/vcards/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java ListVcardsPaypoint import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/vcards/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php ListVcardsPaypoint request('GET', 'https://api-sandbox.payabli.com/api/Query/vcards/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ListVcardsPaypoint import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/vcards/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List vcards by org GET https://api-sandbox.payabli.com/api/Query/vcards/org/{orgId} Retrieve a list of vcards (virtual credit cards) issued for an organization. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-virtual-cards-for-organization ## SDK Code Examples ```typescript ListVCardsOrg import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listVcardsOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python ListVCardsOrg from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_vcards_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp ListVCardsOrg using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListVcardsOrgAsync( 123, new ListVcardsOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go ListVCardsOrg package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/vcards/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListVCardsOrg require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/vcards/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java ListVCardsOrg import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/vcards/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php ListVCardsOrg request('GET', 'https://api-sandbox.payabli.com/api/Query/vcards/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ListVCardsOrg import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/vcards/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get list of outbound transfers for an organization GET https://api-sandbox.payabli.com/api/Query/transfersOut/org/{orgId} Retrieve a list of outbound transfers for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-transfers-out-for-organization ## SDK Code Examples ```typescript ListTransfersOutOrgExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient(); await client.query.listTransfersOutOrg(77, { fromRecord: 0, limitRecord: 20, }); } main(); ``` ```python ListTransfersOutOrgExample from payabli import payabli client = payabli() client.query.list_transfers_out_org( org_id=77, from_record=0, limit_record=20, ) ``` ```csharp ListTransfersOutOrgExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient(); await client.Query.ListTransfersOutOrgAsync( 77, new ListTransfersOutOrgRequest { FromRecord = 0, LimitRecord = 20 } ); } } ``` ```go ListTransfersOutOrgExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/transfersOut/org/77?fromRecord=0&limitRecord=20" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListTransfersOutOrgExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/transfersOut/org/77?fromRecord=0&limitRecord=20") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) response = http.request(request) puts response.read_body ``` ```java ListTransfersOutOrgExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/transfersOut/org/77?fromRecord=0&limitRecord=20") .asString(); ``` ```php ListTransfersOutOrgExample request('GET', 'https://api-sandbox.payabli.com/api/Query/transfersOut/org/77?fromRecord=0&limitRecord=20'); echo $response->getBody(); ``` ```swift ListTransfersOutOrgExample import Foundation let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/transfersOut/org/77?fromRecord=0&limitRecord=20")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get list of outbound transfers for a paypoint GET https://api-sandbox.payabli.com/api/Query/transfersOut/{entry} Retrieve a list of outbound transfers for a paypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/query/get-list-of-transfers-out-for-entrypoint ## SDK Code Examples ```typescript ListTransfersOutPaypointExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient(); await client.query.listTransfersOutPaypoint("47cade237", { fromRecord: 0, limitRecord: 20, }); } main(); ``` ```python ListTransfersOutPaypointExample from payabli import payabli client = payabli() client.query.list_transfers_out_paypoint( entry="47cade237", from_record=0, limit_record=20, ) ``` ```csharp ListTransfersOutPaypointExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient(); await client.Query.ListTransfersOutPaypointAsync( "47cade237", new ListTransfersOutPaypointRequest { FromRecord = 0, LimitRecord = 20 } ); } } ``` ```go ListTransfersOutPaypointExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/transfersOut/47cade237?fromRecord=0&limitRecord=20" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListTransfersOutPaypointExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/transfersOut/47cade237?fromRecord=0&limitRecord=20") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) response = http.request(request) puts response.read_body ``` ```java ListTransfersOutPaypointExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/transfersOut/47cade237?fromRecord=0&limitRecord=20") .asString(); ``` ```php ListTransfersOutPaypointExample request('GET', 'https://api-sandbox.payabli.com/api/Query/transfersOut/47cade237?fromRecord=0&limitRecord=20'); echo $response->getBody(); ``` ```swift ListTransfersOutPaypointExample import Foundation let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/transfersOut/47cade237?fromRecord=0&limitRecord=20")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get outbound transfer details GET https://api-sandbox.payabli.com/api/Query/transferDetailsOut/{entry}/{transferId} Retrieve details for a specific outbound transfer. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/query/get-transfer-out-details ## SDK Code Examples ```typescript ListTransferDetailsOutExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient(); await client.query.listTransferDetailsOut("47ace2b25", 4521, { fromRecord: 0, limitRecord: 20, }); } main(); ``` ```python ListTransferDetailsOutExample from payabli import payabli client = payabli() client.query.list_transfer_details_out( entry="47ace2b25", transfer_id=4521, from_record=0, limit_record=20, ) ``` ```csharp ListTransferDetailsOutExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient(); await client.Query.ListTransferDetailsOutAsync( "47ace2b25", 4521, new ListTransferDetailsOutRequest { FromRecord = 0, LimitRecord = 20 } ); } } ``` ```go ListTransferDetailsOutExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/transferDetailsOut/47ace2b25/4521?fromRecord=0&limitRecord=20" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListTransferDetailsOutExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/transferDetailsOut/47ace2b25/4521?fromRecord=0&limitRecord=20") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) response = http.request(request) puts response.read_body ``` ```java ListTransferDetailsOutExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/transferDetailsOut/47ace2b25/4521?fromRecord=0&limitRecord=20") .asString(); ``` ```php ListTransferDetailsOutExample request('GET', 'https://api-sandbox.payabli.com/api/Query/transferDetailsOut/47ace2b25/4521?fromRecord=0&limitRecord=20'); echo $response->getBody(); ``` ```swift ListTransferDetailsOutExample import Foundation let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/transferDetailsOut/47ace2b25/4521?fromRecord=0&limitRecord=20")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export payouts by paypoint GET https://api-sandbox.payabli.com/api/Export/payouts/{format}/{entry} Export a list of payouts and their statuses for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-payouts-for-an-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportPayout("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_payout( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportPayoutAsync( ExportFormat1.Csv, "8cfec329267", new ExportPayoutRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/payouts/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/payouts/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/payouts/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/payouts/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/payouts/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export payouts by org GET https://api-sandbox.payabli.com/api/Export/payouts/{format}/org/{orgId} Export a list of payouts and their details for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-payouts-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportPayoutOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_payout_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportPayoutOrgAsync( ExportFormat1.Csv, 123, new ExportPayoutOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/payouts/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/payouts/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/payouts/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/payouts/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/payouts/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export payout batches by paypoint GET https://api-sandbox.payabli.com/api/Export/batchesOut/{format}/{entry} Export a list of money out batches for a paypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-batches-out-for-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportBatchesOut("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_batches_out( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportBatchesOutAsync( ExportFormat1.Csv, "8cfec329267", new ExportBatchesOutRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/batchesOut/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/batchesOut/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/batchesOut/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/batchesOut/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/batchesOut/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export payout batches by org GET https://api-sandbox.payabli.com/api/Export/batchesOut/{format}/org/{orgId} Export a list of money out batches for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/export/export-list-of-batches-out-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportBatchesOutOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_batches_out_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportBatchesOutOrgAsync( ExportFormat1.Csv, 123, new ExportBatchesOutOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/batchesOut/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/batchesOut/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/batchesOut/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/batchesOut/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/batchesOut/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create vendor POST https://api-sandbox.payabli.com/api/Vendor/single/{entry} Content-Type: application/json Creates a vendor in an entrypoint. Reference: https://docs.payabli.com/developers/api-reference/vendor/create-vendor ## SDK Code Examples ```typescript CreateVendor import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.vendor.addVendor("8cfec329267", { vendorNumber: "1234", address1: "123 Ocean Drive", address2: "Suite 400", billingData: { accountNumber: "123123123", bankAccountFunction: 0, bankAccountHolderName: "Gruzya Adventure Outfitters LLC", bankAccountHolderType: "Business", bankName: "Country Bank", id: 123, routingAccount: "123123123", typeAccount: "Checking", }, city: "Miami", contacts: [ { contactEmail: "example@email.com", contactName: "Herman Martinez", contactPhone: "3055550000", contactTitle: "Owner", }, ], country: "US", customerVendorAccount: "A-37622", ein: "12-3456789", email: "example@email.com", internalReferenceId: 123, locationCode: "MIA123", mcc: "7777", name1: "Herman's Coatings and Masonry", name2: "", payeeName1: "", payeeName2: "", paymentMethod: "managed", phone: "5555555555", remitAddress1: "123 Walnut Street", remitAddress2: "Suite 900", remitCity: "Miami", remitCountry: "US", remitState: "FL", remitZip: "31113", state: "FL", vendorStatus: 1, zip: "33139", }); } main(); ``` ```python CreateVendor from payabli import payabli, BillingData, Contacts client = payabli( api_key="YOUR_API_KEY_HERE", ) client.vendor.add_vendor( entry="8cfec329267", vendor_number="1234", address_1="123 Ocean Drive", address_2="Suite 400", billing_data=BillingData( account_number="123123123", bank_account_function=0, bank_account_holder_name="Gruzya Adventure Outfitters LLC", bank_account_holder_type="Business", bank_name="Country Bank", id=123, routing_account="123123123", type_account="Checking", ), city="Miami", contacts=[ Contacts( contact_email="example@email.com", contact_name="Herman Martinez", contact_phone="3055550000", contact_title="Owner", ) ], country="US", customer_vendor_account="A-37622", ein="12-3456789", email="example@email.com", internal_reference_id=123, location_code="MIA123", mcc="7777", name_1="Herman\'s Coatings and Masonry", name_2="", payee_name_1="", payee_name_2="", payment_method="managed", phone="5555555555", remit_address_1="123 Walnut Street", remit_address_2="Suite 900", remit_city="Miami", remit_country="US", remit_state="FL", remit_zip="31113", state="FL", vendor_status=1, zip="33139", ) ``` ```csharp CreateVendor using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Vendor.AddVendorAsync( "8cfec329267", new VendorData { VendorNumber = "1234", Address1 = "123 Ocean Drive", Address2 = "Suite 400", BillingData = new BillingData { AccountNumber = "123123123", BankAccountFunction = 0, BankAccountHolderName = "Gruzya Adventure Outfitters LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "Country Bank", Id = 123, RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking }, City = "Miami", Contacts = new List(){ new Contacts { ContactEmail = "example@email.com", ContactName = "Herman Martinez", ContactPhone = "3055550000", ContactTitle = "Owner" }, } , Country = "US", CustomerVendorAccount = "A-37622", Ein = "12-3456789", Email = "example@email.com", InternalReferenceId = 123L, LocationCode = "MIA123", Mcc = "7777", Name1 = "Herman's Coatings and Masonry", Name2 = "", PayeeName1 = "", PayeeName2 = "", PaymentMethod = "managed", Phone = "5555555555", RemitAddress1 = "123 Walnut Street", RemitAddress2 = "Suite 900", RemitCity = "Miami", RemitCountry = "US", RemitState = "FL", RemitZip = "31113", State = "FL", VendorStatus = 1, Zip = "33139" } ); } } ``` ```go CreateVendor package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Vendor/single/8cfec329267" payload := strings.NewReader("{\n \"vendorNumber\": \"1234\",\n \"address1\": \"123 Ocean Drive\",\n \"address2\": \"Suite 400\",\n \"billingData\": {\n \"accountNumber\": \"123123123\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Gruzya Adventure Outfitters LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"Country Bank\",\n \"id\": 123,\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\"\n },\n \"city\": \"Miami\",\n \"contacts\": [\n {\n \"contactEmail\": \"example@email.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"country\": \"US\",\n \"customerVendorAccount\": \"A-37622\",\n \"ein\": \"12-3456789\",\n \"email\": \"example@email.com\",\n \"internalReferenceId\": 123,\n \"locationCode\": \"MIA123\",\n \"mcc\": \"7777\",\n \"name1\": \"Herman's Coatings and Masonry\",\n \"name2\": \"\",\n \"payeeName1\": \"\",\n \"payeeName2\": \"\",\n \"paymentMethod\": \"managed\",\n \"phone\": \"5555555555\",\n \"remitAddress1\": \"123 Walnut Street\",\n \"remitAddress2\": \"Suite 900\",\n \"remitCity\": \"Miami\",\n \"remitCountry\": \"US\",\n \"remitState\": \"FL\",\n \"remitZip\": \"31113\",\n \"state\": \"FL\",\n \"vendorStatus\": 1,\n \"zip\": \"33139\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CreateVendor require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Vendor/single/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"vendorNumber\": \"1234\",\n \"address1\": \"123 Ocean Drive\",\n \"address2\": \"Suite 400\",\n \"billingData\": {\n \"accountNumber\": \"123123123\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Gruzya Adventure Outfitters LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"Country Bank\",\n \"id\": 123,\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\"\n },\n \"city\": \"Miami\",\n \"contacts\": [\n {\n \"contactEmail\": \"example@email.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"country\": \"US\",\n \"customerVendorAccount\": \"A-37622\",\n \"ein\": \"12-3456789\",\n \"email\": \"example@email.com\",\n \"internalReferenceId\": 123,\n \"locationCode\": \"MIA123\",\n \"mcc\": \"7777\",\n \"name1\": \"Herman's Coatings and Masonry\",\n \"name2\": \"\",\n \"payeeName1\": \"\",\n \"payeeName2\": \"\",\n \"paymentMethod\": \"managed\",\n \"phone\": \"5555555555\",\n \"remitAddress1\": \"123 Walnut Street\",\n \"remitAddress2\": \"Suite 900\",\n \"remitCity\": \"Miami\",\n \"remitCountry\": \"US\",\n \"remitState\": \"FL\",\n \"remitZip\": \"31113\",\n \"state\": \"FL\",\n \"vendorStatus\": 1,\n \"zip\": \"33139\"\n}" response = http.request(request) puts response.read_body ``` ```java CreateVendor import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Vendor/single/8cfec329267") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"vendorNumber\": \"1234\",\n \"address1\": \"123 Ocean Drive\",\n \"address2\": \"Suite 400\",\n \"billingData\": {\n \"accountNumber\": \"123123123\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Gruzya Adventure Outfitters LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"Country Bank\",\n \"id\": 123,\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\"\n },\n \"city\": \"Miami\",\n \"contacts\": [\n {\n \"contactEmail\": \"example@email.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"country\": \"US\",\n \"customerVendorAccount\": \"A-37622\",\n \"ein\": \"12-3456789\",\n \"email\": \"example@email.com\",\n \"internalReferenceId\": 123,\n \"locationCode\": \"MIA123\",\n \"mcc\": \"7777\",\n \"name1\": \"Herman's Coatings and Masonry\",\n \"name2\": \"\",\n \"payeeName1\": \"\",\n \"payeeName2\": \"\",\n \"paymentMethod\": \"managed\",\n \"phone\": \"5555555555\",\n \"remitAddress1\": \"123 Walnut Street\",\n \"remitAddress2\": \"Suite 900\",\n \"remitCity\": \"Miami\",\n \"remitCountry\": \"US\",\n \"remitState\": \"FL\",\n \"remitZip\": \"31113\",\n \"state\": \"FL\",\n \"vendorStatus\": 1,\n \"zip\": \"33139\"\n}") .asString(); ``` ```php CreateVendor request('POST', 'https://api-sandbox.payabli.com/api/Vendor/single/8cfec329267', [ 'body' => '{ "vendorNumber": "1234", "address1": "123 Ocean Drive", "address2": "Suite 400", "billingData": { "accountNumber": "123123123", "bankAccountFunction": 0, "bankAccountHolderName": "Gruzya Adventure Outfitters LLC", "bankAccountHolderType": "Business", "bankName": "Country Bank", "id": 123, "routingAccount": "123123123", "typeAccount": "Checking" }, "city": "Miami", "contacts": [ { "contactEmail": "example@email.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" } ], "country": "US", "customerVendorAccount": "A-37622", "ein": "12-3456789", "email": "example@email.com", "internalReferenceId": 123, "locationCode": "MIA123", "mcc": "7777", "name1": "Herman\'s Coatings and Masonry", "name2": "", "payeeName1": "", "payeeName2": "", "paymentMethod": "managed", "phone": "5555555555", "remitAddress1": "123 Walnut Street", "remitAddress2": "Suite 900", "remitCity": "Miami", "remitCountry": "US", "remitState": "FL", "remitZip": "31113", "state": "FL", "vendorStatus": 1, "zip": "33139" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CreateVendor import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "vendorNumber": "1234", "address1": "123 Ocean Drive", "address2": "Suite 400", "billingData": [ "accountNumber": "123123123", "bankAccountFunction": 0, "bankAccountHolderName": "Gruzya Adventure Outfitters LLC", "bankAccountHolderType": "Business", "bankName": "Country Bank", "id": 123, "routingAccount": "123123123", "typeAccount": "Checking" ], "city": "Miami", "contacts": [ [ "contactEmail": "example@email.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" ] ], "country": "US", "customerVendorAccount": "A-37622", "ein": "12-3456789", "email": "example@email.com", "internalReferenceId": 123, "locationCode": "MIA123", "mcc": "7777", "name1": "Herman's Coatings and Masonry", "name2": "", "payeeName1": "", "payeeName2": "", "paymentMethod": "managed", "phone": "5555555555", "remitAddress1": "123 Walnut Street", "remitAddress2": "Suite 900", "remitCity": "Miami", "remitCountry": "US", "remitState": "FL", "remitZip": "31113", "state": "FL", "vendorStatus": 1, "zip": "33139" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Vendor/single/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get vendor GET https://api-sandbox.payabli.com/api/Vendor/{idVendor} Retrieves a vendor's details. Reference: https://docs.payabli.com/developers/api-reference/vendor/get-vendor ## SDK Code Examples ```typescript GetVendor import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.vendor.getVendor(1); } main(); ``` ```python GetVendor from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.vendor.get_vendor( id_vendor=1, ) ``` ```csharp GetVendor using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Vendor.GetVendorAsync( 1 ); } } ``` ```go GetVendor package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Vendor/1" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetVendor require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Vendor/1") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetVendor import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Vendor/1") .header("requestToken", "") .asString(); ``` ```php GetVendor request('GET', 'https://api-sandbox.payabli.com/api/Vendor/1', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetVendor import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Vendor/1")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update vendor PUT https://api-sandbox.payabli.com/api/Vendor/{idVendor} Content-Type: application/json Updates a vendor's information. Send only the fields you need to update. Reference: https://docs.payabli.com/developers/api-reference/vendor/update-vendor ## SDK Code Examples ```typescript Update `name1` field import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.vendor.editVendor(1, { name1: "Theodore's Janitorial", }); } main(); ``` ```python Update `name1` field from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.vendor.edit_vendor( id_vendor=1, name_1="Theodore\'s Janitorial", ) ``` ```csharp Update `name1` field using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Vendor.EditVendorAsync( 1, new VendorData { Name1 = "Theodore's Janitorial" } ); } } ``` ```go Update `name1` field package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Vendor/1" payload := strings.NewReader("{\n \"name1\": \"Theodore's Janitorial\"\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Update `name1` field require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Vendor/1") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"name1\": \"Theodore's Janitorial\"\n}" response = http.request(request) puts response.read_body ``` ```java Update `name1` field import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Vendor/1") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"name1\": \"Theodore's Janitorial\"\n}") .asString(); ``` ```php Update `name1` field request('PUT', 'https://api-sandbox.payabli.com/api/Vendor/1', [ 'body' => '{ "name1": "Theodore\'s Janitorial" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Update `name1` field import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["name1": "Theodore's Janitorial"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Vendor/1")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete vendor DELETE https://api-sandbox.payabli.com/api/Vendor/{idVendor} Delete a vendor. Reference: https://docs.payabli.com/developers/api-reference/vendor/delete-vendor ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.vendor.deleteVendor(1); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.vendor.delete_vendor( id_vendor=1, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Vendor.DeleteVendorAsync( 1 ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Vendor/1" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Vendor/1") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Vendor/1") .header("requestToken", "") .asString(); ``` ```php request('DELETE', 'https://api-sandbox.payabli.com/api/Vendor/1', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Vendor/1")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Import vendors POST https://api-sandbox.payabli.com/api/Import/vendorsForm/{entry} Content-Type: multipart/form-data Import a list of vendors from a CSV file. See the [Import Guide](/developers/developer-guides/entities-vendors#import-vendors) for more help and example files. Reference: https://docs.payabli.com/developers/api-reference/vendor/import-vendor ## SDK Code Examples ```typescript ImportVendor import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.import.importVendor("8cfec329267", ); } main(); ``` ```python ImportVendor from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.import_.import_vendor( entry="8cfec329267", file="example_file", ) ``` ```csharp ImportVendor using PayabliPayabliApi; using System.Threading.Tasks; using System.IO; using System.Text; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Import.ImportVendorAsync( "8cfec329267", new ImportVendorRequest { File = new FileParameter(){ Stream = new MemoryStream(Encoding.UTF8.GetBytes("[bytes]")) } } ); } } ``` ```go ImportVendor package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Import/vendorsForm/8cfec329267" payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"\"\r\nContent-Type: application/octet-stream\r\n\r\n\r\n-----011000010111000001101001--\r\n") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "multipart/form-data; boundary=---011000010111000001101001") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ImportVendor require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Import/vendorsForm/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'multipart/form-data; boundary=---011000010111000001101001' request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"\"\r\nContent-Type: application/octet-stream\r\n\r\n\r\n-----011000010111000001101001--\r\n" response = http.request(request) puts response.read_body ``` ```java ImportVendor import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Import/vendorsForm/8cfec329267") .header("requestToken", "") .header("Content-Type", "multipart/form-data; boundary=---011000010111000001101001") .body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"\"\r\nContent-Type: application/octet-stream\r\n\r\n\r\n-----011000010111000001101001--\r\n") .asString(); ``` ```php ImportVendor request('POST', 'https://api-sandbox.payabli.com/api/Import/vendorsForm/8cfec329267', [ 'multipart' => [ [ 'name' => 'file', 'filename' => '', 'contents' => null ] ] 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ImportVendor import Foundation let headers = [ "requestToken": "", "Content-Type": "multipart/form-data; boundary=---011000010111000001101001" ] let parameters = [ [ "name": "file", "fileName": "" ] ] let boundary = "---011000010111000001101001" var body = "" var error: NSError? = nil for param in parameters { let paramName = param["name"]! body += "--\(boundary)\r\n" body += "Content-Disposition:form-data; name=\"\(paramName)\"" if let filename = param["fileName"] { let contentType = param["content-type"]! let fileContent = String(contentsOfFile: filename, encoding: String.Encoding.utf8) if (error != nil) { print(error as Any) } body += "; filename=\"\(filename)\"\r\n" body += "Content-Type: \(contentType)\r\n\r\n" body += fileContent } else if let paramValue = param["value"] { body += "\r\n\r\n\(paramValue)" } } let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Import/vendorsForm/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List vendors by paypoint GET https://api-sandbox.payabli.com/api/Query/vendors/{entry} Retrieve a list of vendors for an entrypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/vendor/get-list-of-vendors-for-entrypoint ## SDK Code Examples ```typescript An example response for vendor queries import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listVendors("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python An example response for vendor queries from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_vendors( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp An example response for vendor queries using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListVendorsAsync( "8cfec329267", new ListVendorsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go An example response for vendor queries package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/vendors/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby An example response for vendor queries require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/vendors/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java An example response for vendor queries import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/vendors/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php An example response for vendor queries request('GET', 'https://api-sandbox.payabli.com/api/Query/vendors/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift An example response for vendor queries import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/vendors/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List vendors by organization GET https://api-sandbox.payabli.com/api/Query/vendors/org/{orgId} Retrieve a list of vendors for an organization. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/vendor/get-list-of-vendors-for-organization ## SDK Code Examples ```typescript An example response for vendor queries import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listVendorsOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python An example response for vendor queries from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_vendors_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp An example response for vendor queries using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListVendorsOrgAsync( 123, new ListVendorsOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go An example response for vendor queries package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/vendors/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby An example response for vendor queries require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/vendors/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java An example response for vendor queries import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/vendors/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php An example response for vendor queries request('GET', 'https://api-sandbox.payabli.com/api/Query/vendors/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift An example response for vendor queries import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/vendors/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export vendors by paypoint GET https://api-sandbox.payabli.com/api/Export/vendors/{format}/{entry} Export a list of vendors for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/vendor/export-vendors-for-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportVendors("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_vendors( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportVendorsAsync( ExportFormat1.Csv, "8cfec329267", new ExportVendorsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/vendors/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/vendors/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/vendors/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/vendors/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/vendors/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export vendors by org GET https://api-sandbox.payabli.com/api/Export/vendors/{format}/org/{orgId} Export a list of vendors for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/vendor/export-vendors-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportVendorsOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_vendors_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportVendorsOrgAsync( ExportFormat1.Csv, 123, new ExportVendorsOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/vendors/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/vendors/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/vendors/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/vendors/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/vendors/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get vendor stats GET https://api-sandbox.payabli.com/api/Statistic/vendorbasic/{mode}/{freq}/{idVendor} Retrieve the basic statistics about a vendor for a given time period, grouped by frequency. Reference: https://docs.payabli.com/developers/api-reference/vendor/get-basic-statistics-for-a-vendor ## SDK Code Examples ```typescript VendorBasicStatsExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.statistic.vendorBasicStats("m", 1, "ytd", {}); } main(); ``` ```python VendorBasicStatsExample from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.statistic.vendor_basic_stats( freq="m", id_vendor=1, mode="ytd", ) ``` ```csharp VendorBasicStatsExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Statistic.VendorBasicStatsAsync( "ytd", "m", 1, new VendorBasicStatsRequest() ); } } ``` ```go VendorBasicStatsExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Statistic/vendorbasic/ytd/m/1" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby VendorBasicStatsExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Statistic/vendorbasic/ytd/m/1") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java VendorBasicStatsExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Statistic/vendorbasic/ytd/m/1") .header("requestToken", "") .asString(); ``` ```php VendorBasicStatsExample request('GET', 'https://api-sandbox.payabli.com/api/Statistic/vendorbasic/ytd/m/1', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift VendorBasicStatsExample import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Statistic/vendorbasic/ytd/m/1")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create bill POST https://api-sandbox.payabli.com/api/Bill/single/{entry} Content-Type: application/json Creates a bill in an entrypoint. Reference: https://docs.payabli.com/developers/api-reference/bill/add-bill ## SDK Code Examples ```typescript CreateBill import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.addBill("8cfec329267", { body: { accountingField1: "MyInternalId", attachments: [ { filename: "my-doc.pdf", ftype: "pdf", furl: "https://mysite.com/my-doc.pdf", }, ], billDate: "2024-07-01", billItems: [ { itemCost: 5, itemCategories: [ "deposits", ], itemCommodityCode: "010", itemDescription: "Deposit for materials", itemMode: 0, itemProductCode: "M-DEPOSIT", itemProductName: "Materials deposit", itemQty: 1, itemTaxAmount: 7, itemTaxRate: 0.075, itemTotalAmount: 123, itemUnitOfMeasure: "SqFt", }, ], billNumber: "ABC-123", comments: "Deposit for materials", dueDate: "2024-07-01", endDate: "2024-07-01", frequency: "monthly", mode: 0, netAmount: 3762.87, status: -99, terms: "NET30", vendor: { vendorNumber: "1234-A", }, }, }); } main(); ``` ```python CreateBill from payabli import payabli, FileContent, BillItem, VendorData import datetime client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.add_bill( entry="8cfec329267", accounting_field_1="MyInternalId", attachments=[ FileContent( filename="my-doc.pdf", ftype="pdf", furl="https://mysite.com/my-doc.pdf", ) ], bill_date=datetime.date.fromisoformat("2024-07-01"), bill_items=[ BillItem( item_cost=5, item_categories=[ "deposits" ], item_commodity_code="010", item_description="Deposit for materials", item_mode=0, item_product_code="M-DEPOSIT", item_product_name="Materials deposit", item_qty=1, item_tax_amount=7, item_tax_rate=0.075, item_total_amount=123, item_unit_of_measure="SqFt", ) ], bill_number="ABC-123", comments="Deposit for materials", due_date=datetime.date.fromisoformat("2024-07-01"), end_date=datetime.date.fromisoformat("2024-07-01"), frequency="monthly", mode=0, net_amount=3762.87, status=-99, terms="NET30", vendor=VendorData( vendor_number="1234-A", ), ) ``` ```csharp CreateBill using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; using System; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.AddBillAsync( "8cfec329267", new AddBillRequest { Body = new BillOutData { AccountingField1 = "MyInternalId", Attachments = new List(){ new FileContent { Filename = "my-doc.pdf", Ftype = FileContentFtype.Pdf, Furl = "https://mysite.com/my-doc.pdf" }, } , BillDate = DateOnly.Parse("2024-07-01"), BillItems = new List(){ new BillItem { ItemCost = 5, ItemCategories = new List(){ "deposits", } , ItemCommodityCode = "010", ItemDescription = "Deposit for materials", ItemMode = 0, ItemProductCode = "M-DEPOSIT", ItemProductName = "Materials deposit", ItemQty = 1, ItemTaxAmount = 7, ItemTaxRate = 0.075, ItemTotalAmount = 123, ItemUnitOfMeasure = "SqFt" }, } , BillNumber = "ABC-123", Comments = "Deposit for materials", DueDate = DateOnly.Parse("2024-07-01"), EndDate = DateOnly.Parse("2024-07-01"), Frequency = Frequency.Monthly, Mode = 0, NetAmount = 3762.87, Status = -99, Terms = "NET30", Vendor = new VendorData { VendorNumber = "1234-A" } } } ); } } ``` ```go CreateBill package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Bill/single/8cfec329267" payload := strings.NewReader("{\n \"accountingField1\": \"MyInternalId\",\n \"attachments\": [\n {\n \"filename\": \"my-doc.pdf\",\n \"ftype\": \"pdf\",\n \"furl\": \"https://mysite.com/my-doc.pdf\"\n }\n ],\n \"billDate\": \"2024-07-01\",\n \"billItems\": [\n {\n \"itemCost\": 5,\n \"itemCategories\": [\n \"deposits\"\n ],\n \"itemCommodityCode\": \"010\",\n \"itemDescription\": \"Deposit for materials\",\n \"itemMode\": 0,\n \"itemProductCode\": \"M-DEPOSIT\",\n \"itemProductName\": \"Materials deposit\",\n \"itemQty\": 1,\n \"itemTaxAmount\": 7,\n \"itemTaxRate\": 0.075,\n \"itemTotalAmount\": 123,\n \"itemUnitOfMeasure\": \"SqFt\"\n }\n ],\n \"billNumber\": \"ABC-123\",\n \"comments\": \"Deposit for materials\",\n \"dueDate\": \"2024-07-01\",\n \"endDate\": \"2024-07-01\",\n \"frequency\": \"monthly\",\n \"mode\": 0,\n \"netAmount\": 3762.87,\n \"status\": -99,\n \"terms\": \"NET30\",\n \"vendor\": {\n \"vendorNumber\": \"1234-A\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CreateBill require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Bill/single/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"accountingField1\": \"MyInternalId\",\n \"attachments\": [\n {\n \"filename\": \"my-doc.pdf\",\n \"ftype\": \"pdf\",\n \"furl\": \"https://mysite.com/my-doc.pdf\"\n }\n ],\n \"billDate\": \"2024-07-01\",\n \"billItems\": [\n {\n \"itemCost\": 5,\n \"itemCategories\": [\n \"deposits\"\n ],\n \"itemCommodityCode\": \"010\",\n \"itemDescription\": \"Deposit for materials\",\n \"itemMode\": 0,\n \"itemProductCode\": \"M-DEPOSIT\",\n \"itemProductName\": \"Materials deposit\",\n \"itemQty\": 1,\n \"itemTaxAmount\": 7,\n \"itemTaxRate\": 0.075,\n \"itemTotalAmount\": 123,\n \"itemUnitOfMeasure\": \"SqFt\"\n }\n ],\n \"billNumber\": \"ABC-123\",\n \"comments\": \"Deposit for materials\",\n \"dueDate\": \"2024-07-01\",\n \"endDate\": \"2024-07-01\",\n \"frequency\": \"monthly\",\n \"mode\": 0,\n \"netAmount\": 3762.87,\n \"status\": -99,\n \"terms\": \"NET30\",\n \"vendor\": {\n \"vendorNumber\": \"1234-A\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java CreateBill import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Bill/single/8cfec329267") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"accountingField1\": \"MyInternalId\",\n \"attachments\": [\n {\n \"filename\": \"my-doc.pdf\",\n \"ftype\": \"pdf\",\n \"furl\": \"https://mysite.com/my-doc.pdf\"\n }\n ],\n \"billDate\": \"2024-07-01\",\n \"billItems\": [\n {\n \"itemCost\": 5,\n \"itemCategories\": [\n \"deposits\"\n ],\n \"itemCommodityCode\": \"010\",\n \"itemDescription\": \"Deposit for materials\",\n \"itemMode\": 0,\n \"itemProductCode\": \"M-DEPOSIT\",\n \"itemProductName\": \"Materials deposit\",\n \"itemQty\": 1,\n \"itemTaxAmount\": 7,\n \"itemTaxRate\": 0.075,\n \"itemTotalAmount\": 123,\n \"itemUnitOfMeasure\": \"SqFt\"\n }\n ],\n \"billNumber\": \"ABC-123\",\n \"comments\": \"Deposit for materials\",\n \"dueDate\": \"2024-07-01\",\n \"endDate\": \"2024-07-01\",\n \"frequency\": \"monthly\",\n \"mode\": 0,\n \"netAmount\": 3762.87,\n \"status\": -99,\n \"terms\": \"NET30\",\n \"vendor\": {\n \"vendorNumber\": \"1234-A\"\n }\n}") .asString(); ``` ```php CreateBill request('POST', 'https://api-sandbox.payabli.com/api/Bill/single/8cfec329267', [ 'body' => '{ "accountingField1": "MyInternalId", "attachments": [ { "filename": "my-doc.pdf", "ftype": "pdf", "furl": "https://mysite.com/my-doc.pdf" } ], "billDate": "2024-07-01", "billItems": [ { "itemCost": 5, "itemCategories": [ "deposits" ], "itemCommodityCode": "010", "itemDescription": "Deposit for materials", "itemMode": 0, "itemProductCode": "M-DEPOSIT", "itemProductName": "Materials deposit", "itemQty": 1, "itemTaxAmount": 7, "itemTaxRate": 0.075, "itemTotalAmount": 123, "itemUnitOfMeasure": "SqFt" } ], "billNumber": "ABC-123", "comments": "Deposit for materials", "dueDate": "2024-07-01", "endDate": "2024-07-01", "frequency": "monthly", "mode": 0, "netAmount": 3762.87, "status": -99, "terms": "NET30", "vendor": { "vendorNumber": "1234-A" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CreateBill import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "accountingField1": "MyInternalId", "attachments": [ [ "filename": "my-doc.pdf", "ftype": "pdf", "furl": "https://mysite.com/my-doc.pdf" ] ], "billDate": "2024-07-01", "billItems": [ [ "itemCost": 5, "itemCategories": ["deposits"], "itemCommodityCode": "010", "itemDescription": "Deposit for materials", "itemMode": 0, "itemProductCode": "M-DEPOSIT", "itemProductName": "Materials deposit", "itemQty": 1, "itemTaxAmount": 7, "itemTaxRate": 0.075, "itemTotalAmount": 123, "itemUnitOfMeasure": "SqFt" ] ], "billNumber": "ABC-123", "comments": "Deposit for materials", "dueDate": "2024-07-01", "endDate": "2024-07-01", "frequency": "monthly", "mode": 0, "netAmount": 3762.87, "status": -99, "terms": "NET30", "vendor": ["vendorNumber": "1234-A"] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Bill/single/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get bill GET https://api-sandbox.payabli.com/api/Bill/{idBill} Retrieves a bill by ID from an entrypoint. Reference: https://docs.payabli.com/developers/api-reference/bill/get-bill ## SDK Code Examples ```typescript GetBillbyId import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.getBill(285); } main(); ``` ```python GetBillbyId from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.get_bill( id_bill=285, ) ``` ```csharp GetBillbyId using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.GetBillAsync( 285 ); } } ``` ```go GetBillbyId package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Bill/285" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetBillbyId require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Bill/285") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetBillbyId import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Bill/285") .header("requestToken", "") .asString(); ``` ```php GetBillbyId request('GET', 'https://api-sandbox.payabli.com/api/Bill/285', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetBillbyId import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Bill/285")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update bill PUT https://api-sandbox.payabli.com/api/Bill/{idBill} Content-Type: application/json Updates a bill by ID. Reference: https://docs.payabli.com/developers/api-reference/bill/update-bill ## SDK Code Examples ```typescript UpdateBill import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.editBill(285, { billDate: "2025-07-01", netAmount: 3762.87, }); } main(); ``` ```python UpdateBill from payabli import payabli import datetime client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.edit_bill( id_bill=285, bill_date=datetime.date.fromisoformat("2025-07-01"), net_amount=3762.87, ) ``` ```csharp UpdateBill using PayabliPayabliApi; using System.Threading.Tasks; using System; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.EditBillAsync( 285, new BillOutData { BillDate = DateOnly.Parse("2025-07-01"), NetAmount = 3762.87 } ); } } ``` ```go UpdateBill package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Bill/285" payload := strings.NewReader("{\n \"billDate\": \"2025-07-01\",\n \"netAmount\": 3762.87\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdateBill require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Bill/285") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"billDate\": \"2025-07-01\",\n \"netAmount\": 3762.87\n}" response = http.request(request) puts response.read_body ``` ```java UpdateBill import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Bill/285") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"billDate\": \"2025-07-01\",\n \"netAmount\": 3762.87\n}") .asString(); ``` ```php UpdateBill request('PUT', 'https://api-sandbox.payabli.com/api/Bill/285', [ 'body' => '{ "billDate": "2025-07-01", "netAmount": 3762.87 }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdateBill import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "billDate": "2025-07-01", "netAmount": 3762.87 ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Bill/285")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete bill DELETE https://api-sandbox.payabli.com/api/Bill/{idBill} Deletes a bill by ID. Reference: https://docs.payabli.com/developers/api-reference/bill/delete-bill ## SDK Code Examples ```typescript SuccessResponse import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.deleteBill(285); } main(); ``` ```python SuccessResponse from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.delete_bill( id_bill=285, ) ``` ```csharp SuccessResponse using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.DeleteBillAsync( 285 ); } } ``` ```go SuccessResponse package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Bill/285" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby SuccessResponse require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Bill/285") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java SuccessResponse import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Bill/285") .header("requestToken", "") .asString(); ``` ```php SuccessResponse request('DELETE', 'https://api-sandbox.payabli.com/api/Bill/285', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift SuccessResponse import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Bill/285")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List bills by paypoint GET https://api-sandbox.payabli.com/api/Query/bills/{entry} Retrieve a list of bills for an entrypoint. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/bill/get-list-of-bills-for-entrypoint ## SDK Code Examples ```typescript ListBillsEntry import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.listBills("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python ListBillsEntry from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.list_bills( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp ListBillsEntry using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.ListBillsAsync( "8cfec329267", new ListBillsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go ListBillsEntry package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/bills/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListBillsEntry require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/bills/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java ListBillsEntry import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/bills/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php ListBillsEntry request('GET', 'https://api-sandbox.payabli.com/api/Query/bills/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ListBillsEntry import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/bills/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List bills by organization GET https://api-sandbox.payabli.com/api/Query/bills/org/{orgId} Retrieve a list of bills for an organization. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/bill/get-list-of-bills-for-organization ## SDK Code Examples ```typescript ListBillsOrg import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.listBillsOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python ListBillsOrg from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.list_bills_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp ListBillsOrg using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.ListBillsOrgAsync( 123, new ListBillsOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go ListBillsOrg package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/bills/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListBillsOrg require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/bills/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java ListBillsOrg import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/bills/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php ListBillsOrg request('GET', 'https://api-sandbox.payabli.com/api/Query/bills/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ListBillsOrg import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/bills/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Import bills POST https://api-sandbox.payabli.com/api/Import/billsForm/{entry} Content-Type: multipart/form-data Import a list of bills from a CSV file. See the [Import Guide](/developers/developer-guides/bills-add#import-bills) for more help and an example file. Reference: https://docs.payabli.com/developers/api-reference/bill/import-list-of-bills ## SDK Code Examples ```typescript ImportBills import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.import.importBills("8cfec329267", ); } main(); ``` ```python ImportBills from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.import_.import_bills( entry="8cfec329267", file="example_file", ) ``` ```csharp ImportBills using PayabliPayabliApi; using System.Threading.Tasks; using System.IO; using System.Text; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Import.ImportBillsAsync( "8cfec329267", new ImportBillsRequest { File = new FileParameter(){ Stream = new MemoryStream(Encoding.UTF8.GetBytes("[bytes]")) } } ); } } ``` ```go ImportBills package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Import/billsForm/8cfec329267" payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"\"\r\nContent-Type: application/octet-stream\r\n\r\n\r\n-----011000010111000001101001--\r\n") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "multipart/form-data; boundary=---011000010111000001101001") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ImportBills require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Import/billsForm/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'multipart/form-data; boundary=---011000010111000001101001' request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"\"\r\nContent-Type: application/octet-stream\r\n\r\n\r\n-----011000010111000001101001--\r\n" response = http.request(request) puts response.read_body ``` ```java ImportBills import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Import/billsForm/8cfec329267") .header("requestToken", "") .header("Content-Type", "multipart/form-data; boundary=---011000010111000001101001") .body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"\"\r\nContent-Type: application/octet-stream\r\n\r\n\r\n-----011000010111000001101001--\r\n") .asString(); ``` ```php ImportBills request('POST', 'https://api-sandbox.payabli.com/api/Import/billsForm/8cfec329267', [ 'multipart' => [ [ 'name' => 'file', 'filename' => '', 'contents' => null ] ] 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ImportBills import Foundation let headers = [ "requestToken": "", "Content-Type": "multipart/form-data; boundary=---011000010111000001101001" ] let parameters = [ [ "name": "file", "fileName": "" ] ] let boundary = "---011000010111000001101001" var body = "" var error: NSError? = nil for param in parameters { let paramName = param["name"]! body += "--\(boundary)\r\n" body += "Content-Disposition:form-data; name=\"\(paramName)\"" if let filename = param["fileName"] { let contentType = param["content-type"]! let fileContent = String(contentsOfFile: filename, encoding: String.Encoding.utf8) if (error != nil) { print(error as Any) } body += "; filename=\"\(filename)\"\r\n" body += "Content-Type: \(contentType)\r\n\r\n" body += fileContent } else if let paramValue = param["value"] { body += "\r\n\r\n\(paramValue)" } } let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Import/billsForm/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete bill attachment DELETE https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/{idBill}/{filename} Delete a file attached to a bill. Reference: https://docs.payabli.com/developers/api-reference/bill/delete-attached-file-from-bill ## SDK Code Examples ```typescript DeleteAttachment import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.deleteAttachedFromBill("0_Bill.pdf", 285, {}); } main(); ``` ```python DeleteAttachment from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.delete_attached_from_bill( filename="0_Bill.pdf", id_bill=285, ) ``` ```csharp DeleteAttachment using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.DeleteAttachedFromBillAsync( 285, "0_Bill.pdf", new DeleteAttachedFromBillRequest() ); } } ``` ```go DeleteAttachment package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby DeleteAttachment require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java DeleteAttachment import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf") .header("requestToken", "") .asString(); ``` ```php DeleteAttachment request('DELETE', 'https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift DeleteAttachment import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get bill attachment GET https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/{idBill}/{filename} Retrieves a file attached to a bill, either as a binary file or as a Base64-encoded string. Reference: https://docs.payabli.com/developers/api-reference/bill/get-attached-file-from-bill ## SDK Code Examples ```typescript GetAttachedFile import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.getAttachedFromBill("0_Bill.pdf", 285, { returnObject: true, }); } main(); ``` ```python GetAttachedFile from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.get_attached_from_bill( filename="0_Bill.pdf", id_bill=285, return_object=True, ) ``` ```csharp GetAttachedFile using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.GetAttachedFromBillAsync( 285, "0_Bill.pdf", new GetAttachedFromBillRequest { ReturnObject = true } ); } } ``` ```go GetAttachedFile package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf?returnObject=true" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetAttachedFile require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf?returnObject=true") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetAttachedFile import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf?returnObject=true") .header("requestToken", "") .asString(); ``` ```php GetAttachedFile request('GET', 'https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf?returnObject=true', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetAttachedFile import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Bill/attachedFileFromBill/285/0_Bill.pdf?returnObject=true")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Send bill for approval POST https://api-sandbox.payabli.com/api/Bill/approval/{idBill} Content-Type: application/json Send a bill to a user or list of users to approve. Reference: https://docs.payabli.com/developers/api-reference/bill/send-a-bill-to-approval ## SDK Code Examples ```typescript SendForApproval import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.sendToApprovalBill(285, { idempotencyKey: "6B29FC40-CA47-1067-B31D-00DD010662DA", body: [ "string", ], }); } main(); ``` ```python SendForApproval from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.send_to_approval_bill( id_bill=285, idempotency_key="6B29FC40-CA47-1067-B31D-00DD010662DA", request=[ "string" ], ) ``` ```csharp SendForApproval using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.SendToApprovalBillAsync( 285, new SendToApprovalBillRequest { IdempotencyKey = "6B29FC40-CA47-1067-B31D-00DD010662DA", Body = new List(){ "string", } } ); } } ``` ```go SendForApproval package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Bill/approval/285" payload := strings.NewReader("[\n \"string\"\n]") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby SendForApproval require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Bill/approval/285") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["idempotencyKey"] = '6B29FC40-CA47-1067-B31D-00DD010662DA' request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "[\n \"string\"\n]" response = http.request(request) puts response.read_body ``` ```java SendForApproval import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Bill/approval/285") .header("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") .header("requestToken", "") .header("Content-Type", "application/json") .body("[\n \"string\"\n]") .asString(); ``` ```php SendForApproval request('POST', 'https://api-sandbox.payabli.com/api/Bill/approval/285', [ 'body' => '[ "string" ]', 'headers' => [ 'Content-Type' => 'application/json', 'idempotencyKey' => '6B29FC40-CA47-1067-B31D-00DD010662DA', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift SendForApproval import Foundation let headers = [ "idempotencyKey": "6B29FC40-CA47-1067-B31D-00DD010662DA", "requestToken": "", "Content-Type": "application/json" ] let parameters = ["string"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Bill/approval/285")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Approve bill GET https://api-sandbox.payabli.com/api/Bill/approval/{idBill}/{approved} Approve or disapprove a bill by ID. Reference: https://docs.payabli.com/developers/api-reference/bill/approve-or-disapprove-a-bill ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.setApprovedBill("true", 285, {}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.set_approved_bill( approved="true", id_bill=285, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.SetApprovedBillAsync( 285, "true", new SetApprovedBillRequest() ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Bill/approval/285/true" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Bill/approval/285/true") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Bill/approval/285/true") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Bill/approval/285/true', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Bill/approval/285/true")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Change approvers PUT https://api-sandbox.payabli.com/api/Bill/approval/{idBill} Content-Type: application/json Modify the list of users the bill is sent to for approval. Reference: https://docs.payabli.com/developers/api-reference/bill/change-bill-approvers ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.bill.modifyApprovalBill(285, [ "string", ]); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.bill.modify_approval_bill( id_bill=285, request=[ "string" ], ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Bill.ModifyApprovalBillAsync( 285, new List(){ "string", } ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Bill/approval/285" payload := strings.NewReader("[\n \"string\"\n]") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Bill/approval/285") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "[\n \"string\"\n]" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Bill/approval/285") .header("requestToken", "") .header("Content-Type", "application/json") .body("[\n \"string\"\n]") .asString(); ``` ```php request('PUT', 'https://api-sandbox.payabli.com/api/Bill/approval/285', [ 'body' => '[ "string" ]', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["string"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Bill/approval/285")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export bills by paypoint GET https://api-sandbox.payabli.com/api/Export/bills/{format}/{entry} Export a list of bills for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/bill/export-bills ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportBills("8cfec329267", "csv", { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_bills( entry="8cfec329267", format="csv", columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportBillsAsync( ExportFormat1.Csv, "8cfec329267", new ExportBillsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/bills/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/bills/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/bills/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/bills/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/bills/csv/8cfec329267?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export bills by org GET https://api-sandbox.payabli.com/api/Export/bills/{format}/org/{orgId} Export a list of bills for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/bill/export-bills-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportBillsOrg("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_bills_org( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportBillsOrgAsync( ExportFormat1.Csv, 123, new ExportBillsOrgRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/bills/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/bills/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/bills/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/bills/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/bills/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Generate boarding link GET https://api-sandbox.payabli.com/api/Templates/getlink/{templateId}/{ignoreEmpty} Generates a boarding link from a boarding template. Reference: https://docs.payabli.com/developers/api-reference/templates/generate-boarding-link-from-template ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.templates.getlinkTemplate(true, 80); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.templates.getlink_template( ignore_empty=True, template_id=80, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Templates.GetlinkTemplateAsync( 80, true ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Templates/getlink/80/true" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Templates/getlink/80/true") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Templates/getlink/80/true") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Templates/getlink/80/true', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Templates/getlink/80/true")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get template GET https://api-sandbox.payabli.com/api/Templates/get/{templateId} Retrieves a boarding template's details by ID. Reference: https://docs.payabli.com/developers/api-reference/templates/get-boarding-template-by-id ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.templates.getTemplate(80); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.templates.get_template( template_id=80, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Templates.GetTemplateAsync( 80 ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Templates/get/80" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Templates/get/80") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Templates/get/80") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Templates/get/80', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Templates/get/80")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List templates GET https://api-sandbox.payabli.com/api/Query/templates/{orgId} Retrieves a list of boarding templates for an organization. Use filters to limit results. You can't make a request that includes filters from the API console in the documentation. The response won't be filtered. Instead, copy the request, remove `parameters=` and run the request in a different client. Reference: https://docs.payabli.com/developers/api-reference/templates/get-list-of-boarding-templates-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.templates.listTemplates(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.templates.list_templates( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Templates.ListTemplatesAsync( 123, new ListTemplatesRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/templates/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/templates/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/templates/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/templates/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/templates/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete template DELETE https://api-sandbox.payabli.com/api/Templates/{templateId} Deletes a template by ID. Reference: https://docs.payabli.com/developers/api-reference/templates/delete-boarding-template ## SDK Code Examples ```typescript General success response example for template operations. import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.templates.deleteTemplate(80); } main(); ``` ```python General success response example for template operations. from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.templates.delete_template( template_id=80, ) ``` ```csharp General success response example for template operations. using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Templates.DeleteTemplateAsync( 80 ); } } ``` ```go General success response example for template operations. package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Templates/80" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby General success response example for template operations. require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Templates/80") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java General success response example for template operations. import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Templates/80") .header("requestToken", "") .asString(); ``` ```php General success response example for template operations. request('DELETE', 'https://api-sandbox.payabli.com/api/Templates/80', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift General success response example for template operations. import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Templates/80")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create merchant application POST https://api-sandbox.payabli.com/api/Boarding/app Content-Type: application/json Creates a boarding application in an organization. This endpoint requires an application API token. Reference: https://docs.payabli.com/developers/api-reference/boarding/create-boarding-application ## SDK Code Examples ```typescript PayIn import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.addApplication({ services: { ach: {}, card: { acceptAmex: true, acceptDiscover: true, acceptMastercard: true, acceptVisa: true, }, }, annualRevenue: 1000, averageBillSize: "500", averageMonthlyBill: "5650", avgmonthly: 1000, baddress: "123 Walnut Street", baddress1: "Suite 103", bankData: [ { accountNumber: "123123123", bankAccountFunction: 1, bankAccountHolderName: "Gruzya Adventure Outfitters LLC", bankAccountHolderType: "Business", bankName: "Test Bank", nickname: "Withdrawal Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "123-456", }, { accountNumber: "123123123", bankAccountFunction: 0, bankAccountHolderName: "Gruzya Adventure Outfitters LLC", bankAccountHolderType: "Business", bankName: "Test Bank", nickname: "Deposit Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "123-456", }, ], bcity: "New Vegas", bcountry: "US", binperson: 60, binphone: 20, binweb: 20, bstate: "FL", bsummary: "Brick and mortar store that sells office supplies", btype: "Limited Liability Company", bzip: "33000", contacts: [ { contactEmail: "herman@hermanscoatings.com", contactName: "Herman Martinez", contactPhone: "3055550000", contactTitle: "Owner", }, ], creditLimit: "creditLimit", dbaName: "Sunshine Gutters", ein: "123456789", faxnumber: "1234567890", highticketamt: 1000, legalName: "Sunshine Services, LLC", license: "2222222FFG", licstate: "CA", maddress: "123 Walnut Street", maddress1: "STE 900", mcc: "7777", mcity: "Johnson City", mcountry: "US", mstate: "TN", mzip: "37615", orgId: 123, ownership: [ { oaddress: "33 North St", ocity: "Any City", ocountry: "US", odriverstate: "CA", ostate: "CA", ownerdob: "01/01/1990", ownerdriver: "CA6677778", owneremail: "test@email.com", ownername: "John Smith", ownerpercent: 100, ownerphone1: "555888111", ownerphone2: "555888111", ownerssn: "123456789", ownertitle: "CEO", ozip: "55555", }, ], phonenumber: "1234567890", processingRegion: "US", recipientEmail: "josephray@example.com", recipientEmailNotification: true, resumable: true, signer: { address: "33 North St", address1: "STE 900", city: "Bristol", country: "US", dob: "01/01/1976", email: "test@email.com", name: "John Smith", phone: "555888111", ssn: "123456789", state: "TN", zip: "55555", pciAttestation: true, signedDocumentReference: "https://example.com/signed-document.pdf", attestationDate: "04/20/2025", signDate: "04/20/2025", additionalData: { "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years", }, }, startdate: "01/01/1990", taxFillName: "Sunshine LLC", templateId: 22, ticketamt: 1000, website: "www.example.com", whenCharged: "When Service Provided", whenDelivered: "Over 30 Days", whenProvided: "30 Days or Less", whenRefunded: "30 Days or Less", }); } main(); ``` ```python PayIn from payabli import payabli, ApplicationDataPayIn, ApplicationDataPayInServices, ApplicationDataPayInServicesAch, ApplicationDataPayInServicesCard, Bank, ApplicationDataPayInContactsItem, ApplicationDataPayInOwnershipItem, SignerDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.add_application( request=ApplicationDataPayIn( services=ApplicationDataPayInServices( ach=ApplicationDataPayInServicesAch(), card=ApplicationDataPayInServicesCard( accept_amex=True, accept_discover=True, accept_mastercard=True, accept_visa=True, ), ), annual_revenue=1000, average_bill_size="500", average_monthly_bill="5650", avgmonthly=1000, baddress="123 Walnut Street", baddress_1="Suite 103", bank_data=[ Bank( account_number="123123123", bank_account_function=1, bank_account_holder_name="Gruzya Adventure Outfitters LLC", bank_account_holder_type="Business", bank_name="Test Bank", nickname="Withdrawal Account", routing_account="123123123", type_account="Checking", account_id="123-456", ), Bank( account_number="123123123", bank_account_function=0, bank_account_holder_name="Gruzya Adventure Outfitters LLC", bank_account_holder_type="Business", bank_name="Test Bank", nickname="Deposit Account", routing_account="123123123", type_account="Checking", account_id="123-456", ) ], bcity="New Vegas", bcountry="US", binperson=60, binphone=20, binweb=20, bstate="FL", bsummary="Brick and mortar store that sells office supplies", btype="Limited Liability Company", bzip="33000", contacts=[ ApplicationDataPayInContactsItem( contact_email="herman@hermanscoatings.com", contact_name="Herman Martinez", contact_phone="3055550000", contact_title="Owner", ) ], credit_limit="creditLimit", dba_name="Sunshine Gutters", ein="123456789", faxnumber="1234567890", highticketamt=1000, legal_name="Sunshine Services, LLC", license="2222222FFG", licstate="CA", maddress="123 Walnut Street", maddress_1="STE 900", mcc="7777", mcity="Johnson City", mcountry="US", mstate="TN", mzip="37615", org_id=123, ownership=[ ApplicationDataPayInOwnershipItem( oaddress="33 North St", ocity="Any City", ocountry="US", odriverstate="CA", ostate="CA", ownerdob="01/01/1990", ownerdriver="CA6677778", owneremail="test@email.com", ownername="John Smith", ownerpercent=100, ownerphone_1="555888111", ownerphone_2="555888111", ownerssn="123456789", ownertitle="CEO", ozip="55555", ) ], phonenumber="1234567890", processing_region="US", recipient_email="josephray@example.com", recipient_email_notification=True, resumable=True, signer=SignerDataRequest( address="33 North St", address_1="STE 900", city="Bristol", country="US", dob="01/01/1976", email="test@email.com", name="John Smith", phone="555888111", ssn="123456789", state="TN", zip="55555", pci_attestation=True, signed_document_reference="https://example.com/signed-document.pdf", attestation_date="04/20/2025", sign_date="04/20/2025", additional_data={ "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" }, ), startdate="01/01/1990", tax_fill_name="Sunshine LLC", template_id=22, ticketamt=1000, website="www.example.com", when_charged="When Service Provided", when_delivered="Over 30 Days", when_provided="30 Days or Less", when_refunded="30 Days or Less", ), ) ``` ```csharp PayIn using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.AddApplicationAsync( new ApplicationDataPayIn { Services = new ApplicationDataPayInServices { Ach = new ApplicationDataPayInServicesAch(), Card = new ApplicationDataPayInServicesCard { AcceptAmex = true, AcceptDiscover = true, AcceptMastercard = true, AcceptVisa = true } }, AnnualRevenue = 1000, AverageBillSize = "500", AverageMonthlyBill = "5650", Avgmonthly = 1000, Baddress = "123 Walnut Street", Baddress1 = "Suite 103", BankData = new List(){ new Bank { AccountNumber = "123123123", BankAccountFunction = 1, BankAccountHolderName = "Gruzya Adventure Outfitters LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "Test Bank", Nickname = "Withdrawal Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "123-456" }, new Bank { AccountNumber = "123123123", BankAccountFunction = 0, BankAccountHolderName = "Gruzya Adventure Outfitters LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "Test Bank", Nickname = "Deposit Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "123-456" }, } , Bcity = "New Vegas", Bcountry = "US", Binperson = 60, Binphone = 20, Binweb = 20, Bstate = "FL", Bsummary = "Brick and mortar store that sells office supplies", Btype = OwnType.LimitedLiabilityCompany, Bzip = "33000", Contacts = new List(){ new ApplicationDataPayInContactsItem { ContactEmail = "herman@hermanscoatings.com", ContactName = "Herman Martinez", ContactPhone = "3055550000", ContactTitle = "Owner" }, } , CreditLimit = "creditLimit", DbaName = "Sunshine Gutters", Ein = "123456789", Faxnumber = "1234567890", Highticketamt = 1000, LegalName = "Sunshine Services, LLC", License = "2222222FFG", Licstate = "CA", Maddress = "123 Walnut Street", Maddress1 = "STE 900", Mcc = "7777", Mcity = "Johnson City", Mcountry = "US", Mstate = "TN", Mzip = "37615", OrgId = 123L, Ownership = new List(){ new ApplicationDataPayInOwnershipItem { Oaddress = "33 North St", Ocity = "Any City", Ocountry = "US", Odriverstate = "CA", Ostate = "CA", Ownerdob = "01/01/1990", Ownerdriver = "CA6677778", Owneremail = "test@email.com", Ownername = "John Smith", Ownerpercent = 100, Ownerphone1 = "555888111", Ownerphone2 = "555888111", Ownerssn = "123456789", Ownertitle = "CEO", Ozip = "55555" }, } , Phonenumber = "1234567890", ProcessingRegion = "US", RecipientEmail = "josephray@example.com", RecipientEmailNotification = true, Resumable = true, Signer = new SignerDataRequest { Address = "33 North St", Address1 = "STE 900", City = "Bristol", Country = "US", Dob = "01/01/1976", Email = "test@email.com", Name = "John Smith", Phone = "555888111", Ssn = "123456789", State = "TN", Zip = "55555", PciAttestation = true, SignedDocumentReference = "https://example.com/signed-document.pdf", AttestationDate = "04/20/2025", SignDate = "04/20/2025", AdditionalData = new Dictionary(){ ["deviceId"] = "499585-389fj484-3jcj8hj3", ["session"] = "fifji4-fiu443-fn4843", ["timeWithCompany"] = "6 Years", } }, Startdate = "01/01/1990", TaxFillName = "Sunshine LLC", TemplateId = 22L, Ticketamt = 1000, Website = "www.example.com", WhenCharged = Whencharged.WhenServiceProvided, WhenDelivered = Whendelivered.Over30Days, WhenProvided = Whenprovided.ThirtyDaysOrLess, WhenRefunded = Whenrefunded.ThirtyDaysOrLess } ); } } ``` ```go PayIn package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/app" payload := strings.NewReader("{\n \"services\": {\n \"ach\": {},\n \"card\": {\n \"acceptAmex\": true,\n \"acceptDiscover\": true,\n \"acceptMastercard\": true,\n \"acceptVisa\": true\n }\n },\n \"annualRevenue\": 1000,\n \"averageBillSize\": \"500\",\n \"averageMonthlyBill\": \"5650\",\n \"avgmonthly\": 1000,\n \"baddress\": \"123 Walnut Street\",\n \"baddress1\": \"Suite 103\",\n \"bankData\": [\n {\n \"accountNumber\": \"123123123\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Gruzya Adventure Outfitters LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"Test Bank\",\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n },\n {\n \"accountNumber\": \"123123123\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Gruzya Adventure Outfitters LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"Test Bank\",\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n }\n ],\n \"bcity\": \"New Vegas\",\n \"bcountry\": \"US\",\n \"binperson\": 60,\n \"binphone\": 20,\n \"binweb\": 20,\n \"bstate\": \"FL\",\n \"bsummary\": \"Brick and mortar store that sells office supplies\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33000\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"creditLimit\": \"creditLimit\",\n \"dbaName\": \"Sunshine Gutters\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"1234567890\",\n \"highticketamt\": 1000,\n \"legalName\": \"Sunshine Services, LLC\",\n \"license\": \"2222222FFG\",\n \"licstate\": \"CA\",\n \"maddress\": \"123 Walnut Street\",\n \"maddress1\": \"STE 900\",\n \"mcc\": \"7777\",\n \"mcity\": \"Johnson City\",\n \"mcountry\": \"US\",\n \"mstate\": \"TN\",\n \"mzip\": \"37615\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"33 North St\",\n \"ocity\": \"Any City\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"CA\",\n \"ostate\": \"CA\",\n \"ownerdob\": \"01/01/1990\",\n \"ownerdriver\": \"CA6677778\",\n \"owneremail\": \"test@email.com\",\n \"ownername\": \"John Smith\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"555888111\",\n \"ownerphone2\": \"555888111\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"CEO\",\n \"ozip\": \"55555\"\n }\n ],\n \"phonenumber\": \"1234567890\",\n \"processingRegion\": \"US\",\n \"recipientEmail\": \"josephray@example.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/1990\",\n \"taxFillName\": \"Sunshine LLC\",\n \"templateId\": 22,\n \"ticketamt\": 1000,\n \"website\": \"www.example.com\",\n \"whenCharged\": \"When Service Provided\",\n \"whenDelivered\": \"Over 30 Days\",\n \"whenProvided\": \"30 Days or Less\",\n \"whenRefunded\": \"30 Days or Less\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby PayIn require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/app") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"services\": {\n \"ach\": {},\n \"card\": {\n \"acceptAmex\": true,\n \"acceptDiscover\": true,\n \"acceptMastercard\": true,\n \"acceptVisa\": true\n }\n },\n \"annualRevenue\": 1000,\n \"averageBillSize\": \"500\",\n \"averageMonthlyBill\": \"5650\",\n \"avgmonthly\": 1000,\n \"baddress\": \"123 Walnut Street\",\n \"baddress1\": \"Suite 103\",\n \"bankData\": [\n {\n \"accountNumber\": \"123123123\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Gruzya Adventure Outfitters LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"Test Bank\",\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n },\n {\n \"accountNumber\": \"123123123\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Gruzya Adventure Outfitters LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"Test Bank\",\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n }\n ],\n \"bcity\": \"New Vegas\",\n \"bcountry\": \"US\",\n \"binperson\": 60,\n \"binphone\": 20,\n \"binweb\": 20,\n \"bstate\": \"FL\",\n \"bsummary\": \"Brick and mortar store that sells office supplies\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33000\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"creditLimit\": \"creditLimit\",\n \"dbaName\": \"Sunshine Gutters\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"1234567890\",\n \"highticketamt\": 1000,\n \"legalName\": \"Sunshine Services, LLC\",\n \"license\": \"2222222FFG\",\n \"licstate\": \"CA\",\n \"maddress\": \"123 Walnut Street\",\n \"maddress1\": \"STE 900\",\n \"mcc\": \"7777\",\n \"mcity\": \"Johnson City\",\n \"mcountry\": \"US\",\n \"mstate\": \"TN\",\n \"mzip\": \"37615\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"33 North St\",\n \"ocity\": \"Any City\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"CA\",\n \"ostate\": \"CA\",\n \"ownerdob\": \"01/01/1990\",\n \"ownerdriver\": \"CA6677778\",\n \"owneremail\": \"test@email.com\",\n \"ownername\": \"John Smith\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"555888111\",\n \"ownerphone2\": \"555888111\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"CEO\",\n \"ozip\": \"55555\"\n }\n ],\n \"phonenumber\": \"1234567890\",\n \"processingRegion\": \"US\",\n \"recipientEmail\": \"josephray@example.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/1990\",\n \"taxFillName\": \"Sunshine LLC\",\n \"templateId\": 22,\n \"ticketamt\": 1000,\n \"website\": \"www.example.com\",\n \"whenCharged\": \"When Service Provided\",\n \"whenDelivered\": \"Over 30 Days\",\n \"whenProvided\": \"30 Days or Less\",\n \"whenRefunded\": \"30 Days or Less\"\n}" response = http.request(request) puts response.read_body ``` ```java PayIn import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Boarding/app") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"services\": {\n \"ach\": {},\n \"card\": {\n \"acceptAmex\": true,\n \"acceptDiscover\": true,\n \"acceptMastercard\": true,\n \"acceptVisa\": true\n }\n },\n \"annualRevenue\": 1000,\n \"averageBillSize\": \"500\",\n \"averageMonthlyBill\": \"5650\",\n \"avgmonthly\": 1000,\n \"baddress\": \"123 Walnut Street\",\n \"baddress1\": \"Suite 103\",\n \"bankData\": [\n {\n \"accountNumber\": \"123123123\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Gruzya Adventure Outfitters LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"Test Bank\",\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n },\n {\n \"accountNumber\": \"123123123\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Gruzya Adventure Outfitters LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"Test Bank\",\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n }\n ],\n \"bcity\": \"New Vegas\",\n \"bcountry\": \"US\",\n \"binperson\": 60,\n \"binphone\": 20,\n \"binweb\": 20,\n \"bstate\": \"FL\",\n \"bsummary\": \"Brick and mortar store that sells office supplies\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33000\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"creditLimit\": \"creditLimit\",\n \"dbaName\": \"Sunshine Gutters\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"1234567890\",\n \"highticketamt\": 1000,\n \"legalName\": \"Sunshine Services, LLC\",\n \"license\": \"2222222FFG\",\n \"licstate\": \"CA\",\n \"maddress\": \"123 Walnut Street\",\n \"maddress1\": \"STE 900\",\n \"mcc\": \"7777\",\n \"mcity\": \"Johnson City\",\n \"mcountry\": \"US\",\n \"mstate\": \"TN\",\n \"mzip\": \"37615\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"33 North St\",\n \"ocity\": \"Any City\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"CA\",\n \"ostate\": \"CA\",\n \"ownerdob\": \"01/01/1990\",\n \"ownerdriver\": \"CA6677778\",\n \"owneremail\": \"test@email.com\",\n \"ownername\": \"John Smith\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"555888111\",\n \"ownerphone2\": \"555888111\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"CEO\",\n \"ozip\": \"55555\"\n }\n ],\n \"phonenumber\": \"1234567890\",\n \"processingRegion\": \"US\",\n \"recipientEmail\": \"josephray@example.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/1990\",\n \"taxFillName\": \"Sunshine LLC\",\n \"templateId\": 22,\n \"ticketamt\": 1000,\n \"website\": \"www.example.com\",\n \"whenCharged\": \"When Service Provided\",\n \"whenDelivered\": \"Over 30 Days\",\n \"whenProvided\": \"30 Days or Less\",\n \"whenRefunded\": \"30 Days or Less\"\n}") .asString(); ``` ```php PayIn request('POST', 'https://api-sandbox.payabli.com/api/Boarding/app', [ 'body' => '{ "services": { "ach": {}, "card": { "acceptAmex": true, "acceptDiscover": true, "acceptMastercard": true, "acceptVisa": true } }, "annualRevenue": 1000, "averageBillSize": "500", "averageMonthlyBill": "5650", "avgmonthly": 1000, "baddress": "123 Walnut Street", "baddress1": "Suite 103", "bankData": [ { "accountNumber": "123123123", "bankAccountFunction": 1, "bankAccountHolderName": "Gruzya Adventure Outfitters LLC", "bankAccountHolderType": "Business", "bankName": "Test Bank", "nickname": "Withdrawal Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-456" }, { "accountNumber": "123123123", "bankAccountFunction": 0, "bankAccountHolderName": "Gruzya Adventure Outfitters LLC", "bankAccountHolderType": "Business", "bankName": "Test Bank", "nickname": "Deposit Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-456" } ], "bcity": "New Vegas", "bcountry": "US", "binperson": 60, "binphone": 20, "binweb": 20, "bstate": "FL", "bsummary": "Brick and mortar store that sells office supplies", "btype": "Limited Liability Company", "bzip": "33000", "contacts": [ { "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" } ], "creditLimit": "creditLimit", "dbaName": "Sunshine Gutters", "ein": "123456789", "faxnumber": "1234567890", "highticketamt": 1000, "legalName": "Sunshine Services, LLC", "license": "2222222FFG", "licstate": "CA", "maddress": "123 Walnut Street", "maddress1": "STE 900", "mcc": "7777", "mcity": "Johnson City", "mcountry": "US", "mstate": "TN", "mzip": "37615", "orgId": 123, "ownership": [ { "oaddress": "33 North St", "ocity": "Any City", "ocountry": "US", "odriverstate": "CA", "ostate": "CA", "ownerdob": "01/01/1990", "ownerdriver": "CA6677778", "owneremail": "test@email.com", "ownername": "John Smith", "ownerpercent": 100, "ownerphone1": "555888111", "ownerphone2": "555888111", "ownerssn": "123456789", "ownertitle": "CEO", "ozip": "55555" } ], "phonenumber": "1234567890", "processingRegion": "US", "recipientEmail": "josephray@example.com", "recipientEmailNotification": true, "resumable": true, "signer": { "address": "33 North St", "address1": "STE 900", "city": "Bristol", "country": "US", "dob": "01/01/1976", "email": "test@email.com", "name": "John Smith", "phone": "555888111", "ssn": "123456789", "state": "TN", "zip": "55555", "pciAttestation": true, "signedDocumentReference": "https://example.com/signed-document.pdf", "attestationDate": "04/20/2025", "signDate": "04/20/2025", "additionalData": { "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" } }, "startdate": "01/01/1990", "taxFillName": "Sunshine LLC", "templateId": 22, "ticketamt": 1000, "website": "www.example.com", "whenCharged": "When Service Provided", "whenDelivered": "Over 30 Days", "whenProvided": "30 Days or Less", "whenRefunded": "30 Days or Less" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift PayIn import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "services": [ "ach": [], "card": [ "acceptAmex": true, "acceptDiscover": true, "acceptMastercard": true, "acceptVisa": true ] ], "annualRevenue": 1000, "averageBillSize": "500", "averageMonthlyBill": "5650", "avgmonthly": 1000, "baddress": "123 Walnut Street", "baddress1": "Suite 103", "bankData": [ [ "accountNumber": "123123123", "bankAccountFunction": 1, "bankAccountHolderName": "Gruzya Adventure Outfitters LLC", "bankAccountHolderType": "Business", "bankName": "Test Bank", "nickname": "Withdrawal Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-456" ], [ "accountNumber": "123123123", "bankAccountFunction": 0, "bankAccountHolderName": "Gruzya Adventure Outfitters LLC", "bankAccountHolderType": "Business", "bankName": "Test Bank", "nickname": "Deposit Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-456" ] ], "bcity": "New Vegas", "bcountry": "US", "binperson": 60, "binphone": 20, "binweb": 20, "bstate": "FL", "bsummary": "Brick and mortar store that sells office supplies", "btype": "Limited Liability Company", "bzip": "33000", "contacts": [ [ "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" ] ], "creditLimit": "creditLimit", "dbaName": "Sunshine Gutters", "ein": "123456789", "faxnumber": "1234567890", "highticketamt": 1000, "legalName": "Sunshine Services, LLC", "license": "2222222FFG", "licstate": "CA", "maddress": "123 Walnut Street", "maddress1": "STE 900", "mcc": "7777", "mcity": "Johnson City", "mcountry": "US", "mstate": "TN", "mzip": "37615", "orgId": 123, "ownership": [ [ "oaddress": "33 North St", "ocity": "Any City", "ocountry": "US", "odriverstate": "CA", "ostate": "CA", "ownerdob": "01/01/1990", "ownerdriver": "CA6677778", "owneremail": "test@email.com", "ownername": "John Smith", "ownerpercent": 100, "ownerphone1": "555888111", "ownerphone2": "555888111", "ownerssn": "123456789", "ownertitle": "CEO", "ozip": "55555" ] ], "phonenumber": "1234567890", "processingRegion": "US", "recipientEmail": "josephray@example.com", "recipientEmailNotification": true, "resumable": true, "signer": [ "address": "33 North St", "address1": "STE 900", "city": "Bristol", "country": "US", "dob": "01/01/1976", "email": "test@email.com", "name": "John Smith", "phone": "555888111", "ssn": "123456789", "state": "TN", "zip": "55555", "pciAttestation": true, "signedDocumentReference": "https://example.com/signed-document.pdf", "attestationDate": "04/20/2025", "signDate": "04/20/2025", "additionalData": [ "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" ] ], "startdate": "01/01/1990", "taxFillName": "Sunshine LLC", "templateId": 22, "ticketamt": 1000, "website": "www.example.com", "whenCharged": "When Service Provided", "whenDelivered": "Over 30 Days", "whenProvided": "30 Days or Less", "whenRefunded": "30 Days or Less" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/app")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript ManagedPayout import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.addApplication({ annualRevenue: 750000, baddress: "789 Industrial Parkway", baddress1: "Unit 12", bankData: [ { accountNumber: "1XXXXXX3100", bankAccountFunction: 1, bankAccountHolderName: "Herman's Coatings LLC", bankAccountHolderType: "Business", bankName: "First Miami Bank", nickname: "Withdrawal Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "123-456", }, { accountNumber: "1XXXXXX3200", bankAccountFunction: 0, bankAccountHolderName: "Herman's Coatings LLC", bankAccountHolderType: "Business", bankName: "First Miami Bank", nickname: "Deposit Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "123-789", }, { accountNumber: "1XXXXXX3123", bankAccountFunction: 3, bankAccountHolderName: "Herman's Coatings LLC", bankAccountHolderType: "Business", bankName: "First Miami Bank", nickname: "Remittance Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "123-100", }, ], bcity: "Miami", bcountry: "US", bstate: "FL", bsummary: "Commercial and industrial coating services, including protective and decorative coatings", btype: "Limited Liability Company", bzip: "33101", contacts: [ { contactEmail: "herman@hermanscoatings.com", contactName: "Herman Martinez", contactPhone: "3055550000", contactTitle: "Owner", }, ], ein: "123456789", faxnumber: "3055550001", license: "FL123456", licstate: "FL", maddress: "789 Industrial Parkway", maddress1: "Unit 12", mcc: "1799", mcity: "Miami", mcountry: "US", mstate: "FL", mzip: "33101", orgId: 123, ownership: [ { oaddress: "123 Palm Avenue", ocity: "Miami", ocountry: "US", odriverstate: "FL", ostate: "FL", ownerdob: "05/15/1980", ownerdriver: "FL789456", owneremail: "herman@hermanscoatings.com", ownername: "Herman Martinez", ownerpercent: 100, ownerphone1: "3055550000", ownerphone2: "3055550002", ownerssn: "123456789", ownertitle: "Owner", ozip: "33102", }, ], phonenumber: "3055550000", recipientEmail: "herman@hermanscoatings.com", recipientEmailNotification: true, resumable: true, signer: { address: "33 North St", address1: "STE 900", city: "Bristol", country: "US", dob: "01/01/1976", email: "test@email.com", name: "John Smith", phone: "555888111", ssn: "123456789", state: "TN", zip: "55555", pciAttestation: true, signedDocumentReference: "https://example.com/signed-document.pdf", attestationDate: "04/20/2025", signDate: "04/20/2025", additionalData: { "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years", }, }, startdate: "01/01/2015", templateId: 22, website: "www.hermanscoatings.com", }); } main(); ``` ```python ManagedPayout from payabli import payabli, ApplicationDataPayIn, Bank, ApplicationDataPayInContactsItem, ApplicationDataPayInOwnershipItem, SignerDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.add_application( request=ApplicationDataPayIn( annual_revenue=750000, baddress="789 Industrial Parkway", baddress_1="Unit 12", bank_data=[ Bank( account_number="1XXXXXX3100", bank_account_function=1, bank_account_holder_name="Herman\'s Coatings LLC", bank_account_holder_type="Business", bank_name="First Miami Bank", nickname="Withdrawal Account", routing_account="123123123", type_account="Checking", account_id="123-456", ), Bank( account_number="1XXXXXX3200", bank_account_function=0, bank_account_holder_name="Herman\'s Coatings LLC", bank_account_holder_type="Business", bank_name="First Miami Bank", nickname="Deposit Account", routing_account="123123123", type_account="Checking", account_id="123-789", ), Bank( account_number="1XXXXXX3123", bank_account_function=3, bank_account_holder_name="Herman\'s Coatings LLC", bank_account_holder_type="Business", bank_name="First Miami Bank", nickname="Remittance Account", routing_account="123123123", type_account="Checking", account_id="123-100", ) ], bcity="Miami", bcountry="US", bstate="FL", bsummary="Commercial and industrial coating services, including protective and decorative coatings", btype="Limited Liability Company", bzip="33101", contacts=[ ApplicationDataPayInContactsItem( contact_email="herman@hermanscoatings.com", contact_name="Herman Martinez", contact_phone="3055550000", contact_title="Owner", ) ], ein="123456789", faxnumber="3055550001", license="FL123456", licstate="FL", maddress="789 Industrial Parkway", maddress_1="Unit 12", mcc="1799", mcity="Miami", mcountry="US", mstate="FL", mzip="33101", org_id=123, ownership=[ ApplicationDataPayInOwnershipItem( oaddress="123 Palm Avenue", ocity="Miami", ocountry="US", odriverstate="FL", ostate="FL", ownerdob="05/15/1980", ownerdriver="FL789456", owneremail="herman@hermanscoatings.com", ownername="Herman Martinez", ownerpercent=100, ownerphone_1="3055550000", ownerphone_2="3055550002", ownerssn="123456789", ownertitle="Owner", ozip="33102", ) ], phonenumber="3055550000", recipient_email="herman@hermanscoatings.com", recipient_email_notification=True, resumable=True, signer=SignerDataRequest( address="33 North St", address_1="STE 900", city="Bristol", country="US", dob="01/01/1976", email="test@email.com", name="John Smith", phone="555888111", ssn="123456789", state="TN", zip="55555", pci_attestation=True, signed_document_reference="https://example.com/signed-document.pdf", attestation_date="04/20/2025", sign_date="04/20/2025", additional_data={ "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" }, ), startdate="01/01/2015", template_id=22, website="www.hermanscoatings.com", ), ) ``` ```csharp ManagedPayout using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.AddApplicationAsync( new ApplicationDataPayIn { AnnualRevenue = 750000, Baddress = "789 Industrial Parkway", Baddress1 = "Unit 12", BankData = new List(){ new Bank { AccountNumber = "1XXXXXX3100", BankAccountFunction = 1, BankAccountHolderName = "Herman's Coatings LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "First Miami Bank", Nickname = "Withdrawal Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "123-456" }, new Bank { AccountNumber = "1XXXXXX3200", BankAccountFunction = 0, BankAccountHolderName = "Herman's Coatings LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "First Miami Bank", Nickname = "Deposit Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "123-789" }, new Bank { AccountNumber = "1XXXXXX3123", BankAccountFunction = 3, BankAccountHolderName = "Herman's Coatings LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "First Miami Bank", Nickname = "Remittance Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "123-100" }, } , Bcity = "Miami", Bcountry = "US", Bstate = "FL", Bsummary = "Commercial and industrial coating services, including protective and decorative coatings", Btype = OwnType.LimitedLiabilityCompany, Bzip = "33101", Contacts = new List(){ new ApplicationDataPayInContactsItem { ContactEmail = "herman@hermanscoatings.com", ContactName = "Herman Martinez", ContactPhone = "3055550000", ContactTitle = "Owner" }, } , Ein = "123456789", Faxnumber = "3055550001", License = "FL123456", Licstate = "FL", Maddress = "789 Industrial Parkway", Maddress1 = "Unit 12", Mcc = "1799", Mcity = "Miami", Mcountry = "US", Mstate = "FL", Mzip = "33101", OrgId = 123L, Ownership = new List(){ new ApplicationDataPayInOwnershipItem { Oaddress = "123 Palm Avenue", Ocity = "Miami", Ocountry = "US", Odriverstate = "FL", Ostate = "FL", Ownerdob = "05/15/1980", Ownerdriver = "FL789456", Owneremail = "herman@hermanscoatings.com", Ownername = "Herman Martinez", Ownerpercent = 100, Ownerphone1 = "3055550000", Ownerphone2 = "3055550002", Ownerssn = "123456789", Ownertitle = "Owner", Ozip = "33102" }, } , Phonenumber = "3055550000", RecipientEmail = "herman@hermanscoatings.com", RecipientEmailNotification = true, Resumable = true, Signer = new SignerDataRequest { Address = "33 North St", Address1 = "STE 900", City = "Bristol", Country = "US", Dob = "01/01/1976", Email = "test@email.com", Name = "John Smith", Phone = "555888111", Ssn = "123456789", State = "TN", Zip = "55555", PciAttestation = true, SignedDocumentReference = "https://example.com/signed-document.pdf", AttestationDate = "04/20/2025", SignDate = "04/20/2025", AdditionalData = new Dictionary(){ ["deviceId"] = "499585-389fj484-3jcj8hj3", ["session"] = "fifji4-fiu443-fn4843", ["timeWithCompany"] = "6 Years", } }, Startdate = "01/01/2015", TemplateId = 22L, Website = "www.hermanscoatings.com" } ); } } ``` ```go ManagedPayout package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/app" payload := strings.NewReader("{\n \"annualRevenue\": 750000,\n \"baddress\": \"789 Industrial Parkway\",\n \"baddress1\": \"Unit 12\",\n \"bankData\": [\n {\n \"accountNumber\": \"1XXXXXX3100\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n },\n {\n \"accountNumber\": \"1XXXXXX3200\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-789\"\n },\n {\n \"accountNumber\": \"1XXXXXX3123\",\n \"bankAccountFunction\": 3,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Remittance Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-100\"\n }\n ],\n \"bcity\": \"Miami\",\n \"bcountry\": \"US\",\n \"bstate\": \"FL\",\n \"bsummary\": \"Commercial and industrial coating services, including protective and decorative coatings\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33101\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"dbaname\": \"Herman's Coatings\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"3055550001\",\n \"legalname\": \"Herman's Coatings LLC\",\n \"license\": \"FL123456\",\n \"licstate\": \"FL\",\n \"maddress\": \"789 Industrial Parkway\",\n \"maddress1\": \"Unit 12\",\n \"mcc\": \"1799\",\n \"mcity\": \"Miami\",\n \"mcountry\": \"US\",\n \"mstate\": \"FL\",\n \"mzip\": \"33101\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"123 Palm Avenue\",\n \"ocity\": \"Miami\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"FL\",\n \"ostate\": \"FL\",\n \"ownerdob\": \"05/15/1980\",\n \"ownerdriver\": \"FL789456\",\n \"owneremail\": \"herman@hermanscoatings.com\",\n \"ownername\": \"Herman Martinez\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"3055550000\",\n \"ownerphone2\": \"3055550002\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"Owner\",\n \"ozip\": \"33102\"\n }\n ],\n \"phonenumber\": \"3055550000\",\n \"recipientEmail\": \"herman@hermanscoatings.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/2015\",\n \"taxfillname\": \"Herman's Coatings LLC\",\n \"templateId\": 22,\n \"website\": \"www.hermanscoatings.com\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ManagedPayout require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/app") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"annualRevenue\": 750000,\n \"baddress\": \"789 Industrial Parkway\",\n \"baddress1\": \"Unit 12\",\n \"bankData\": [\n {\n \"accountNumber\": \"1XXXXXX3100\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n },\n {\n \"accountNumber\": \"1XXXXXX3200\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-789\"\n },\n {\n \"accountNumber\": \"1XXXXXX3123\",\n \"bankAccountFunction\": 3,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Remittance Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-100\"\n }\n ],\n \"bcity\": \"Miami\",\n \"bcountry\": \"US\",\n \"bstate\": \"FL\",\n \"bsummary\": \"Commercial and industrial coating services, including protective and decorative coatings\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33101\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"dbaname\": \"Herman's Coatings\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"3055550001\",\n \"legalname\": \"Herman's Coatings LLC\",\n \"license\": \"FL123456\",\n \"licstate\": \"FL\",\n \"maddress\": \"789 Industrial Parkway\",\n \"maddress1\": \"Unit 12\",\n \"mcc\": \"1799\",\n \"mcity\": \"Miami\",\n \"mcountry\": \"US\",\n \"mstate\": \"FL\",\n \"mzip\": \"33101\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"123 Palm Avenue\",\n \"ocity\": \"Miami\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"FL\",\n \"ostate\": \"FL\",\n \"ownerdob\": \"05/15/1980\",\n \"ownerdriver\": \"FL789456\",\n \"owneremail\": \"herman@hermanscoatings.com\",\n \"ownername\": \"Herman Martinez\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"3055550000\",\n \"ownerphone2\": \"3055550002\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"Owner\",\n \"ozip\": \"33102\"\n }\n ],\n \"phonenumber\": \"3055550000\",\n \"recipientEmail\": \"herman@hermanscoatings.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/2015\",\n \"taxfillname\": \"Herman's Coatings LLC\",\n \"templateId\": 22,\n \"website\": \"www.hermanscoatings.com\"\n}" response = http.request(request) puts response.read_body ``` ```java ManagedPayout import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Boarding/app") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"annualRevenue\": 750000,\n \"baddress\": \"789 Industrial Parkway\",\n \"baddress1\": \"Unit 12\",\n \"bankData\": [\n {\n \"accountNumber\": \"1XXXXXX3100\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n },\n {\n \"accountNumber\": \"1XXXXXX3200\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-789\"\n },\n {\n \"accountNumber\": \"1XXXXXX3123\",\n \"bankAccountFunction\": 3,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Remittance Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-100\"\n }\n ],\n \"bcity\": \"Miami\",\n \"bcountry\": \"US\",\n \"bstate\": \"FL\",\n \"bsummary\": \"Commercial and industrial coating services, including protective and decorative coatings\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33101\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"dbaname\": \"Herman's Coatings\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"3055550001\",\n \"legalname\": \"Herman's Coatings LLC\",\n \"license\": \"FL123456\",\n \"licstate\": \"FL\",\n \"maddress\": \"789 Industrial Parkway\",\n \"maddress1\": \"Unit 12\",\n \"mcc\": \"1799\",\n \"mcity\": \"Miami\",\n \"mcountry\": \"US\",\n \"mstate\": \"FL\",\n \"mzip\": \"33101\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"123 Palm Avenue\",\n \"ocity\": \"Miami\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"FL\",\n \"ostate\": \"FL\",\n \"ownerdob\": \"05/15/1980\",\n \"ownerdriver\": \"FL789456\",\n \"owneremail\": \"herman@hermanscoatings.com\",\n \"ownername\": \"Herman Martinez\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"3055550000\",\n \"ownerphone2\": \"3055550002\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"Owner\",\n \"ozip\": \"33102\"\n }\n ],\n \"phonenumber\": \"3055550000\",\n \"recipientEmail\": \"herman@hermanscoatings.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/2015\",\n \"taxfillname\": \"Herman's Coatings LLC\",\n \"templateId\": 22,\n \"website\": \"www.hermanscoatings.com\"\n}") .asString(); ``` ```php ManagedPayout request('POST', 'https://api-sandbox.payabli.com/api/Boarding/app', [ 'body' => '{ "annualRevenue": 750000, "baddress": "789 Industrial Parkway", "baddress1": "Unit 12", "bankData": [ { "accountNumber": "1XXXXXX3100", "bankAccountFunction": 1, "bankAccountHolderName": "Herman\'s Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Withdrawal Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-456" }, { "accountNumber": "1XXXXXX3200", "bankAccountFunction": 0, "bankAccountHolderName": "Herman\'s Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Deposit Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-789" }, { "accountNumber": "1XXXXXX3123", "bankAccountFunction": 3, "bankAccountHolderName": "Herman\'s Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Remittance Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-100" } ], "bcity": "Miami", "bcountry": "US", "bstate": "FL", "bsummary": "Commercial and industrial coating services, including protective and decorative coatings", "btype": "Limited Liability Company", "bzip": "33101", "contacts": [ { "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" } ], "dbaname": "Herman\'s Coatings", "ein": "123456789", "faxnumber": "3055550001", "legalname": "Herman\'s Coatings LLC", "license": "FL123456", "licstate": "FL", "maddress": "789 Industrial Parkway", "maddress1": "Unit 12", "mcc": "1799", "mcity": "Miami", "mcountry": "US", "mstate": "FL", "mzip": "33101", "orgId": 123, "ownership": [ { "oaddress": "123 Palm Avenue", "ocity": "Miami", "ocountry": "US", "odriverstate": "FL", "ostate": "FL", "ownerdob": "05/15/1980", "ownerdriver": "FL789456", "owneremail": "herman@hermanscoatings.com", "ownername": "Herman Martinez", "ownerpercent": 100, "ownerphone1": "3055550000", "ownerphone2": "3055550002", "ownerssn": "123456789", "ownertitle": "Owner", "ozip": "33102" } ], "phonenumber": "3055550000", "recipientEmail": "herman@hermanscoatings.com", "recipientEmailNotification": true, "resumable": true, "signer": { "address": "33 North St", "address1": "STE 900", "city": "Bristol", "country": "US", "dob": "01/01/1976", "email": "test@email.com", "name": "John Smith", "phone": "555888111", "ssn": "123456789", "state": "TN", "zip": "55555", "pciAttestation": true, "signedDocumentReference": "https://example.com/signed-document.pdf", "attestationDate": "04/20/2025", "signDate": "04/20/2025", "additionalData": { "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" } }, "startdate": "01/01/2015", "taxfillname": "Herman\'s Coatings LLC", "templateId": 22, "website": "www.hermanscoatings.com" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ManagedPayout import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "annualRevenue": 750000, "baddress": "789 Industrial Parkway", "baddress1": "Unit 12", "bankData": [ [ "accountNumber": "1XXXXXX3100", "bankAccountFunction": 1, "bankAccountHolderName": "Herman's Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Withdrawal Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-456" ], [ "accountNumber": "1XXXXXX3200", "bankAccountFunction": 0, "bankAccountHolderName": "Herman's Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Deposit Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-789" ], [ "accountNumber": "1XXXXXX3123", "bankAccountFunction": 3, "bankAccountHolderName": "Herman's Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Remittance Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-100" ] ], "bcity": "Miami", "bcountry": "US", "bstate": "FL", "bsummary": "Commercial and industrial coating services, including protective and decorative coatings", "btype": "Limited Liability Company", "bzip": "33101", "contacts": [ [ "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" ] ], "dbaname": "Herman's Coatings", "ein": "123456789", "faxnumber": "3055550001", "legalname": "Herman's Coatings LLC", "license": "FL123456", "licstate": "FL", "maddress": "789 Industrial Parkway", "maddress1": "Unit 12", "mcc": "1799", "mcity": "Miami", "mcountry": "US", "mstate": "FL", "mzip": "33101", "orgId": 123, "ownership": [ [ "oaddress": "123 Palm Avenue", "ocity": "Miami", "ocountry": "US", "odriverstate": "FL", "ostate": "FL", "ownerdob": "05/15/1980", "ownerdriver": "FL789456", "owneremail": "herman@hermanscoatings.com", "ownername": "Herman Martinez", "ownerpercent": 100, "ownerphone1": "3055550000", "ownerphone2": "3055550002", "ownerssn": "123456789", "ownertitle": "Owner", "ozip": "33102" ] ], "phonenumber": "3055550000", "recipientEmail": "herman@hermanscoatings.com", "recipientEmailNotification": true, "resumable": true, "signer": [ "address": "33 North St", "address1": "STE 900", "city": "Bristol", "country": "US", "dob": "01/01/1976", "email": "test@email.com", "name": "John Smith", "phone": "555888111", "ssn": "123456789", "state": "TN", "zip": "55555", "pciAttestation": true, "signedDocumentReference": "https://example.com/signed-document.pdf", "attestationDate": "04/20/2025", "signDate": "04/20/2025", "additionalData": [ "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" ] ], "startdate": "01/01/2015", "taxfillname": "Herman's Coatings LLC", "templateId": 22, "website": "www.hermanscoatings.com" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/app")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript OnDemandPayout import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.addApplication({ services: { ach: { acceptCCD: true, acceptPPD: true, acceptWeb: true, }, card: { acceptAmex: true, acceptDiscover: true, acceptMastercard: true, acceptVisa: true, }, odp: { allowAch: true, allowChecks: true, allowVCard: true, processing_region: "US", processor: "tsys", issuerNetworkSettingsId: "12345678901234", }, }, annualRevenue: 750000, baddress: "789 Industrial Parkway", baddress1: "Unit 12", bankData: [ { accountNumber: "1XXXXXX3100", bankAccountFunction: 1, bankAccountHolderName: "Herman's Coatings LLC", bankAccountHolderType: "Business", bankName: "First Miami Bank", nickname: "Withdrawal Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "333-789", }, { accountNumber: "1XXXXXX3200", bankAccountFunction: 0, bankAccountHolderName: "Herman's Coatings LLC", bankAccountHolderType: "Business", bankName: "First Miami Bank", nickname: "Deposit Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "333-234", }, { accountNumber: "1XXXXXX3123", bankAccountFunction: 3, bankAccountHolderName: "Herman's Coatings LLC", bankAccountHolderType: "Business", bankName: "First Miami Bank", nickname: "Remittance Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "333-567", }, ], bcity: "Miami", bcountry: "US", bstate: "FL", bsummary: "Commercial and industrial coating services, including protective and decorative coatings", btype: "Limited Liability Company", bzip: "33101", contacts: [ { contactEmail: "herman@hermanscoatings.com", contactName: "Herman Martinez", contactPhone: "3055550000", contactTitle: "Owner", }, ], ein: "123456789", faxnumber: "3055550001", highticketamt: 15000, license: "FL123456", licstate: "FL", maddress: "789 Industrial Parkway", maddress1: "Unit 12", mcc: "1799", mcity: "Miami", mcountry: "US", mstate: "FL", mzip: "33101", orgId: 123, ownership: [ { oaddress: "123 Palm Avenue", ocity: "Miami", ocountry: "US", odriverstate: "FL", ostate: "FL", ownerdob: "05/15/1980", ownerdriver: "FL789456", owneremail: "herman@hermanscoatings.com", ownername: "Herman Martinez", ownerpercent: 100, ownerphone1: "3055550000", ownerphone2: "3055550002", ownerssn: "123456789", ownertitle: "Owner", ozip: "33102", }, ], phonenumber: "3055550000", recipientEmail: "herman@hermanscoatings.com", recipientEmailNotification: true, resumable: true, signer: { address: "33 North St", address1: "STE 900", city: "Bristol", country: "US", dob: "01/01/1976", email: "test@email.com", name: "John Smith", phone: "555888111", ssn: "123456789", state: "TN", zip: "55555", pciAttestation: true, signedDocumentReference: "https://example.com/signed-document.pdf", attestationDate: "04/20/2025", signDate: "04/20/2025", additionalData: { "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years", }, }, startdate: "01/01/2015", templateId: 22, website: "www.hermanscoatings.com", }); } main(); ``` ```python OnDemandPayout from payabli import payabli, ApplicationDataPayIn, ApplicationDataPayInServices, ApplicationDataPayInServicesAch, ApplicationDataPayInServicesCard, OdpSetup, Bank, ApplicationDataPayInContactsItem, ApplicationDataPayInOwnershipItem, SignerDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.add_application( request=ApplicationDataPayIn( services=ApplicationDataPayInServices( ach=ApplicationDataPayInServicesAch( accept_ccd=True, accept_ppd=True, accept_web=True, ), card=ApplicationDataPayInServicesCard( accept_amex=True, accept_discover=True, accept_mastercard=True, accept_visa=True, ), odp=OdpSetup( allow_ach=True, allow_checks=True, allow_v_card=True, processing_region="US", processor="tsys", issuer_network_settings_id="12345678901234", ), ), annual_revenue=750000, baddress="789 Industrial Parkway", baddress_1="Unit 12", bank_data=[ Bank( account_number="1XXXXXX3100", bank_account_function=1, bank_account_holder_name="Herman\'s Coatings LLC", bank_account_holder_type="Business", bank_name="First Miami Bank", nickname="Withdrawal Account", routing_account="123123123", type_account="Checking", account_id="333-789", ), Bank( account_number="1XXXXXX3200", bank_account_function=0, bank_account_holder_name="Herman\'s Coatings LLC", bank_account_holder_type="Business", bank_name="First Miami Bank", nickname="Deposit Account", routing_account="123123123", type_account="Checking", account_id="333-234", ), Bank( account_number="1XXXXXX3123", bank_account_function=3, bank_account_holder_name="Herman\'s Coatings LLC", bank_account_holder_type="Business", bank_name="First Miami Bank", nickname="Remittance Account", routing_account="123123123", type_account="Checking", account_id="333-567", ) ], bcity="Miami", bcountry="US", bstate="FL", bsummary="Commercial and industrial coating services, including protective and decorative coatings", btype="Limited Liability Company", bzip="33101", contacts=[ ApplicationDataPayInContactsItem( contact_email="herman@hermanscoatings.com", contact_name="Herman Martinez", contact_phone="3055550000", contact_title="Owner", ) ], ein="123456789", faxnumber="3055550001", highticketamt=15000, license="FL123456", licstate="FL", maddress="789 Industrial Parkway", maddress_1="Unit 12", mcc="1799", mcity="Miami", mcountry="US", mstate="FL", mzip="33101", org_id=123, ownership=[ ApplicationDataPayInOwnershipItem( oaddress="123 Palm Avenue", ocity="Miami", ocountry="US", odriverstate="FL", ostate="FL", ownerdob="05/15/1980", ownerdriver="FL789456", owneremail="herman@hermanscoatings.com", ownername="Herman Martinez", ownerpercent=100, ownerphone_1="3055550000", ownerphone_2="3055550002", ownerssn="123456789", ownertitle="Owner", ozip="33102", ) ], phonenumber="3055550000", recipient_email="herman@hermanscoatings.com", recipient_email_notification=True, resumable=True, signer=SignerDataRequest( address="33 North St", address_1="STE 900", city="Bristol", country="US", dob="01/01/1976", email="test@email.com", name="John Smith", phone="555888111", ssn="123456789", state="TN", zip="55555", pci_attestation=True, signed_document_reference="https://example.com/signed-document.pdf", attestation_date="04/20/2025", sign_date="04/20/2025", additional_data={ "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" }, ), startdate="01/01/2015", template_id=22, website="www.hermanscoatings.com", ), ) ``` ```csharp OnDemandPayout using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.AddApplicationAsync( new ApplicationDataPayIn { Services = new ApplicationDataPayInServices { Ach = new ApplicationDataPayInServicesAch { AcceptCcd = true, AcceptPpd = true, AcceptWeb = true }, Card = new ApplicationDataPayInServicesCard { AcceptAmex = true, AcceptDiscover = true, AcceptMastercard = true, AcceptVisa = true }, Odp = new OdpSetup { AllowAch = true, AllowChecks = true, AllowVCard = true, ProcessingRegion = OdpSetupProcessingRegion.Us, Processor = "tsys", IssuerNetworkSettingsId = "12345678901234" } }, AnnualRevenue = 750000, Baddress = "789 Industrial Parkway", Baddress1 = "Unit 12", BankData = new List(){ new Bank { AccountNumber = "1XXXXXX3100", BankAccountFunction = 1, BankAccountHolderName = "Herman's Coatings LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "First Miami Bank", Nickname = "Withdrawal Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "333-789" }, new Bank { AccountNumber = "1XXXXXX3200", BankAccountFunction = 0, BankAccountHolderName = "Herman's Coatings LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "First Miami Bank", Nickname = "Deposit Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "333-234" }, new Bank { AccountNumber = "1XXXXXX3123", BankAccountFunction = 3, BankAccountHolderName = "Herman's Coatings LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "First Miami Bank", Nickname = "Remittance Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "333-567" }, } , Bcity = "Miami", Bcountry = "US", Bstate = "FL", Bsummary = "Commercial and industrial coating services, including protective and decorative coatings", Btype = OwnType.LimitedLiabilityCompany, Bzip = "33101", Contacts = new List(){ new ApplicationDataPayInContactsItem { ContactEmail = "herman@hermanscoatings.com", ContactName = "Herman Martinez", ContactPhone = "3055550000", ContactTitle = "Owner" }, } , Ein = "123456789", Faxnumber = "3055550001", Highticketamt = 15000, License = "FL123456", Licstate = "FL", Maddress = "789 Industrial Parkway", Maddress1 = "Unit 12", Mcc = "1799", Mcity = "Miami", Mcountry = "US", Mstate = "FL", Mzip = "33101", OrgId = 123L, Ownership = new List(){ new ApplicationDataPayInOwnershipItem { Oaddress = "123 Palm Avenue", Ocity = "Miami", Ocountry = "US", Odriverstate = "FL", Ostate = "FL", Ownerdob = "05/15/1980", Ownerdriver = "FL789456", Owneremail = "herman@hermanscoatings.com", Ownername = "Herman Martinez", Ownerpercent = 100, Ownerphone1 = "3055550000", Ownerphone2 = "3055550002", Ownerssn = "123456789", Ownertitle = "Owner", Ozip = "33102" }, } , Phonenumber = "3055550000", RecipientEmail = "herman@hermanscoatings.com", RecipientEmailNotification = true, Resumable = true, Signer = new SignerDataRequest { Address = "33 North St", Address1 = "STE 900", City = "Bristol", Country = "US", Dob = "01/01/1976", Email = "test@email.com", Name = "John Smith", Phone = "555888111", Ssn = "123456789", State = "TN", Zip = "55555", PciAttestation = true, SignedDocumentReference = "https://example.com/signed-document.pdf", AttestationDate = "04/20/2025", SignDate = "04/20/2025", AdditionalData = new Dictionary(){ ["deviceId"] = "499585-389fj484-3jcj8hj3", ["session"] = "fifji4-fiu443-fn4843", ["timeWithCompany"] = "6 Years", } }, Startdate = "01/01/2015", TemplateId = 22L, Website = "www.hermanscoatings.com" } ); } } ``` ```go OnDemandPayout package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/app" payload := strings.NewReader("{\n \"services\": {\n \"ach\": {\n \"acceptCCD\": true,\n \"acceptPPD\": true,\n \"acceptWeb\": true\n },\n \"card\": {\n \"acceptAmex\": true,\n \"acceptDiscover\": true,\n \"acceptMastercard\": true,\n \"acceptVisa\": true\n },\n \"odp\": {\n \"allowAch\": true,\n \"allowChecks\": true,\n \"allowVCard\": true,\n \"processing_region\": \"US\",\n \"processor\": \"tsys\",\n \"issuerNetworkSettingsId\": \"12345678901234\"\n }\n },\n \"annualRevenue\": 750000,\n \"baddress\": \"789 Industrial Parkway\",\n \"baddress1\": \"Unit 12\",\n \"bankData\": [\n {\n \"accountNumber\": \"1XXXXXX3100\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"333-789\"\n },\n {\n \"accountNumber\": \"1XXXXXX3200\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"333-234\"\n },\n {\n \"accountNumber\": \"1XXXXXX3123\",\n \"bankAccountFunction\": 3,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Remittance Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"333-567\"\n }\n ],\n \"bcity\": \"Miami\",\n \"bcountry\": \"US\",\n \"bstate\": \"FL\",\n \"bsummary\": \"Commercial and industrial coating services, including protective and decorative coatings\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33101\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"dbaname\": \"Herman's Coatings\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"3055550001\",\n \"highticketamt\": 15000,\n \"legalname\": \"Herman's Coatings LLC\",\n \"license\": \"FL123456\",\n \"licstate\": \"FL\",\n \"maddress\": \"789 Industrial Parkway\",\n \"maddress1\": \"Unit 12\",\n \"mcc\": \"1799\",\n \"mcity\": \"Miami\",\n \"mcountry\": \"US\",\n \"mstate\": \"FL\",\n \"mzip\": \"33101\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"123 Palm Avenue\",\n \"ocity\": \"Miami\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"FL\",\n \"ostate\": \"FL\",\n \"ownerdob\": \"05/15/1980\",\n \"ownerdriver\": \"FL789456\",\n \"owneremail\": \"herman@hermanscoatings.com\",\n \"ownername\": \"Herman Martinez\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"3055550000\",\n \"ownerphone2\": \"3055550002\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"Owner\",\n \"ozip\": \"33102\"\n }\n ],\n \"payoutAverageMonthlyVolume\": 50000,\n \"payoutAverageTicketAmount\": 3500,\n \"payoutCreditLimit\": 25000,\n \"payoutHighTicketAmount\": 15000,\n \"phonenumber\": \"3055550000\",\n \"recipientEmail\": \"herman@hermanscoatings.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/2015\",\n \"taxfillname\": \"Herman's Coatings LLC\",\n \"templateId\": 22,\n \"website\": \"www.hermanscoatings.com\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby OnDemandPayout require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/app") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"services\": {\n \"ach\": {\n \"acceptCCD\": true,\n \"acceptPPD\": true,\n \"acceptWeb\": true\n },\n \"card\": {\n \"acceptAmex\": true,\n \"acceptDiscover\": true,\n \"acceptMastercard\": true,\n \"acceptVisa\": true\n },\n \"odp\": {\n \"allowAch\": true,\n \"allowChecks\": true,\n \"allowVCard\": true,\n \"processing_region\": \"US\",\n \"processor\": \"tsys\",\n \"issuerNetworkSettingsId\": \"12345678901234\"\n }\n },\n \"annualRevenue\": 750000,\n \"baddress\": \"789 Industrial Parkway\",\n \"baddress1\": \"Unit 12\",\n \"bankData\": [\n {\n \"accountNumber\": \"1XXXXXX3100\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"333-789\"\n },\n {\n \"accountNumber\": \"1XXXXXX3200\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"333-234\"\n },\n {\n \"accountNumber\": \"1XXXXXX3123\",\n \"bankAccountFunction\": 3,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Remittance Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"333-567\"\n }\n ],\n \"bcity\": \"Miami\",\n \"bcountry\": \"US\",\n \"bstate\": \"FL\",\n \"bsummary\": \"Commercial and industrial coating services, including protective and decorative coatings\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33101\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"dbaname\": \"Herman's Coatings\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"3055550001\",\n \"highticketamt\": 15000,\n \"legalname\": \"Herman's Coatings LLC\",\n \"license\": \"FL123456\",\n \"licstate\": \"FL\",\n \"maddress\": \"789 Industrial Parkway\",\n \"maddress1\": \"Unit 12\",\n \"mcc\": \"1799\",\n \"mcity\": \"Miami\",\n \"mcountry\": \"US\",\n \"mstate\": \"FL\",\n \"mzip\": \"33101\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"123 Palm Avenue\",\n \"ocity\": \"Miami\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"FL\",\n \"ostate\": \"FL\",\n \"ownerdob\": \"05/15/1980\",\n \"ownerdriver\": \"FL789456\",\n \"owneremail\": \"herman@hermanscoatings.com\",\n \"ownername\": \"Herman Martinez\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"3055550000\",\n \"ownerphone2\": \"3055550002\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"Owner\",\n \"ozip\": \"33102\"\n }\n ],\n \"payoutAverageMonthlyVolume\": 50000,\n \"payoutAverageTicketAmount\": 3500,\n \"payoutCreditLimit\": 25000,\n \"payoutHighTicketAmount\": 15000,\n \"phonenumber\": \"3055550000\",\n \"recipientEmail\": \"herman@hermanscoatings.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/2015\",\n \"taxfillname\": \"Herman's Coatings LLC\",\n \"templateId\": 22,\n \"website\": \"www.hermanscoatings.com\"\n}" response = http.request(request) puts response.read_body ``` ```java OnDemandPayout import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Boarding/app") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"services\": {\n \"ach\": {\n \"acceptCCD\": true,\n \"acceptPPD\": true,\n \"acceptWeb\": true\n },\n \"card\": {\n \"acceptAmex\": true,\n \"acceptDiscover\": true,\n \"acceptMastercard\": true,\n \"acceptVisa\": true\n },\n \"odp\": {\n \"allowAch\": true,\n \"allowChecks\": true,\n \"allowVCard\": true,\n \"processing_region\": \"US\",\n \"processor\": \"tsys\",\n \"issuerNetworkSettingsId\": \"12345678901234\"\n }\n },\n \"annualRevenue\": 750000,\n \"baddress\": \"789 Industrial Parkway\",\n \"baddress1\": \"Unit 12\",\n \"bankData\": [\n {\n \"accountNumber\": \"1XXXXXX3100\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"333-789\"\n },\n {\n \"accountNumber\": \"1XXXXXX3200\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"333-234\"\n },\n {\n \"accountNumber\": \"1XXXXXX3123\",\n \"bankAccountFunction\": 3,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"nickname\": \"Remittance Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"333-567\"\n }\n ],\n \"bcity\": \"Miami\",\n \"bcountry\": \"US\",\n \"bstate\": \"FL\",\n \"bsummary\": \"Commercial and industrial coating services, including protective and decorative coatings\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33101\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"dbaname\": \"Herman's Coatings\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"3055550001\",\n \"highticketamt\": 15000,\n \"legalname\": \"Herman's Coatings LLC\",\n \"license\": \"FL123456\",\n \"licstate\": \"FL\",\n \"maddress\": \"789 Industrial Parkway\",\n \"maddress1\": \"Unit 12\",\n \"mcc\": \"1799\",\n \"mcity\": \"Miami\",\n \"mcountry\": \"US\",\n \"mstate\": \"FL\",\n \"mzip\": \"33101\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"123 Palm Avenue\",\n \"ocity\": \"Miami\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"FL\",\n \"ostate\": \"FL\",\n \"ownerdob\": \"05/15/1980\",\n \"ownerdriver\": \"FL789456\",\n \"owneremail\": \"herman@hermanscoatings.com\",\n \"ownername\": \"Herman Martinez\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"3055550000\",\n \"ownerphone2\": \"3055550002\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"Owner\",\n \"ozip\": \"33102\"\n }\n ],\n \"payoutAverageMonthlyVolume\": 50000,\n \"payoutAverageTicketAmount\": 3500,\n \"payoutCreditLimit\": 25000,\n \"payoutHighTicketAmount\": 15000,\n \"phonenumber\": \"3055550000\",\n \"recipientEmail\": \"herman@hermanscoatings.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/2015\",\n \"taxfillname\": \"Herman's Coatings LLC\",\n \"templateId\": 22,\n \"website\": \"www.hermanscoatings.com\"\n}") .asString(); ``` ```php OnDemandPayout request('POST', 'https://api-sandbox.payabli.com/api/Boarding/app', [ 'body' => '{ "services": { "ach": { "acceptCCD": true, "acceptPPD": true, "acceptWeb": true }, "card": { "acceptAmex": true, "acceptDiscover": true, "acceptMastercard": true, "acceptVisa": true }, "odp": { "allowAch": true, "allowChecks": true, "allowVCard": true, "processing_region": "US", "processor": "tsys", "issuerNetworkSettingsId": "12345678901234" } }, "annualRevenue": 750000, "baddress": "789 Industrial Parkway", "baddress1": "Unit 12", "bankData": [ { "accountNumber": "1XXXXXX3100", "bankAccountFunction": 1, "bankAccountHolderName": "Herman\'s Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Withdrawal Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "333-789" }, { "accountNumber": "1XXXXXX3200", "bankAccountFunction": 0, "bankAccountHolderName": "Herman\'s Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Deposit Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "333-234" }, { "accountNumber": "1XXXXXX3123", "bankAccountFunction": 3, "bankAccountHolderName": "Herman\'s Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Remittance Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "333-567" } ], "bcity": "Miami", "bcountry": "US", "bstate": "FL", "bsummary": "Commercial and industrial coating services, including protective and decorative coatings", "btype": "Limited Liability Company", "bzip": "33101", "contacts": [ { "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" } ], "dbaname": "Herman\'s Coatings", "ein": "123456789", "faxnumber": "3055550001", "highticketamt": 15000, "legalname": "Herman\'s Coatings LLC", "license": "FL123456", "licstate": "FL", "maddress": "789 Industrial Parkway", "maddress1": "Unit 12", "mcc": "1799", "mcity": "Miami", "mcountry": "US", "mstate": "FL", "mzip": "33101", "orgId": 123, "ownership": [ { "oaddress": "123 Palm Avenue", "ocity": "Miami", "ocountry": "US", "odriverstate": "FL", "ostate": "FL", "ownerdob": "05/15/1980", "ownerdriver": "FL789456", "owneremail": "herman@hermanscoatings.com", "ownername": "Herman Martinez", "ownerpercent": 100, "ownerphone1": "3055550000", "ownerphone2": "3055550002", "ownerssn": "123456789", "ownertitle": "Owner", "ozip": "33102" } ], "payoutAverageMonthlyVolume": 50000, "payoutAverageTicketAmount": 3500, "payoutCreditLimit": 25000, "payoutHighTicketAmount": 15000, "phonenumber": "3055550000", "recipientEmail": "herman@hermanscoatings.com", "recipientEmailNotification": true, "resumable": true, "signer": { "address": "33 North St", "address1": "STE 900", "city": "Bristol", "country": "US", "dob": "01/01/1976", "email": "test@email.com", "name": "John Smith", "phone": "555888111", "ssn": "123456789", "state": "TN", "zip": "55555", "pciAttestation": true, "signedDocumentReference": "https://example.com/signed-document.pdf", "attestationDate": "04/20/2025", "signDate": "04/20/2025", "additionalData": { "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" } }, "startdate": "01/01/2015", "taxfillname": "Herman\'s Coatings LLC", "templateId": 22, "website": "www.hermanscoatings.com" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift OnDemandPayout import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "services": [ "ach": [ "acceptCCD": true, "acceptPPD": true, "acceptWeb": true ], "card": [ "acceptAmex": true, "acceptDiscover": true, "acceptMastercard": true, "acceptVisa": true ], "odp": [ "allowAch": true, "allowChecks": true, "allowVCard": true, "processing_region": "US", "processor": "tsys", "issuerNetworkSettingsId": "12345678901234" ] ], "annualRevenue": 750000, "baddress": "789 Industrial Parkway", "baddress1": "Unit 12", "bankData": [ [ "accountNumber": "1XXXXXX3100", "bankAccountFunction": 1, "bankAccountHolderName": "Herman's Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Withdrawal Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "333-789" ], [ "accountNumber": "1XXXXXX3200", "bankAccountFunction": 0, "bankAccountHolderName": "Herman's Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Deposit Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "333-234" ], [ "accountNumber": "1XXXXXX3123", "bankAccountFunction": 3, "bankAccountHolderName": "Herman's Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "nickname": "Remittance Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "333-567" ] ], "bcity": "Miami", "bcountry": "US", "bstate": "FL", "bsummary": "Commercial and industrial coating services, including protective and decorative coatings", "btype": "Limited Liability Company", "bzip": "33101", "contacts": [ [ "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" ] ], "dbaname": "Herman's Coatings", "ein": "123456789", "faxnumber": "3055550001", "highticketamt": 15000, "legalname": "Herman's Coatings LLC", "license": "FL123456", "licstate": "FL", "maddress": "789 Industrial Parkway", "maddress1": "Unit 12", "mcc": "1799", "mcity": "Miami", "mcountry": "US", "mstate": "FL", "mzip": "33101", "orgId": 123, "ownership": [ [ "oaddress": "123 Palm Avenue", "ocity": "Miami", "ocountry": "US", "odriverstate": "FL", "ostate": "FL", "ownerdob": "05/15/1980", "ownerdriver": "FL789456", "owneremail": "herman@hermanscoatings.com", "ownername": "Herman Martinez", "ownerpercent": 100, "ownerphone1": "3055550000", "ownerphone2": "3055550002", "ownerssn": "123456789", "ownertitle": "Owner", "ozip": "33102" ] ], "payoutAverageMonthlyVolume": 50000, "payoutAverageTicketAmount": 3500, "payoutCreditLimit": 25000, "payoutHighTicketAmount": 15000, "phonenumber": "3055550000", "recipientEmail": "herman@hermanscoatings.com", "recipientEmailNotification": true, "resumable": true, "signer": [ "address": "33 North St", "address1": "STE 900", "city": "Bristol", "country": "US", "dob": "01/01/1976", "email": "test@email.com", "name": "John Smith", "phone": "555888111", "ssn": "123456789", "state": "TN", "zip": "55555", "pciAttestation": true, "signedDocumentReference": "https://example.com/signed-document.pdf", "attestationDate": "04/20/2025", "signDate": "04/20/2025", "additionalData": [ "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" ] ], "startdate": "01/01/2015", "taxfillname": "Herman's Coatings LLC", "templateId": 22, "website": "www.hermanscoatings.com" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/app")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript AllFields import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.addApplication({ services: { ach: { acceptCCD: true, acceptPPD: true, acceptWeb: true, }, card: { acceptAmex: true, acceptDiscover: true, acceptMastercard: true, acceptVisa: true, }, odp: { allowAch: false, allowChecks: false, allowVCard: false, }, }, annualRevenue: 750000, baddress: "789 Industrial Parkway", baddress1: "Unit 12", bankData: [ { accountNumber: "1XXXXXX3100", bankAccountFunction: 1, bankAccountHolderName: "Herman's Coatings LLC", bankAccountHolderType: "Business", bankName: "First Miami Bank", id: 123, nickname: "Withdrawal Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "123-789", }, { accountNumber: "1XXXXXX3200", bankAccountFunction: 0, bankAccountHolderName: "Herman's Coatings LLC", bankAccountHolderType: "Business", bankName: "First Miami Bank", id: 456, nickname: "Deposit Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "123-456", }, { accountNumber: "1XXXXXX3123", bankAccountFunction: 3, bankAccountHolderName: "Herman's Coatings LLC", bankAccountHolderType: "Business", bankName: "First Miami Bank", id: 987, nickname: "Remittance Account", routingAccount: "123123123", typeAccount: "Checking", accountId: "123-100", }, ], bcity: "Miami", bcountry: "US", boardingLinkId: "bl_123456", bstate: "FL", bsummary: "Commercial and industrial coating services, including protective and decorative coatings", btype: "Limited Liability Company", bzip: "33101", contacts: [ { contactEmail: "herman@hermanscoatings.com", contactName: "Herman Martinez", contactPhone: "3055550000", contactTitle: "Owner", }, ], ein: "123456789", faxnumber: "3055550001", highticketamt: 15000, license: "FL123456", licstate: "FL", maddress: "789 Industrial Parkway", maddress1: "Unit 12", mcc: "1799", mcity: "Miami", mcountry: "US", mstate: "FL", mzip: "33101", orgId: 123, ownership: [ { oaddress: "123 Palm Avenue", ocity: "Miami", ocountry: "US", odriverstate: "FL", ostate: "FL", ownerdob: "05/15/1980", ownerdriver: "FL789456", owneremail: "herman@hermanscoatings.com", ownername: "Herman Martinez", ownerpercent: 100, ownerphone1: "3055550000", ownerphone2: "3055550002", ownerssn: "123456789", ownertitle: "Owner", ozip: "33102", }, ], phonenumber: "3055550000", recipientEmail: "herman@hermanscoatings.com", recipientEmailNotification: true, resumable: true, signer: { address: "33 North St", address1: "STE 900", city: "Bristol", country: "US", dob: "01/01/1976", email: "test@email.com", name: "John Smith", phone: "555888111", ssn: "123456789", state: "TN", zip: "55555", pciAttestation: true, signedDocumentReference: "https://example.com/signed-document.pdf", attestationDate: "04/20/2025", signDate: "04/20/2025", additionalData: { "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years", }, }, startdate: "01/01/2015", templateId: 22, website: "www.hermanscoatings.com", }); } main(); ``` ```python AllFields from payabli import payabli, ApplicationDataPayIn, ApplicationDataPayInServices, ApplicationDataPayInServicesAch, ApplicationDataPayInServicesCard, OdpSetup, Bank, ApplicationDataPayInContactsItem, ApplicationDataPayInOwnershipItem, SignerDataRequest client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.add_application( request=ApplicationDataPayIn( services=ApplicationDataPayInServices( ach=ApplicationDataPayInServicesAch( accept_ccd=True, accept_ppd=True, accept_web=True, ), card=ApplicationDataPayInServicesCard( accept_amex=True, accept_discover=True, accept_mastercard=True, accept_visa=True, ), odp=OdpSetup( allow_ach=False, allow_checks=False, allow_v_card=False, ), ), annual_revenue=750000, baddress="789 Industrial Parkway", baddress_1="Unit 12", bank_data=[ Bank( account_number="1XXXXXX3100", bank_account_function=1, bank_account_holder_name="Herman\'s Coatings LLC", bank_account_holder_type="Business", bank_name="First Miami Bank", id=123, nickname="Withdrawal Account", routing_account="123123123", type_account="Checking", account_id="123-789", ), Bank( account_number="1XXXXXX3200", bank_account_function=0, bank_account_holder_name="Herman\'s Coatings LLC", bank_account_holder_type="Business", bank_name="First Miami Bank", id=456, nickname="Deposit Account", routing_account="123123123", type_account="Checking", account_id="123-456", ), Bank( account_number="1XXXXXX3123", bank_account_function=3, bank_account_holder_name="Herman\'s Coatings LLC", bank_account_holder_type="Business", bank_name="First Miami Bank", id=987, nickname="Remittance Account", routing_account="123123123", type_account="Checking", account_id="123-100", ) ], bcity="Miami", bcountry="US", boarding_link_id="bl_123456", bstate="FL", bsummary="Commercial and industrial coating services, including protective and decorative coatings", btype="Limited Liability Company", bzip="33101", contacts=[ ApplicationDataPayInContactsItem( contact_email="herman@hermanscoatings.com", contact_name="Herman Martinez", contact_phone="3055550000", contact_title="Owner", ) ], ein="123456789", faxnumber="3055550001", highticketamt=15000, license="FL123456", licstate="FL", maddress="789 Industrial Parkway", maddress_1="Unit 12", mcc="1799", mcity="Miami", mcountry="US", mstate="FL", mzip="33101", org_id=123, ownership=[ ApplicationDataPayInOwnershipItem( oaddress="123 Palm Avenue", ocity="Miami", ocountry="US", odriverstate="FL", ostate="FL", ownerdob="05/15/1980", ownerdriver="FL789456", owneremail="herman@hermanscoatings.com", ownername="Herman Martinez", ownerpercent=100, ownerphone_1="3055550000", ownerphone_2="3055550002", ownerssn="123456789", ownertitle="Owner", ozip="33102", ) ], phonenumber="3055550000", recipient_email="herman@hermanscoatings.com", recipient_email_notification=True, resumable=True, signer=SignerDataRequest( address="33 North St", address_1="STE 900", city="Bristol", country="US", dob="01/01/1976", email="test@email.com", name="John Smith", phone="555888111", ssn="123456789", state="TN", zip="55555", pci_attestation=True, signed_document_reference="https://example.com/signed-document.pdf", attestation_date="04/20/2025", sign_date="04/20/2025", additional_data={ "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" }, ), startdate="01/01/2015", template_id=22, website="www.hermanscoatings.com", ), ) ``` ```csharp AllFields using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.AddApplicationAsync( new ApplicationDataPayIn { Services = new ApplicationDataPayInServices { Ach = new ApplicationDataPayInServicesAch { AcceptCcd = true, AcceptPpd = true, AcceptWeb = true }, Card = new ApplicationDataPayInServicesCard { AcceptAmex = true, AcceptDiscover = true, AcceptMastercard = true, AcceptVisa = true }, Odp = new OdpSetup { AllowAch = false, AllowChecks = false, AllowVCard = false } }, AnnualRevenue = 750000, Baddress = "789 Industrial Parkway", Baddress1 = "Unit 12", BankData = new List(){ new Bank { AccountNumber = "1XXXXXX3100", BankAccountFunction = 1, BankAccountHolderName = "Herman's Coatings LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "First Miami Bank", Id = 123, Nickname = "Withdrawal Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "123-789" }, new Bank { AccountNumber = "1XXXXXX3200", BankAccountFunction = 0, BankAccountHolderName = "Herman's Coatings LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "First Miami Bank", Id = 456, Nickname = "Deposit Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "123-456" }, new Bank { AccountNumber = "1XXXXXX3123", BankAccountFunction = 3, BankAccountHolderName = "Herman's Coatings LLC", BankAccountHolderType = BankAccountHolderType.Business, BankName = "First Miami Bank", Id = 987, Nickname = "Remittance Account", RoutingAccount = "123123123", TypeAccount = TypeAccount.Checking, AccountId = "123-100" }, } , Bcity = "Miami", Bcountry = "US", BoardingLinkId = "bl_123456", Bstate = "FL", Bsummary = "Commercial and industrial coating services, including protective and decorative coatings", Btype = OwnType.LimitedLiabilityCompany, Bzip = "33101", Contacts = new List(){ new ApplicationDataPayInContactsItem { ContactEmail = "herman@hermanscoatings.com", ContactName = "Herman Martinez", ContactPhone = "3055550000", ContactTitle = "Owner" }, } , Ein = "123456789", Faxnumber = "3055550001", Highticketamt = 15000, License = "FL123456", Licstate = "FL", Maddress = "789 Industrial Parkway", Maddress1 = "Unit 12", Mcc = "1799", Mcity = "Miami", Mcountry = "US", Mstate = "FL", Mzip = "33101", OrgId = 123L, Ownership = new List(){ new ApplicationDataPayInOwnershipItem { Oaddress = "123 Palm Avenue", Ocity = "Miami", Ocountry = "US", Odriverstate = "FL", Ostate = "FL", Ownerdob = "05/15/1980", Ownerdriver = "FL789456", Owneremail = "herman@hermanscoatings.com", Ownername = "Herman Martinez", Ownerpercent = 100, Ownerphone1 = "3055550000", Ownerphone2 = "3055550002", Ownerssn = "123456789", Ownertitle = "Owner", Ozip = "33102" }, } , Phonenumber = "3055550000", RecipientEmail = "herman@hermanscoatings.com", RecipientEmailNotification = true, Resumable = true, Signer = new SignerDataRequest { Address = "33 North St", Address1 = "STE 900", City = "Bristol", Country = "US", Dob = "01/01/1976", Email = "test@email.com", Name = "John Smith", Phone = "555888111", Ssn = "123456789", State = "TN", Zip = "55555", PciAttestation = true, SignedDocumentReference = "https://example.com/signed-document.pdf", AttestationDate = "04/20/2025", SignDate = "04/20/2025", AdditionalData = new Dictionary(){ ["deviceId"] = "499585-389fj484-3jcj8hj3", ["session"] = "fifji4-fiu443-fn4843", ["timeWithCompany"] = "6 Years", } }, Startdate = "01/01/2015", TemplateId = 22L, Website = "www.hermanscoatings.com" } ); } } ``` ```go AllFields package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/app" payload := strings.NewReader("{\n \"services\": {\n \"ach\": {\n \"acceptCCD\": true,\n \"acceptPPD\": true,\n \"acceptWeb\": true\n },\n \"card\": {\n \"acceptAmex\": true,\n \"acceptDiscover\": true,\n \"acceptMastercard\": true,\n \"acceptVisa\": true\n },\n \"odp\": {\n \"allowAch\": false,\n \"allowChecks\": false,\n \"allowVCard\": false\n }\n },\n \"annualRevenue\": 750000,\n \"attachments\": [\n {},\n {}\n ],\n \"baddress\": \"789 Industrial Parkway\",\n \"baddress1\": \"Unit 12\",\n \"bankData\": [\n {\n \"accountNumber\": \"1XXXXXX3100\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"id\": 123,\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-789\"\n },\n {\n \"accountNumber\": \"1XXXXXX3200\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"id\": 456,\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n },\n {\n \"accountNumber\": \"1XXXXXX3123\",\n \"bankAccountFunction\": 3,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"id\": 987,\n \"nickname\": \"Remittance Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-100\"\n }\n ],\n \"bcity\": \"Miami\",\n \"bcountry\": \"US\",\n \"boardingLinkId\": \"bl_123456\",\n \"bstate\": \"FL\",\n \"bsummary\": \"Commercial and industrial coating services, including protective and decorative coatings\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33101\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"dbaname\": \"Herman's Coatings\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"3055550001\",\n \"highticketamt\": 15000,\n \"legalname\": \"Herman's Coatings LLC\",\n \"license\": \"FL123456\",\n \"licstate\": \"FL\",\n \"maddress\": \"789 Industrial Parkway\",\n \"maddress1\": \"Unit 12\",\n \"mcc\": \"1799\",\n \"mcity\": \"Miami\",\n \"mcountry\": \"US\",\n \"mstate\": \"FL\",\n \"mzip\": \"33101\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"123 Palm Avenue\",\n \"ocity\": \"Miami\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"FL\",\n \"ostate\": \"FL\",\n \"ownerdob\": \"05/15/1980\",\n \"ownerdriver\": \"FL789456\",\n \"owneremail\": \"herman@hermanscoatings.com\",\n \"ownername\": \"Herman Martinez\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"3055550000\",\n \"ownerphone2\": \"3055550002\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"Owner\",\n \"ozip\": \"33102\"\n }\n ],\n \"payoutAverageMonthlyVolume\": 50000,\n \"payoutAverageTicketAmount\": 500,\n \"payoutCreditLimit\": 25000,\n \"payoutHighTicketAmount\": 15000,\n \"phonenumber\": \"3055550000\",\n \"recipientEmail\": \"herman@hermanscoatings.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/2015\",\n \"taxfillname\": \"Herman's Coatings LLC\",\n \"templateId\": 22,\n \"website\": \"www.hermanscoatings.com\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby AllFields require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/app") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"services\": {\n \"ach\": {\n \"acceptCCD\": true,\n \"acceptPPD\": true,\n \"acceptWeb\": true\n },\n \"card\": {\n \"acceptAmex\": true,\n \"acceptDiscover\": true,\n \"acceptMastercard\": true,\n \"acceptVisa\": true\n },\n \"odp\": {\n \"allowAch\": false,\n \"allowChecks\": false,\n \"allowVCard\": false\n }\n },\n \"annualRevenue\": 750000,\n \"attachments\": [\n {},\n {}\n ],\n \"baddress\": \"789 Industrial Parkway\",\n \"baddress1\": \"Unit 12\",\n \"bankData\": [\n {\n \"accountNumber\": \"1XXXXXX3100\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"id\": 123,\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-789\"\n },\n {\n \"accountNumber\": \"1XXXXXX3200\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"id\": 456,\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n },\n {\n \"accountNumber\": \"1XXXXXX3123\",\n \"bankAccountFunction\": 3,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"id\": 987,\n \"nickname\": \"Remittance Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-100\"\n }\n ],\n \"bcity\": \"Miami\",\n \"bcountry\": \"US\",\n \"boardingLinkId\": \"bl_123456\",\n \"bstate\": \"FL\",\n \"bsummary\": \"Commercial and industrial coating services, including protective and decorative coatings\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33101\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"dbaname\": \"Herman's Coatings\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"3055550001\",\n \"highticketamt\": 15000,\n \"legalname\": \"Herman's Coatings LLC\",\n \"license\": \"FL123456\",\n \"licstate\": \"FL\",\n \"maddress\": \"789 Industrial Parkway\",\n \"maddress1\": \"Unit 12\",\n \"mcc\": \"1799\",\n \"mcity\": \"Miami\",\n \"mcountry\": \"US\",\n \"mstate\": \"FL\",\n \"mzip\": \"33101\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"123 Palm Avenue\",\n \"ocity\": \"Miami\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"FL\",\n \"ostate\": \"FL\",\n \"ownerdob\": \"05/15/1980\",\n \"ownerdriver\": \"FL789456\",\n \"owneremail\": \"herman@hermanscoatings.com\",\n \"ownername\": \"Herman Martinez\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"3055550000\",\n \"ownerphone2\": \"3055550002\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"Owner\",\n \"ozip\": \"33102\"\n }\n ],\n \"payoutAverageMonthlyVolume\": 50000,\n \"payoutAverageTicketAmount\": 500,\n \"payoutCreditLimit\": 25000,\n \"payoutHighTicketAmount\": 15000,\n \"phonenumber\": \"3055550000\",\n \"recipientEmail\": \"herman@hermanscoatings.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/2015\",\n \"taxfillname\": \"Herman's Coatings LLC\",\n \"templateId\": 22,\n \"website\": \"www.hermanscoatings.com\"\n}" response = http.request(request) puts response.read_body ``` ```java AllFields import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Boarding/app") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"services\": {\n \"ach\": {\n \"acceptCCD\": true,\n \"acceptPPD\": true,\n \"acceptWeb\": true\n },\n \"card\": {\n \"acceptAmex\": true,\n \"acceptDiscover\": true,\n \"acceptMastercard\": true,\n \"acceptVisa\": true\n },\n \"odp\": {\n \"allowAch\": false,\n \"allowChecks\": false,\n \"allowVCard\": false\n }\n },\n \"annualRevenue\": 750000,\n \"attachments\": [\n {},\n {}\n ],\n \"baddress\": \"789 Industrial Parkway\",\n \"baddress1\": \"Unit 12\",\n \"bankData\": [\n {\n \"accountNumber\": \"1XXXXXX3100\",\n \"bankAccountFunction\": 1,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"id\": 123,\n \"nickname\": \"Withdrawal Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-789\"\n },\n {\n \"accountNumber\": \"1XXXXXX3200\",\n \"bankAccountFunction\": 0,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"id\": 456,\n \"nickname\": \"Deposit Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-456\"\n },\n {\n \"accountNumber\": \"1XXXXXX3123\",\n \"bankAccountFunction\": 3,\n \"bankAccountHolderName\": \"Herman's Coatings LLC\",\n \"bankAccountHolderType\": \"Business\",\n \"bankName\": \"First Miami Bank\",\n \"id\": 987,\n \"nickname\": \"Remittance Account\",\n \"routingAccount\": \"123123123\",\n \"typeAccount\": \"Checking\",\n \"accountId\": \"123-100\"\n }\n ],\n \"bcity\": \"Miami\",\n \"bcountry\": \"US\",\n \"boardingLinkId\": \"bl_123456\",\n \"bstate\": \"FL\",\n \"bsummary\": \"Commercial and industrial coating services, including protective and decorative coatings\",\n \"btype\": \"Limited Liability Company\",\n \"bzip\": \"33101\",\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"dbaname\": \"Herman's Coatings\",\n \"ein\": \"123456789\",\n \"faxnumber\": \"3055550001\",\n \"highticketamt\": 15000,\n \"legalname\": \"Herman's Coatings LLC\",\n \"license\": \"FL123456\",\n \"licstate\": \"FL\",\n \"maddress\": \"789 Industrial Parkway\",\n \"maddress1\": \"Unit 12\",\n \"mcc\": \"1799\",\n \"mcity\": \"Miami\",\n \"mcountry\": \"US\",\n \"mstate\": \"FL\",\n \"mzip\": \"33101\",\n \"orgId\": 123,\n \"ownership\": [\n {\n \"oaddress\": \"123 Palm Avenue\",\n \"ocity\": \"Miami\",\n \"ocountry\": \"US\",\n \"odriverstate\": \"FL\",\n \"ostate\": \"FL\",\n \"ownerdob\": \"05/15/1980\",\n \"ownerdriver\": \"FL789456\",\n \"owneremail\": \"herman@hermanscoatings.com\",\n \"ownername\": \"Herman Martinez\",\n \"ownerpercent\": 100,\n \"ownerphone1\": \"3055550000\",\n \"ownerphone2\": \"3055550002\",\n \"ownerssn\": \"123456789\",\n \"ownertitle\": \"Owner\",\n \"ozip\": \"33102\"\n }\n ],\n \"payoutAverageMonthlyVolume\": 50000,\n \"payoutAverageTicketAmount\": 500,\n \"payoutCreditLimit\": 25000,\n \"payoutHighTicketAmount\": 15000,\n \"phonenumber\": \"3055550000\",\n \"recipientEmail\": \"herman@hermanscoatings.com\",\n \"recipientEmailNotification\": true,\n \"resumable\": true,\n \"signer\": {\n \"address\": \"33 North St\",\n \"address1\": \"STE 900\",\n \"city\": \"Bristol\",\n \"country\": \"US\",\n \"dob\": \"01/01/1976\",\n \"email\": \"test@email.com\",\n \"name\": \"John Smith\",\n \"phone\": \"555888111\",\n \"ssn\": \"123456789\",\n \"state\": \"TN\",\n \"zip\": \"55555\",\n \"pciAttestation\": true,\n \"signedDocumentReference\": \"https://example.com/signed-document.pdf\",\n \"attestationDate\": \"04/20/2025\",\n \"signDate\": \"04/20/2025\",\n \"additionalData\": {\n \"deviceId\": \"499585-389fj484-3jcj8hj3\",\n \"session\": \"fifji4-fiu443-fn4843\",\n \"timeWithCompany\": \"6 Years\"\n }\n },\n \"startdate\": \"01/01/2015\",\n \"taxfillname\": \"Herman's Coatings LLC\",\n \"templateId\": 22,\n \"website\": \"www.hermanscoatings.com\"\n}") .asString(); ``` ```php AllFields request('POST', 'https://api-sandbox.payabli.com/api/Boarding/app', [ 'body' => '{ "services": { "ach": { "acceptCCD": true, "acceptPPD": true, "acceptWeb": true }, "card": { "acceptAmex": true, "acceptDiscover": true, "acceptMastercard": true, "acceptVisa": true }, "odp": { "allowAch": false, "allowChecks": false, "allowVCard": false } }, "annualRevenue": 750000, "attachments": [ {}, {} ], "baddress": "789 Industrial Parkway", "baddress1": "Unit 12", "bankData": [ { "accountNumber": "1XXXXXX3100", "bankAccountFunction": 1, "bankAccountHolderName": "Herman\'s Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "id": 123, "nickname": "Withdrawal Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-789" }, { "accountNumber": "1XXXXXX3200", "bankAccountFunction": 0, "bankAccountHolderName": "Herman\'s Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "id": 456, "nickname": "Deposit Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-456" }, { "accountNumber": "1XXXXXX3123", "bankAccountFunction": 3, "bankAccountHolderName": "Herman\'s Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "id": 987, "nickname": "Remittance Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-100" } ], "bcity": "Miami", "bcountry": "US", "boardingLinkId": "bl_123456", "bstate": "FL", "bsummary": "Commercial and industrial coating services, including protective and decorative coatings", "btype": "Limited Liability Company", "bzip": "33101", "contacts": [ { "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" } ], "dbaname": "Herman\'s Coatings", "ein": "123456789", "faxnumber": "3055550001", "highticketamt": 15000, "legalname": "Herman\'s Coatings LLC", "license": "FL123456", "licstate": "FL", "maddress": "789 Industrial Parkway", "maddress1": "Unit 12", "mcc": "1799", "mcity": "Miami", "mcountry": "US", "mstate": "FL", "mzip": "33101", "orgId": 123, "ownership": [ { "oaddress": "123 Palm Avenue", "ocity": "Miami", "ocountry": "US", "odriverstate": "FL", "ostate": "FL", "ownerdob": "05/15/1980", "ownerdriver": "FL789456", "owneremail": "herman@hermanscoatings.com", "ownername": "Herman Martinez", "ownerpercent": 100, "ownerphone1": "3055550000", "ownerphone2": "3055550002", "ownerssn": "123456789", "ownertitle": "Owner", "ozip": "33102" } ], "payoutAverageMonthlyVolume": 50000, "payoutAverageTicketAmount": 500, "payoutCreditLimit": 25000, "payoutHighTicketAmount": 15000, "phonenumber": "3055550000", "recipientEmail": "herman@hermanscoatings.com", "recipientEmailNotification": true, "resumable": true, "signer": { "address": "33 North St", "address1": "STE 900", "city": "Bristol", "country": "US", "dob": "01/01/1976", "email": "test@email.com", "name": "John Smith", "phone": "555888111", "ssn": "123456789", "state": "TN", "zip": "55555", "pciAttestation": true, "signedDocumentReference": "https://example.com/signed-document.pdf", "attestationDate": "04/20/2025", "signDate": "04/20/2025", "additionalData": { "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" } }, "startdate": "01/01/2015", "taxfillname": "Herman\'s Coatings LLC", "templateId": 22, "website": "www.hermanscoatings.com" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift AllFields import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "services": [ "ach": [ "acceptCCD": true, "acceptPPD": true, "acceptWeb": true ], "card": [ "acceptAmex": true, "acceptDiscover": true, "acceptMastercard": true, "acceptVisa": true ], "odp": [ "allowAch": false, "allowChecks": false, "allowVCard": false ] ], "annualRevenue": 750000, "attachments": [[], []], "baddress": "789 Industrial Parkway", "baddress1": "Unit 12", "bankData": [ [ "accountNumber": "1XXXXXX3100", "bankAccountFunction": 1, "bankAccountHolderName": "Herman's Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "id": 123, "nickname": "Withdrawal Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-789" ], [ "accountNumber": "1XXXXXX3200", "bankAccountFunction": 0, "bankAccountHolderName": "Herman's Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "id": 456, "nickname": "Deposit Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-456" ], [ "accountNumber": "1XXXXXX3123", "bankAccountFunction": 3, "bankAccountHolderName": "Herman's Coatings LLC", "bankAccountHolderType": "Business", "bankName": "First Miami Bank", "id": 987, "nickname": "Remittance Account", "routingAccount": "123123123", "typeAccount": "Checking", "accountId": "123-100" ] ], "bcity": "Miami", "bcountry": "US", "boardingLinkId": "bl_123456", "bstate": "FL", "bsummary": "Commercial and industrial coating services, including protective and decorative coatings", "btype": "Limited Liability Company", "bzip": "33101", "contacts": [ [ "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" ] ], "dbaname": "Herman's Coatings", "ein": "123456789", "faxnumber": "3055550001", "highticketamt": 15000, "legalname": "Herman's Coatings LLC", "license": "FL123456", "licstate": "FL", "maddress": "789 Industrial Parkway", "maddress1": "Unit 12", "mcc": "1799", "mcity": "Miami", "mcountry": "US", "mstate": "FL", "mzip": "33101", "orgId": 123, "ownership": [ [ "oaddress": "123 Palm Avenue", "ocity": "Miami", "ocountry": "US", "odriverstate": "FL", "ostate": "FL", "ownerdob": "05/15/1980", "ownerdriver": "FL789456", "owneremail": "herman@hermanscoatings.com", "ownername": "Herman Martinez", "ownerpercent": 100, "ownerphone1": "3055550000", "ownerphone2": "3055550002", "ownerssn": "123456789", "ownertitle": "Owner", "ozip": "33102" ] ], "payoutAverageMonthlyVolume": 50000, "payoutAverageTicketAmount": 500, "payoutCreditLimit": 25000, "payoutHighTicketAmount": 15000, "phonenumber": "3055550000", "recipientEmail": "herman@hermanscoatings.com", "recipientEmailNotification": true, "resumable": true, "signer": [ "address": "33 North St", "address1": "STE 900", "city": "Bristol", "country": "US", "dob": "01/01/1976", "email": "test@email.com", "name": "John Smith", "phone": "555888111", "ssn": "123456789", "state": "TN", "zip": "55555", "pciAttestation": true, "signedDocumentReference": "https://example.com/signed-document.pdf", "attestationDate": "04/20/2025", "signDate": "04/20/2025", "additionalData": [ "deviceId": "499585-389fj484-3jcj8hj3", "session": "fifji4-fiu443-fn4843", "timeWithCompany": "6 Years" ] ], "startdate": "01/01/2015", "taxfillname": "Herman's Coatings LLC", "templateId": 22, "website": "www.hermanscoatings.com" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/app")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get app by ID GET https://api-sandbox.payabli.com/api/Boarding/read/{appId} Retrieves the details for a boarding application by ID. Reference: https://docs.payabli.com/developers/api-reference/boarding/get-boarding-application-by-id ## SDK Code Examples ```typescript General success response example for boarding app get. import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.getApplication(352); } main(); ``` ```python General success response example for boarding app get. from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.get_application( app_id=352, ) ``` ```csharp General success response example for boarding app get. using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.GetApplicationAsync( 352 ); } } ``` ```go General success response example for boarding app get. package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/read/352" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby General success response example for boarding app get. require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/read/352") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java General success response example for boarding app get. import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Boarding/read/352") .header("requestToken", "") .asString(); ``` ```php General success response example for boarding app get. request('GET', 'https://api-sandbox.payabli.com/api/Boarding/read/352', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift General success response example for boarding app get. import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/read/352")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List all apps for org GET https://api-sandbox.payabli.com/api/Query/boarding/{orgId} Returns a list of boarding applications for an organization. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/boarding/get-list-of-applications-for-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.listApplications(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.list_applications( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.ListApplicationsAsync( 123, new ListApplicationsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/boarding/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/boarding/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/boarding/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/boarding/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/boarding/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update app PUT https://api-sandbox.payabli.com/api/Boarding/app/{appId} Content-Type: application/json Updates a boarding application by ID. This endpoint requires an application API token. Reference: https://docs.payabli.com/developers/api-reference/boarding/update-boarding-application ## SDK Code Examples ```typescript General success response example for some boarding operations. import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.updateApplication(352, {}); } main(); ``` ```python General success response example for some boarding operations. from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.update_application( app_id=352, ) ``` ```csharp General success response example for some boarding operations. using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.UpdateApplicationAsync( 352, new ApplicationData() ); } } ``` ```go General success response example for some boarding operations. package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/app/352" payload := strings.NewReader("{}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby General success response example for some boarding operations. require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/app/352") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java General success response example for some boarding operations. import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Boarding/app/352") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php General success response example for some boarding operations. request('PUT', 'https://api-sandbox.payabli.com/api/Boarding/app/352', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift General success response example for some boarding operations. import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/app/352")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete application DELETE https://api-sandbox.payabli.com/api/Boarding/app/{appId} Deletes a boarding application by ID. Reference: https://docs.payabli.com/developers/api-reference/boarding/delete-boarding-application ## SDK Code Examples ```typescript General success response example for some boarding operations. import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.deleteApplication(352); } main(); ``` ```python General success response example for some boarding operations. from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.delete_application( app_id=352, ) ``` ```csharp General success response example for some boarding operations. using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.DeleteApplicationAsync( 352 ); } } ``` ```go General success response example for some boarding operations. package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/app/352" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby General success response example for some boarding operations. require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/app/352") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java General success response example for some boarding operations. import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Boarding/app/352") .header("requestToken", "") .asString(); ``` ```php General success response example for some boarding operations. request('DELETE', 'https://api-sandbox.payabli.com/api/Boarding/app/352', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift General success response example for some boarding operations. import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/app/352")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get application via auth token POST https://api-sandbox.payabli.com/api/Boarding/read/{xId} Content-Type: application/json Gets a boarding application by authentication information. This endpoint requires an `application` API token. Reference: https://docs.payabli.com/developers/api-reference/boarding/get-boarding-application-by-auth ## SDK Code Examples ```typescript Example import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.getApplicationByAuth("17E", { email: "admin@email.com", referenceId: "n6UCd1f1ygG7", }); } main(); ``` ```python Example from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.get_application_by_auth( x_id="17E", email="admin@email.com", reference_id="n6UCd1f1ygG7", ) ``` ```csharp Example using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.GetApplicationByAuthAsync( "17E", new RequestAppByAuth { Email = "admin@email.com", ReferenceId = "n6UCd1f1ygG7" } ); } } ``` ```go Example package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/read/17E" payload := strings.NewReader("{\n \"email\": \"admin@email.com\",\n \"referenceId\": \"n6UCd1f1ygG7\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/read/17E") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"email\": \"admin@email.com\",\n \"referenceId\": \"n6UCd1f1ygG7\"\n}" response = http.request(request) puts response.read_body ``` ```java Example import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Boarding/read/17E") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"email\": \"admin@email.com\",\n \"referenceId\": \"n6UCd1f1ygG7\"\n}") .asString(); ``` ```php Example request('POST', 'https://api-sandbox.payabli.com/api/Boarding/read/17E', [ 'body' => '{ "email": "admin@email.com", "referenceId": "n6UCd1f1ygG7" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "email": "admin@email.com", "referenceId": "n6UCd1f1ygG7" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/read/17E")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Retrieve application by link ID GET https://api-sandbox.payabli.com/api/Boarding/linkbyId/{boardingLinkId} Retrieves details for a boarding link, by ID. Reference: https://docs.payabli.com/developers/api-reference/boarding/get-boarding-link-by-id ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.getByIdLinkApplication(91); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.get_by_id_link_application( boarding_link_id=91, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.GetByIdLinkApplicationAsync( 91 ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/linkbyId/91" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/linkbyId/91") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Boarding/linkbyId/91") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Boarding/linkbyId/91', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/linkbyId/91")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get boarding link by template ID GET https://api-sandbox.payabli.com/api/Boarding/linkbyTemplate/{templateId} Get details for a boarding link using the boarding template ID. This endpoint requires an application API token. Reference: https://docs.payabli.com/developers/api-reference/boarding/get-boarding-link-by-template-id ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.getByTemplateIdLinkApplication(80); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.get_by_template_id_link_application( template_id=80, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.GetByTemplateIdLinkApplicationAsync( 80 ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/linkbyTemplate/80" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/linkbyTemplate/80") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Boarding/linkbyTemplate/80") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Boarding/linkbyTemplate/80', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/linkbyTemplate/80")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get or send boarding link PUT https://api-sandbox.payabli.com/api/Boarding/applink/{appId}/{mail2} Retrieves a link and the verification code used to log into an existing boarding application. You can also use this endpoint to send a link and referenceId for an existing boarding application to an email address. The recipient can use the referenceId and email address to access and edit the application. Reference: https://docs.payabli.com/developers/api-reference/boarding/get-link-or-email-a-link-for-a-boarding-application ## SDK Code Examples ```typescript Example Response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.getExternalApplication(352, "mail2", {}); } main(); ``` ```python Example Response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.get_external_application( app_id=352, mail_2="mail2", ) ``` ```csharp Example Response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.GetExternalApplicationAsync( 352, "mail2", new GetExternalApplicationRequest() ); } } ``` ```go Example Response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/applink/352/mail2" req, _ := http.NewRequest("PUT", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example Response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/applink/352/mail2") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example Response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Boarding/applink/352/mail2") .header("requestToken", "") .asString(); ``` ```php Example Response request('PUT', 'https://api-sandbox.payabli.com/api/Boarding/applink/352/mail2', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example Response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/applink/352/mail2")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get boarding link by reference GET https://api-sandbox.payabli.com/api/Boarding/link/{boardingLinkReference} Retrieves the details for a boarding link, by reference name. This endpoint requires an application API token. Reference: https://docs.payabli.com/developers/api-reference/boarding/get-boarding-link-by-reference ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.getLinkApplication("myorgaccountname-00091"); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.get_link_application( boarding_link_reference="myorgaccountname-00091", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.GetLinkApplicationAsync( "myorgaccountname-00091" ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Boarding/link/myorgaccountname-00091" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Boarding/link/myorgaccountname-00091") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Boarding/link/myorgaccountname-00091") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Boarding/link/myorgaccountname-00091', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Boarding/link/myorgaccountname-00091")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List all application links GET https://api-sandbox.payabli.com/api/Query/boardinglinks/{orgId} Return a list of boarding links for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/boarding/get-list-of-boarding-links-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.boarding.listBoardingLinks(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.boarding.list_boarding_links( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Boarding.ListBoardingLinksAsync( 123, new ListBoardingLinksRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/boardinglinks/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/boardinglinks/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/boardinglinks/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/boardinglinks/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/boardinglinks/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export applications GET https://api-sandbox.payabli.com/api/Export/boarding/{format}/{orgId} Export a list of boarding applications for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/boarding/export-list-of-boarding-applications-for-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportApplications("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_applications( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportApplicationsAsync( ExportFormat1.Csv, 123, new ExportApplicationsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/boarding/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/boarding/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/boarding/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/boarding/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/boarding/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create notification POST https://api-sandbox.payabli.com/api/Notification Content-Type: application/json Create a new notification or autogenerated report. Reference: https://docs.payabli.com/developers/api-reference/notification/add-notification ## SDK Code Examples ```typescript Webhook import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notification.addNotification({ content: { eventType: "CreatedApplication", }, frequency: "untilcancelled", method: "web", ownerId: 236, ownerType: 0, status: 1, target: "https://webhook.site/2871b8f8-edc7-441a-b376-98d8c8e33275", }); } main(); ``` ```python Webhook from payabli import payabli, NotificationStandardRequest, NotificationStandardRequestContent client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notification.add_notification( request=NotificationStandardRequest( content=NotificationStandardRequestContent( event_type="CreatedApplication", ), frequency="untilcancelled", method="web", owner_id=236, owner_type=0, status=1, target="https://webhook.site/2871b8f8-edc7-441a-b376-98d8c8e33275", ), ) ``` ```csharp Webhook using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notification.AddNotificationAsync( new NotificationStandardRequest { Content = new NotificationStandardRequestContent { EventType = NotificationStandardRequestContentEventType.CreatedApplication }, Frequency = NotificationStandardRequestFrequency.Untilcancelled, Method = NotificationStandardRequestMethod.Web, OwnerId = 236, OwnerType = 0, Status = 1, Target = "https://webhook.site/2871b8f8-edc7-441a-b376-98d8c8e33275" } ); } } ``` ```go Webhook package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Notification" payload := strings.NewReader("{\n \"content\": {\n \"eventType\": \"CreatedApplication\"\n },\n \"frequency\": \"untilcancelled\",\n \"method\": \"web\",\n \"ownerId\": 236,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"https://webhook.site/2871b8f8-edc7-441a-b376-98d8c8e33275\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Webhook require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Notification") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"content\": {\n \"eventType\": \"CreatedApplication\"\n },\n \"frequency\": \"untilcancelled\",\n \"method\": \"web\",\n \"ownerId\": 236,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"https://webhook.site/2871b8f8-edc7-441a-b376-98d8c8e33275\"\n}" response = http.request(request) puts response.read_body ``` ```java Webhook import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Notification") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"content\": {\n \"eventType\": \"CreatedApplication\"\n },\n \"frequency\": \"untilcancelled\",\n \"method\": \"web\",\n \"ownerId\": 236,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"https://webhook.site/2871b8f8-edc7-441a-b376-98d8c8e33275\"\n}") .asString(); ``` ```php Webhook request('POST', 'https://api-sandbox.payabli.com/api/Notification', [ 'body' => '{ "content": { "eventType": "CreatedApplication" }, "frequency": "untilcancelled", "method": "web", "ownerId": 236, "ownerType": 0, "status": 1, "target": "https://webhook.site/2871b8f8-edc7-441a-b376-98d8c8e33275" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Webhook import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "content": ["eventType": "CreatedApplication"], "frequency": "untilcancelled", "method": "web", "ownerId": 236, "ownerType": 0, "status": 1, "target": "https://webhook.site/2871b8f8-edc7-441a-b376-98d8c8e33275" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Notification")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript ApprovedPayment import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notification.addNotification({ content: { eventType: "ApprovedPayment", }, frequency: "untilcancelled", method: "web", ownerId: 236, ownerType: 0, status: 1, target: "https://cfe9dc390ce2.ngrok-free.app/webhook", }); } main(); ``` ```python ApprovedPayment from payabli import payabli, NotificationStandardRequest, NotificationStandardRequestContent client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notification.add_notification( request=NotificationStandardRequest( content=NotificationStandardRequestContent( event_type="ApprovedPayment", ), frequency="untilcancelled", method="web", owner_id=236, owner_type=0, status=1, target="https://cfe9dc390ce2.ngrok-free.app/webhook", ), ) ``` ```csharp ApprovedPayment using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notification.AddNotificationAsync( new NotificationStandardRequest { Content = new NotificationStandardRequestContent { EventType = NotificationStandardRequestContentEventType.ApprovedPayment }, Frequency = NotificationStandardRequestFrequency.Untilcancelled, Method = NotificationStandardRequestMethod.Web, OwnerId = 236, OwnerType = 0, Status = 1, Target = "https://cfe9dc390ce2.ngrok-free.app/webhook" } ); } } ``` ```go ApprovedPayment package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Notification" payload := strings.NewReader("{\n \"content\": {\n \"eventType\": \"ApprovedPayment\"\n },\n \"frequency\": \"untilcancelled\",\n \"method\": \"web\",\n \"ownerId\": 236,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"https://cfe9dc390ce2.ngrok-free.app/webhook\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ApprovedPayment require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Notification") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"content\": {\n \"eventType\": \"ApprovedPayment\"\n },\n \"frequency\": \"untilcancelled\",\n \"method\": \"web\",\n \"ownerId\": 236,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"https://cfe9dc390ce2.ngrok-free.app/webhook\"\n}" response = http.request(request) puts response.read_body ``` ```java ApprovedPayment import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Notification") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"content\": {\n \"eventType\": \"ApprovedPayment\"\n },\n \"frequency\": \"untilcancelled\",\n \"method\": \"web\",\n \"ownerId\": 236,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"https://cfe9dc390ce2.ngrok-free.app/webhook\"\n}") .asString(); ``` ```php ApprovedPayment request('POST', 'https://api-sandbox.payabli.com/api/Notification', [ 'body' => '{ "content": { "eventType": "ApprovedPayment" }, "frequency": "untilcancelled", "method": "web", "ownerId": 236, "ownerType": 0, "status": 1, "target": "https://cfe9dc390ce2.ngrok-free.app/webhook" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ApprovedPayment import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "content": ["eventType": "ApprovedPayment"], "frequency": "untilcancelled", "method": "web", "ownerId": 236, "ownerType": 0, "status": 1, "target": "https://cfe9dc390ce2.ngrok-free.app/webhook" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Notification")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript ReportExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notification.addNotification({ content: { eventType: "Report", transactionId: "0", }, ownerId: 236, ownerType: 0, status: 1, target: "admin@example.com", }); } main(); ``` ```python ReportExample from payabli import payabli, NotificationStandardRequest, NotificationStandardRequestContent client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notification.add_notification( request=NotificationStandardRequest( content=NotificationStandardRequestContent( event_type="Report", transaction_id="0", ), frequency=, method=, owner_id=236, owner_type=0, status=1, target="admin@example.com", ), ) ``` ```csharp ReportExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notification.AddNotificationAsync( new NotificationStandardRequest { Content = new NotificationStandardRequestContent { EventType = NotificationStandardRequestContentEventType.Report, TransactionId = "0" }, OwnerId = 236, OwnerType = 0, Status = 1, Target = "admin@example.com" } ); } } ``` ```go ReportExample package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Notification" payload := strings.NewReader("{\n \"content\": {\n \"eventType\": \"Report\",\n \"fileFormat\": \"json\",\n \"reportName\": \"Transaction\",\n \"timeZone\": -5,\n \"transactionId\": \"0\"\n },\n \"frequency\": \"biweekly\",\n \"method\": \"report-email\",\n \"ownerId\": 236,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"admin@example.com\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ReportExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Notification") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"content\": {\n \"eventType\": \"Report\",\n \"fileFormat\": \"json\",\n \"reportName\": \"Transaction\",\n \"timeZone\": -5,\n \"transactionId\": \"0\"\n },\n \"frequency\": \"biweekly\",\n \"method\": \"report-email\",\n \"ownerId\": 236,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"admin@example.com\"\n}" response = http.request(request) puts response.read_body ``` ```java ReportExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Notification") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"content\": {\n \"eventType\": \"Report\",\n \"fileFormat\": \"json\",\n \"reportName\": \"Transaction\",\n \"timeZone\": -5,\n \"transactionId\": \"0\"\n },\n \"frequency\": \"biweekly\",\n \"method\": \"report-email\",\n \"ownerId\": 236,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"admin@example.com\"\n}") .asString(); ``` ```php ReportExample request('POST', 'https://api-sandbox.payabli.com/api/Notification', [ 'body' => '{ "content": { "eventType": "Report", "fileFormat": "json", "reportName": "Transaction", "timeZone": -5, "transactionId": "0" }, "frequency": "biweekly", "method": "report-email", "ownerId": 236, "ownerType": 0, "status": 1, "target": "admin@example.com" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ReportExample import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "content": [ "eventType": "Report", "fileFormat": "json", "reportName": "Transaction", "timeZone": -5, "transactionId": "0" ], "frequency": "biweekly", "method": "report-email", "ownerId": 236, "ownerType": 0, "status": 1, "target": "admin@example.com" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Notification")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get notification GET https://api-sandbox.payabli.com/api/Notification/{nId} Retrieves a single notification or autogenerated report's details. Reference: https://docs.payabli.com/developers/api-reference/notification/get-notification ## SDK Code Examples ```typescript Get import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notification.getNotification("1717"); } main(); ``` ```python Get from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notification.get_notification( n_id="1717", ) ``` ```csharp Get using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notification.GetNotificationAsync( "1717" ); } } ``` ```go Get package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Notification/1717" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Get require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Notification/1717") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Get import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Notification/1717") .header("requestToken", "") .asString(); ``` ```php Get request('GET', 'https://api-sandbox.payabli.com/api/Notification/1717', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Get import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Notification/1717")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List notifications by paypoint GET https://api-sandbox.payabli.com/api/Query/notifications/{entry} Returns a list of notifications for an entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/notification/get-list-of-notifications-for-an-entrypoint ## SDK Code Examples ```typescript QueryResponseExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listNotifications("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python QueryResponseExample from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_notifications( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp QueryResponseExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListNotificationsAsync( "8cfec329267", new ListNotificationsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go QueryResponseExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/notifications/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby QueryResponseExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/notifications/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java QueryResponseExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/notifications/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php QueryResponseExample request('GET', 'https://api-sandbox.payabli.com/api/Query/notifications/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift QueryResponseExample import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/notifications/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List notifications by org GET https://api-sandbox.payabli.com/api/Query/notifications/org/{orgId} Return a list of notifications for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/notification/get-list-of-notifications-for-organization ## SDK Code Examples ```typescript QueryResponseExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listNotificationsOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python QueryResponseExample from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_notifications_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp QueryResponseExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListNotificationsOrgAsync( 123, new ListNotificationsOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go QueryResponseExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/notifications/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby QueryResponseExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/notifications/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java QueryResponseExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/notifications/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php QueryResponseExample request('GET', 'https://api-sandbox.payabli.com/api/Query/notifications/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift QueryResponseExample import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/notifications/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update notification PUT https://api-sandbox.payabli.com/api/Notification/{nId} Content-Type: application/json Update a notification or autogenerated report. Reference: https://docs.payabli.com/developers/api-reference/notification/update-notification ## SDK Code Examples ```typescript Update import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notification.updateNotification("1717", { content: { eventType: "ApprovedPayment", }, frequency: "untilcancelled", method: "email", ownerId: 136, ownerType: 0, status: 1, target: "newemail@email.com", }); } main(); ``` ```python Update from payabli import payabli, NotificationStandardRequest, NotificationStandardRequestContent client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notification.update_notification( n_id="1717", request=NotificationStandardRequest( content=NotificationStandardRequestContent( event_type="ApprovedPayment", ), frequency="untilcancelled", method="email", owner_id=136, owner_type=0, status=1, target="newemail@email.com", ), ) ``` ```csharp Update using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notification.UpdateNotificationAsync( "1717", new NotificationStandardRequest { Content = new NotificationStandardRequestContent { EventType = NotificationStandardRequestContentEventType.ApprovedPayment }, Frequency = NotificationStandardRequestFrequency.Untilcancelled, Method = NotificationStandardRequestMethod.Email, OwnerId = 136, OwnerType = 0, Status = 1, Target = "newemail@email.com" } ); } } ``` ```go Update package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Notification/1717" payload := strings.NewReader("{\n \"content\": {\n \"eventType\": \"ApprovedPayment\"\n },\n \"frequency\": \"untilcancelled\",\n \"method\": \"email\",\n \"ownerId\": 136,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"newemail@email.com\"\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Update require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Notification/1717") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"content\": {\n \"eventType\": \"ApprovedPayment\"\n },\n \"frequency\": \"untilcancelled\",\n \"method\": \"email\",\n \"ownerId\": 136,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"newemail@email.com\"\n}" response = http.request(request) puts response.read_body ``` ```java Update import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Notification/1717") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"content\": {\n \"eventType\": \"ApprovedPayment\"\n },\n \"frequency\": \"untilcancelled\",\n \"method\": \"email\",\n \"ownerId\": 136,\n \"ownerType\": 0,\n \"status\": 1,\n \"target\": \"newemail@email.com\"\n}") .asString(); ``` ```php Update request('PUT', 'https://api-sandbox.payabli.com/api/Notification/1717', [ 'body' => '{ "content": { "eventType": "ApprovedPayment" }, "frequency": "untilcancelled", "method": "email", "ownerId": 136, "ownerType": 0, "status": 1, "target": "newemail@email.com" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Update import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "content": ["eventType": "ApprovedPayment"], "frequency": "untilcancelled", "method": "email", "ownerId": 136, "ownerType": 0, "status": 1, "target": "newemail@email.com" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Notification/1717")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete notification DELETE https://api-sandbox.payabli.com/api/Notification/{nId} Deletes a single notification or autogenerated report. Reference: https://docs.payabli.com/developers/api-reference/notification/delete-notification ## SDK Code Examples ```typescript Delete import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notification.deleteNotification("1717"); } main(); ``` ```python Delete from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notification.delete_notification( n_id="1717", ) ``` ```csharp Delete using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notification.DeleteNotificationAsync( "1717" ); } } ``` ```go Delete package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Notification/1717" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Delete require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Notification/1717") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Delete import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Notification/1717") .header("requestToken", "") .asString(); ``` ```php Delete request('DELETE', 'https://api-sandbox.payabli.com/api/Notification/1717', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Delete import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Notification/1717")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List generated reports by paypoint GET https://api-sandbox.payabli.com/api/Query/notificationReports/{entry} Returns a list of all reports generated in the last 60 days for a single entrypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/notification/get-list-of-reports-generated-in-last-60-days-for-entrypoint ## SDK Code Examples ```typescript Example Response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listNotificationReports("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example Response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_notification_reports( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example Response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListNotificationReportsAsync( "8cfec329267", new ListNotificationReportsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example Response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/notificationReports/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example Response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/notificationReports/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example Response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/notificationReports/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example Response request('GET', 'https://api-sandbox.payabli.com/api/Query/notificationReports/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example Response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/notificationReports/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List generated reports by org GET https://api-sandbox.payabli.com/api/Query/notificationReports/org/{orgId} Returns a list of all reports generated in the last 60 days for an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/notification/get-list-of-reports-generated-in-last-60-days-for-organization ## SDK Code Examples ```typescript Example Response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listNotificationReportsOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python Example Response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_notification_reports_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp Example Response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListNotificationReportsOrgAsync( 123, new ListNotificationReportsOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go Example Response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/notificationReports/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example Response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/notificationReports/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example Response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/notificationReports/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php Example Response request('GET', 'https://api-sandbox.payabli.com/api/Query/notificationReports/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example Response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/notificationReports/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export generated report GET https://api-sandbox.payabli.com/api/Export/notificationReport/{Id} Gets a copy of a generated report by ID. Reference: https://docs.payabli.com/developers/api-reference/notification/get-report-file ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notification.getReportFile(1000000); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notification.get_report_file( id=1000000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notification.GetReportFileAsync( 1000000L ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/notificationReport/1000000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/notificationReport/1000000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/notificationReport/1000000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/notificationReport/1000000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/notificationReport/1000000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Search notification logs POST https://api-sandbox.payabli.com/api/v2/notificationlogs Content-Type: application/json Search notification logs with filtering and pagination. - Start date and end date cannot be more than 30 days apart - Either `orgId` or `paypointId` must be provided This endpoint requires the `notifications_create` OR `notifications_read` permission. Reference: https://docs.payabli.com/developers/api-reference/notification-logs/search-notification-logs-with-filtering-and-pagination ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notificationlogs.searchNotificationLogs({ PageSize: 20, body: { startDate: "2024-01-01T00:00:00Z", endDate: "2024-01-31T23:59:59Z", notificationEvent: "ActivatedMerchant", succeeded: true, orgId: 12345, }, }); } main(); ``` ```python from payabli import payabli import datetime client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notificationlogs.search_notification_logs( page_size=20, start_date=datetime.datetime.fromisoformat("2024-01-01T00:00:00+00:00"), end_date=datetime.datetime.fromisoformat("2024-01-31T23:59:59+00:00"), notification_event="ActivatedMerchant", succeeded=True, org_id=12345, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; using System; using System.Globalization; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notificationlogs.SearchNotificationLogsAsync( new SearchNotificationLogsRequest { PageSize = 20, Body = new NotificationLogSearchRequest { StartDate = DateTime.Parse("2024-01-01T00:00:00Z", null, DateTimeStyles.AdjustToUniversal), EndDate = DateTime.Parse("2024-01-31T23:59:59Z", null, DateTimeStyles.AdjustToUniversal), NotificationEvent = "ActivatedMerchant", Succeeded = true, OrgId = 12345L } } ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/notificationlogs?PageSize=20" payload := strings.NewReader("{\n \"startDate\": \"2024-01-01T00:00:00Z\",\n \"endDate\": \"2024-01-31T23:59:59Z\",\n \"notificationEvent\": \"ActivatedMerchant\",\n \"succeeded\": true,\n \"orgId\": 12345\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/notificationlogs?PageSize=20") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"startDate\": \"2024-01-01T00:00:00Z\",\n \"endDate\": \"2024-01-31T23:59:59Z\",\n \"notificationEvent\": \"ActivatedMerchant\",\n \"succeeded\": true,\n \"orgId\": 12345\n}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/notificationlogs?PageSize=20") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"startDate\": \"2024-01-01T00:00:00Z\",\n \"endDate\": \"2024-01-31T23:59:59Z\",\n \"notificationEvent\": \"ActivatedMerchant\",\n \"succeeded\": true,\n \"orgId\": 12345\n}") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/v2/notificationlogs?PageSize=20', [ 'body' => '{ "startDate": "2024-01-01T00:00:00Z", "endDate": "2024-01-31T23:59:59Z", "notificationEvent": "ActivatedMerchant", "succeeded": true, "orgId": 12345 }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "startDate": "2024-01-01T00:00:00Z", "endDate": "2024-01-31T23:59:59Z", "notificationEvent": "ActivatedMerchant", "succeeded": true, "orgId": 12345 ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/notificationlogs?PageSize=20")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get log entry GET https://api-sandbox.payabli.com/api/v2/notificationlogs/{uuid} Get detailed information for a specific notification log entry. This endpoint requires the `notifications_create` OR `notifications_read` permission. Reference: https://docs.payabli.com/developers/api-reference/notification-logs/get-notification-log ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notificationlogs.getNotificationLog("550e8400-e29b-41d4-a716-446655440000"); } main(); ``` ```python from payabli import payabli import uuid client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notificationlogs.get_notification_log( uuid_=uuid.UUID("550e8400-e29b-41d4-a716-446655440000"), ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notificationlogs.GetNotificationLogAsync( "550e8400-e29b-41d4-a716-446655440000" ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Retry notification GET https://api-sandbox.payabli.com/api/v2/notificationlogs/{uuid}/retry Retry sending a specific notification. **Permissions:** notifications_create Reference: https://docs.payabli.com/developers/api-reference/notification-logs/retry-notification-log ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notificationlogs.retryNotificationLog("550e8400-e29b-41d4-a716-446655440000"); } main(); ``` ```python from payabli import payabli import uuid client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notificationlogs.retry_notification_log( uuid_=uuid.UUID("550e8400-e29b-41d4-a716-446655440000"), ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notificationlogs.RetryNotificationLogAsync( "550e8400-e29b-41d4-a716-446655440000" ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000/retry" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000/retry") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000/retry") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000/retry', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/notificationlogs/550e8400-e29b-41d4-a716-446655440000/retry")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Bulk retry notifications POST https://api-sandbox.payabli.com/api/v2/notificationlogs/retry Content-Type: application/json Retry sending multiple notifications (maximum 50 IDs). This is an async process, so use the search endpoint again to check the notification status. This endpoint requires the `notifications_create` permission. Reference: https://docs.payabli.com/developers/api-reference/notification-logs/bulk-retry-notification-logs ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.notificationlogs.bulkRetryNotificationLogs([ "550e8400-e29b-41d4-a716-446655440000", "550e8400-e29b-41d4-a716-446655440001", "550e8400-e29b-41d4-a716-446655440002", ]); } main(); ``` ```python from payabli import payabli import uuid client = payabli( api_key="YOUR_API_KEY_HERE", ) client.notificationlogs.bulk_retry_notification_logs( request=[ uuid.UUID("550e8400-e29b-41d4-a716-446655440000"), uuid.UUID("550e8400-e29b-41d4-a716-446655440001"), uuid.UUID("550e8400-e29b-41d4-a716-446655440002") ], ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Notificationlogs.BulkRetryNotificationLogsAsync( new List(){ "550e8400-e29b-41d4-a716-446655440000", "550e8400-e29b-41d4-a716-446655440001", "550e8400-e29b-41d4-a716-446655440002", } ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/v2/notificationlogs/retry" payload := strings.NewReader("[\n \"550e8400-e29b-41d4-a716-446655440000\",\n \"550e8400-e29b-41d4-a716-446655440001\",\n \"550e8400-e29b-41d4-a716-446655440002\"\n]") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/v2/notificationlogs/retry") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "[\n \"550e8400-e29b-41d4-a716-446655440000\",\n \"550e8400-e29b-41d4-a716-446655440001\",\n \"550e8400-e29b-41d4-a716-446655440002\"\n]" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/v2/notificationlogs/retry") .header("requestToken", "") .header("Content-Type", "application/json") .body("[\n \"550e8400-e29b-41d4-a716-446655440000\",\n \"550e8400-e29b-41d4-a716-446655440001\",\n \"550e8400-e29b-41d4-a716-446655440002\"\n]") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/v2/notificationlogs/retry', [ 'body' => '[ "550e8400-e29b-41d4-a716-446655440000", "550e8400-e29b-41d4-a716-446655440001", "550e8400-e29b-41d4-a716-446655440002" ]', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["550e8400-e29b-41d4-a716-446655440000", "550e8400-e29b-41d4-a716-446655440001", "550e8400-e29b-41d4-a716-446655440002"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/v2/notificationlogs/retry")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create user POST https://api-sandbox.payabli.com/api/User Content-Type: application/json Use this endpoint to add a new user to an organization. Reference: https://docs.payabli.com/developers/api-reference/user/add-user-to-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.addUser({}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.add_user() ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.AddUserAsync( new UserData() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User" payload := strings.NewReader("{}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/User") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/User', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get user GET https://api-sandbox.payabli.com/api/User/{userId} Use this endpoint to retrieve information about a specific user within an organization. Reference: https://docs.payabli.com/developers/api-reference/user/get-user-in-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.getUser(1000000, { entry: "478ae1234", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.get_user( user_id=1000000, entry="478ae1234", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.GetUserAsync( 1000000L, new GetUserRequest { Entry = "478ae1234" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/1000000?entry=478ae1234" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/1000000?entry=478ae1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/User/1000000?entry=478ae1234") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/User/1000000?entry=478ae1234', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/1000000?entry=478ae1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update user PUT https://api-sandbox.payabli.com/api/User/{userId} Content-Type: application/json Use this endpoint to modify the details of a specific user within an organization. Reference: https://docs.payabli.com/developers/api-reference/user/modify-user-in-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.editUser(1000000, {}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.edit_user( user_id=1000000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.EditUserAsync( 1000000L, new UserData() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/1000000" payload := strings.NewReader("{}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/1000000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/User/1000000") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('PUT', 'https://api-sandbox.payabli.com/api/User/1000000', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/1000000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete user DELETE https://api-sandbox.payabli.com/api/User/{userId} Use this endpoint to delete a specific user within an organization. Reference: https://docs.payabli.com/developers/api-reference/user/delete-user-in-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.deleteUser(1000000); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.delete_user( user_id=1000000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.DeleteUserAsync( 1000000L ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/1000000" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/1000000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/User/1000000") .header("requestToken", "") .asString(); ``` ```php request('DELETE', 'https://api-sandbox.payabli.com/api/User/1000000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/1000000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Configure MFA PUT https://api-sandbox.payabli.com/api/User/mfa/{userId} Content-Type: application/json Use this endpoint to enable or disable multi-factor authentication (MFA) for a user within an organization. Reference: https://docs.payabli.com/developers/api-reference/user/enable-disable-mfor-user ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.editMfaUser(1000000, {}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.edit_mfa_user( user_id=1000000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.EditMfaUserAsync( 1000000L, new MfaData() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/mfa/1000000" payload := strings.NewReader("{}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/mfa/1000000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/User/mfa/1000000") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('PUT', 'https://api-sandbox.payabli.com/api/User/mfa/1000000', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/mfa/1000000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Authenticate user POST https://api-sandbox.payabli.com/api/User/auth/{provider} Content-Type: application/json This endpoint requires an application API token. Reference: https://docs.payabli.com/developers/api-reference/user/authenticate-user ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.authUser("provider", {}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.auth_user( provider="provider", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.AuthUserAsync( "provider", new UserAuthRequest() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/auth/provider" payload := strings.NewReader("{}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/auth/provider") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/User/auth/provider") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/User/auth/provider', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/auth/provider")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Refresh token POST https://api-sandbox.payabli.com/api/User/authrefresh Use this endpoint to refresh the authentication token for a user within an organization. Reference: https://docs.payabli.com/developers/api-reference/user/refresh-token-for-user ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.authRefreshUser(); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.auth_refresh_user() ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.AuthRefreshUserAsync(); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/authrefresh" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/authrefresh") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/User/authrefresh") .header("requestToken", "") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/User/authrefresh', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/authrefresh")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Logout user GET https://api-sandbox.payabli.com/api/User/authlogout Use this endpoint to log a user out from the system. Reference: https://docs.payabli.com/developers/api-reference/user/logout-user ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.logoutUser(); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.logout_user() ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.LogoutUserAsync(); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/authlogout" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/authlogout") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/User/authlogout") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/User/authlogout', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/authlogout")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update password PUT https://api-sandbox.payabli.com/api/User/authpsw Content-Type: application/json Use this endpoint to change the password for a user within an organization. Reference: https://docs.payabli.com/developers/api-reference/user/update-password-for-user ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.changePswUser({}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.change_psw_user() ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.ChangePswUserAsync( new UserAuthPswResetRequest() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/authpsw" payload := strings.NewReader("{}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/authpsw") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/User/authpsw") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('PUT', 'https://api-sandbox.payabli.com/api/User/authpsw', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/authpsw")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Reset password POST https://api-sandbox.payabli.com/api/User/authreset Content-Type: application/json Use this endpoint to initiate a password reset for a user within an organization. Reference: https://docs.payabli.com/developers/api-reference/user/reset-password-for-user ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.authResetUser({}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.auth_reset_user() ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.AuthResetUserAsync( new UserAuthResetRequest() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/authreset" payload := strings.NewReader("{}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/authreset") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/User/authreset") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/User/authreset', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/authreset")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Validate MFA POST https://api-sandbox.payabli.com/api/User/mfa Content-Type: application/json Use this endpoint to validate the multi-factor authentication (MFA) code for a user within an organization. Reference: https://docs.payabli.com/developers/api-reference/user/validate-mfor-user ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.validateMfaUser({}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.validate_mfa_user() ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.ValidateMfaUserAsync( new MfaValidationData() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/mfa" payload := strings.NewReader("{}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/mfa") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/User/mfa") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/User/mfa', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/mfa")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Resend MFA code POST https://api-sandbox.payabli.com/api/User/resendmfa/{usrname}/{Entry}/{EntryType} Resends the MFA code to the user via the selected MFA mode (email or SMS). Reference: https://docs.payabli.com/developers/api-reference/user/resend-mcode ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.user.resendMfaCode("Entry", 1, "usrname"); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.user.resend_mfa_code( entry="Entry", entry_type=1, usrname="usrname", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.User.ResendMfaCodeAsync( "usrname", "Entry", 1 ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/User/resendmfa/usrname/Entry/1" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/User/resendmfa/usrname/Entry/1") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/User/resendmfa/usrname/Entry/1") .header("requestToken", "") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/User/resendmfa/usrname/Entry/1', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/User/resendmfa/usrname/Entry/1")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List users by org GET https://api-sandbox.payabli.com/api/Query/users/org/{orgId} Get list of users for an org. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/user/get-list-of-users-for-an-org ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listUsersOrg(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_users_org( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListUsersOrgAsync( 123, new ListUsersOrgRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/users/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/users/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/users/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/users/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/users/org/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List users by paypoint GET https://api-sandbox.payabli.com/api/Query/users/point/{entry} Get list of users for a paypoint. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/user/get-list-of-users-for-paypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listUsersPaypoint("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_users_paypoint( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListUsersPaypointAsync( "8cfec329267", new ListUsersPaypointRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/users/point/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/users/point/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/users/point/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/users/point/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/users/point/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create organization POST https://api-sandbox.payabli.com/api/Organization Content-Type: application/json Creates an organization under a parent organization. This is also referred to as a suborganization. Reference: https://docs.payabli.com/developers/api-reference/organization/create-organization ## SDK Code Examples ```typescript General success response for certain organization operations import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.organization.addOrganization({ idempotencyKey: "6B29FC40-CA47-1067-B31D-00DD010662DA", orgName: "Pilgrim Planner", orgType: 0, replyToEmail: "email@example.com", billingInfo: { achAccount: "123123123", achRouting: "123123123", billingAddress: "123 Walnut Street", billingCity: "Johnson City", billingCountry: "US", billingState: "TN", billingZip: "37615", }, contacts: [ { contactEmail: "herman@hermanscoatings.com", contactName: "Herman Martinez", contactPhone: "3055550000", contactTitle: "Owner", }, ], hasBilling: true, hasResidual: true, orgAddress: "123 Walnut Street", orgCity: "Johnson City", orgCountry: "US", orgEntryName: "pilgrim-planner", orgId: "123", orgLogo: { fContent: "TXkgdGVzdCBmaWxlHJ==...", filename: "my-doc.pdf", ftype: "pdf", furl: "https://mysite.com/my-doc.pdf", }, orgParentId: 236, orgState: "TN", orgTimezone: -5, orgWebsite: "www.pilgrimageplanner.com", orgZip: "37615", }); } main(); ``` ```python General success response for certain organization operations from payabli import payabli, Instrument, Contacts, FileContent client = payabli( api_key="YOUR_API_KEY_HERE", ) client.organization.add_organization( idempotency_key="6B29FC40-CA47-1067-B31D-00DD010662DA", org_name="Pilgrim Planner", org_type=0, reply_to_email="email@example.com", billing_info=Instrument( ach_account="123123123", ach_routing="123123123", billing_address="123 Walnut Street", billing_city="Johnson City", billing_country="US", billing_state="TN", billing_zip="37615", ), contacts=[ Contacts( contact_email="herman@hermanscoatings.com", contact_name="Herman Martinez", contact_phone="3055550000", contact_title="Owner", ) ], has_billing=True, has_residual=True, org_address="123 Walnut Street", org_city="Johnson City", org_country="US", org_entry_name="pilgrim-planner", org_id="123", org_logo=FileContent( f_content="TXkgdGVzdCBmaWxlHJ==...", filename="my-doc.pdf", ftype="pdf", furl="https://mysite.com/my-doc.pdf", ), org_parent_id=236, org_state="TN", org_timezone=-5, org_website="www.pilgrimageplanner.com", org_zip="37615", ) ``` ```csharp General success response for certain organization operations using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Organization.AddOrganizationAsync( new AddOrganizationRequest { IdempotencyKey = "6B29FC40-CA47-1067-B31D-00DD010662DA", OrgName = "Pilgrim Planner", OrgType = 0, ReplyToEmail = "email@example.com", BillingInfo = new Instrument { AchAccount = "123123123", AchRouting = "123123123", BillingAddress = "123 Walnut Street", BillingCity = "Johnson City", BillingCountry = "US", BillingState = "TN", BillingZip = "37615" }, Contacts = new List(){ new Contacts { ContactEmail = "herman@hermanscoatings.com", ContactName = "Herman Martinez", ContactPhone = "3055550000", ContactTitle = "Owner" }, } , HasBilling = true, HasResidual = true, OrgAddress = "123 Walnut Street", OrgCity = "Johnson City", OrgCountry = "US", OrgEntryName = "pilgrim-planner", OrgId = "123", OrgLogo = new FileContent { FContent = "TXkgdGVzdCBmaWxlHJ==...", Filename = "my-doc.pdf", Ftype = FileContentFtype.Pdf, Furl = "https://mysite.com/my-doc.pdf" }, OrgParentId = 236L, OrgState = "TN", OrgTimezone = -5, OrgWebsite = "www.pilgrimageplanner.com", OrgZip = "37615" } ); } } ``` ```go General success response for certain organization operations package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Organization" payload := strings.NewReader("{\n \"orgName\": \"Pilgrim Planner\",\n \"orgType\": 0,\n \"replyToEmail\": \"email@example.com\",\n \"billingInfo\": {\n \"achAccount\": \"123123123\",\n \"achRouting\": \"123123123\",\n \"billingAddress\": \"123 Walnut Street\",\n \"billingCity\": \"Johnson City\",\n \"billingCountry\": \"US\",\n \"billingState\": \"TN\",\n \"billingZip\": \"37615\"\n },\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"hasBilling\": true,\n \"hasResidual\": true,\n \"orgAddress\": \"123 Walnut Street\",\n \"orgCity\": \"Johnson City\",\n \"orgCountry\": \"US\",\n \"orgEntryName\": \"pilgrim-planner\",\n \"orgId\": \"123\",\n \"orgLogo\": {\n \"fContent\": \"TXkgdGVzdCBmaWxlHJ==...\",\n \"filename\": \"my-doc.pdf\",\n \"ftype\": \"pdf\",\n \"furl\": \"https://mysite.com/my-doc.pdf\"\n },\n \"orgParentId\": 236,\n \"orgState\": \"TN\",\n \"orgTimezone\": -5,\n \"orgWebsite\": \"www.pilgrimageplanner.com\",\n \"orgZip\": \"37615\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby General success response for certain organization operations require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Organization") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["idempotencyKey"] = '6B29FC40-CA47-1067-B31D-00DD010662DA' request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"orgName\": \"Pilgrim Planner\",\n \"orgType\": 0,\n \"replyToEmail\": \"email@example.com\",\n \"billingInfo\": {\n \"achAccount\": \"123123123\",\n \"achRouting\": \"123123123\",\n \"billingAddress\": \"123 Walnut Street\",\n \"billingCity\": \"Johnson City\",\n \"billingCountry\": \"US\",\n \"billingState\": \"TN\",\n \"billingZip\": \"37615\"\n },\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"hasBilling\": true,\n \"hasResidual\": true,\n \"orgAddress\": \"123 Walnut Street\",\n \"orgCity\": \"Johnson City\",\n \"orgCountry\": \"US\",\n \"orgEntryName\": \"pilgrim-planner\",\n \"orgId\": \"123\",\n \"orgLogo\": {\n \"fContent\": \"TXkgdGVzdCBmaWxlHJ==...\",\n \"filename\": \"my-doc.pdf\",\n \"ftype\": \"pdf\",\n \"furl\": \"https://mysite.com/my-doc.pdf\"\n },\n \"orgParentId\": 236,\n \"orgState\": \"TN\",\n \"orgTimezone\": -5,\n \"orgWebsite\": \"www.pilgrimageplanner.com\",\n \"orgZip\": \"37615\"\n}" response = http.request(request) puts response.read_body ``` ```java General success response for certain organization operations import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Organization") .header("idempotencyKey", "6B29FC40-CA47-1067-B31D-00DD010662DA") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"orgName\": \"Pilgrim Planner\",\n \"orgType\": 0,\n \"replyToEmail\": \"email@example.com\",\n \"billingInfo\": {\n \"achAccount\": \"123123123\",\n \"achRouting\": \"123123123\",\n \"billingAddress\": \"123 Walnut Street\",\n \"billingCity\": \"Johnson City\",\n \"billingCountry\": \"US\",\n \"billingState\": \"TN\",\n \"billingZip\": \"37615\"\n },\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"hasBilling\": true,\n \"hasResidual\": true,\n \"orgAddress\": \"123 Walnut Street\",\n \"orgCity\": \"Johnson City\",\n \"orgCountry\": \"US\",\n \"orgEntryName\": \"pilgrim-planner\",\n \"orgId\": \"123\",\n \"orgLogo\": {\n \"fContent\": \"TXkgdGVzdCBmaWxlHJ==...\",\n \"filename\": \"my-doc.pdf\",\n \"ftype\": \"pdf\",\n \"furl\": \"https://mysite.com/my-doc.pdf\"\n },\n \"orgParentId\": 236,\n \"orgState\": \"TN\",\n \"orgTimezone\": -5,\n \"orgWebsite\": \"www.pilgrimageplanner.com\",\n \"orgZip\": \"37615\"\n}") .asString(); ``` ```php General success response for certain organization operations request('POST', 'https://api-sandbox.payabli.com/api/Organization', [ 'body' => '{ "orgName": "Pilgrim Planner", "orgType": 0, "replyToEmail": "email@example.com", "billingInfo": { "achAccount": "123123123", "achRouting": "123123123", "billingAddress": "123 Walnut Street", "billingCity": "Johnson City", "billingCountry": "US", "billingState": "TN", "billingZip": "37615" }, "contacts": [ { "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" } ], "hasBilling": true, "hasResidual": true, "orgAddress": "123 Walnut Street", "orgCity": "Johnson City", "orgCountry": "US", "orgEntryName": "pilgrim-planner", "orgId": "123", "orgLogo": { "fContent": "TXkgdGVzdCBmaWxlHJ==...", "filename": "my-doc.pdf", "ftype": "pdf", "furl": "https://mysite.com/my-doc.pdf" }, "orgParentId": 236, "orgState": "TN", "orgTimezone": -5, "orgWebsite": "www.pilgrimageplanner.com", "orgZip": "37615" }', 'headers' => [ 'Content-Type' => 'application/json', 'idempotencyKey' => '6B29FC40-CA47-1067-B31D-00DD010662DA', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift General success response for certain organization operations import Foundation let headers = [ "idempotencyKey": "6B29FC40-CA47-1067-B31D-00DD010662DA", "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "orgName": "Pilgrim Planner", "orgType": 0, "replyToEmail": "email@example.com", "billingInfo": [ "achAccount": "123123123", "achRouting": "123123123", "billingAddress": "123 Walnut Street", "billingCity": "Johnson City", "billingCountry": "US", "billingState": "TN", "billingZip": "37615" ], "contacts": [ [ "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" ] ], "hasBilling": true, "hasResidual": true, "orgAddress": "123 Walnut Street", "orgCity": "Johnson City", "orgCountry": "US", "orgEntryName": "pilgrim-planner", "orgId": "123", "orgLogo": [ "fContent": "TXkgdGVzdCBmaWxlHJ==...", "filename": "my-doc.pdf", "ftype": "pdf", "furl": "https://mysite.com/my-doc.pdf" ], "orgParentId": 236, "orgState": "TN", "orgTimezone": -5, "orgWebsite": "www.pilgrimageplanner.com", "orgZip": "37615" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Organization")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get organization GET https://api-sandbox.payabli.com/api/Organization/read/{orgId} Retrieves details for an organization by ID. Reference: https://docs.payabli.com/developers/api-reference/organization/get-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.organization.getOrganization(123); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.organization.get_organization( org_id=123, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Organization.GetOrganizationAsync( 123 ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Organization/read/123" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Organization/read/123") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Organization/read/123") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Organization/read/123', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Organization/read/123")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get basic details by name GET https://api-sandbox.payabli.com/api/Organization/basic/{entry} Gets an organization's basic information by entry name (entrypoint identifier). Reference: https://docs.payabli.com/developers/api-reference/organization/get-basic-organization-details-by-entry-name ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.organization.getBasicOrganization("8cfec329267"); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.organization.get_basic_organization( entry="8cfec329267", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Organization.GetBasicOrganizationAsync( "8cfec329267" ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Organization/basic/8cfec329267" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Organization/basic/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Organization/basic/8cfec329267") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Organization/basic/8cfec329267', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Organization/basic/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get basic details by ID GET https://api-sandbox.payabli.com/api/Organization/basicById/{orgId} Gets an organizations basic details by org ID. Reference: https://docs.payabli.com/developers/api-reference/organization/get-basic-organization-details-by-id ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.organization.getBasicOrganizationById(123); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.organization.get_basic_organization_by_id( org_id=123, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Organization.GetBasicOrganizationByIdAsync( 123 ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Organization/basicById/123" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Organization/basicById/123") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Organization/basicById/123") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Organization/basicById/123', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Organization/basicById/123")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get organization settings GET https://api-sandbox.payabli.com/api/Organization/settings/{orgId} Retrieves an organization's settings. Reference: https://docs.payabli.com/developers/api-reference/organization/get-organization-settings ## SDK Code Examples ```typescript GetSettings import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.organization.getSettingsOrganization(123); } main(); ``` ```python GetSettings from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.organization.get_settings_organization( org_id=123, ) ``` ```csharp GetSettings using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Organization.GetSettingsOrganizationAsync( 123 ); } } ``` ```go GetSettings package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Organization/settings/123" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetSettings require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Organization/settings/123") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetSettings import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Organization/settings/123") .header("requestToken", "") .asString(); ``` ```php GetSettings request('GET', 'https://api-sandbox.payabli.com/api/Organization/settings/123', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetSettings import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Organization/settings/123")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update organization PUT https://api-sandbox.payabli.com/api/Organization/{orgId} Content-Type: application/json Updates an organization's details by ID. Reference: https://docs.payabli.com/developers/api-reference/organization/update-organization ## SDK Code Examples ```typescript Example1 import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.organization.editOrganization(123, { contacts: [ { contactEmail: "herman@hermanscoatings.com", contactName: "Herman Martinez", contactPhone: "3055550000", contactTitle: "Owner", }, ], orgAddress: "123 Walnut Street", orgCity: "Johnson City", orgCountry: "US", orgEntryName: "pilgrim-planner", organizationDataOrgId: "123", orgName: "Pilgrim Planner", orgState: "TN", orgTimezone: -5, orgType: 0, orgWebsite: "www.pilgrimageplanner.com", orgZip: "37615", }); } main(); ``` ```python Example1 from payabli import payabli, Contacts client = payabli( api_key="YOUR_API_KEY_HERE", ) client.organization.edit_organization( org_id=123, contacts=[ Contacts( contact_email="herman@hermanscoatings.com", contact_name="Herman Martinez", contact_phone="3055550000", contact_title="Owner", ) ], org_address="123 Walnut Street", org_city="Johnson City", org_country="US", org_entry_name="pilgrim-planner", organization_data_org_id="123", org_name="Pilgrim Planner", org_state="TN", org_timezone=-5, org_type=0, org_website="www.pilgrimageplanner.com", org_zip="37615", ) ``` ```csharp Example1 using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Organization.EditOrganizationAsync( 123, new OrganizationData { Contacts = new List(){ new Contacts { ContactEmail = "herman@hermanscoatings.com", ContactName = "Herman Martinez", ContactPhone = "3055550000", ContactTitle = "Owner" }, } , OrgAddress = "123 Walnut Street", OrgCity = "Johnson City", OrgCountry = "US", OrgEntryName = "pilgrim-planner", OrganizationDataOrgId = "123", OrgName = "Pilgrim Planner", OrgState = "TN", OrgTimezone = -5, OrgType = 0, OrgWebsite = "www.pilgrimageplanner.com", OrgZip = "37615" } ); } } ``` ```go Example1 package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Organization/123" payload := strings.NewReader("{\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"orgAddress\": \"123 Walnut Street\",\n \"orgCity\": \"Johnson City\",\n \"orgCountry\": \"US\",\n \"orgEntryName\": \"pilgrim-planner\",\n \"orgId\": \"123\",\n \"orgName\": \"Pilgrim Planner\",\n \"orgState\": \"TN\",\n \"orgTimezone\": -5,\n \"orgType\": 0,\n \"orgWebsite\": \"www.pilgrimageplanner.com\",\n \"orgZip\": \"37615\"\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example1 require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Organization/123") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"orgAddress\": \"123 Walnut Street\",\n \"orgCity\": \"Johnson City\",\n \"orgCountry\": \"US\",\n \"orgEntryName\": \"pilgrim-planner\",\n \"orgId\": \"123\",\n \"orgName\": \"Pilgrim Planner\",\n \"orgState\": \"TN\",\n \"orgTimezone\": -5,\n \"orgType\": 0,\n \"orgWebsite\": \"www.pilgrimageplanner.com\",\n \"orgZip\": \"37615\"\n}" response = http.request(request) puts response.read_body ``` ```java Example1 import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Organization/123") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"contacts\": [\n {\n \"contactEmail\": \"herman@hermanscoatings.com\",\n \"contactName\": \"Herman Martinez\",\n \"contactPhone\": \"3055550000\",\n \"contactTitle\": \"Owner\"\n }\n ],\n \"orgAddress\": \"123 Walnut Street\",\n \"orgCity\": \"Johnson City\",\n \"orgCountry\": \"US\",\n \"orgEntryName\": \"pilgrim-planner\",\n \"orgId\": \"123\",\n \"orgName\": \"Pilgrim Planner\",\n \"orgState\": \"TN\",\n \"orgTimezone\": -5,\n \"orgType\": 0,\n \"orgWebsite\": \"www.pilgrimageplanner.com\",\n \"orgZip\": \"37615\"\n}") .asString(); ``` ```php Example1 request('PUT', 'https://api-sandbox.payabli.com/api/Organization/123', [ 'body' => '{ "contacts": [ { "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" } ], "orgAddress": "123 Walnut Street", "orgCity": "Johnson City", "orgCountry": "US", "orgEntryName": "pilgrim-planner", "orgId": "123", "orgName": "Pilgrim Planner", "orgState": "TN", "orgTimezone": -5, "orgType": 0, "orgWebsite": "www.pilgrimageplanner.com", "orgZip": "37615" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example1 import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "contacts": [ [ "contactEmail": "herman@hermanscoatings.com", "contactName": "Herman Martinez", "contactPhone": "3055550000", "contactTitle": "Owner" ] ], "orgAddress": "123 Walnut Street", "orgCity": "Johnson City", "orgCountry": "US", "orgEntryName": "pilgrim-planner", "orgId": "123", "orgName": "Pilgrim Planner", "orgState": "TN", "orgTimezone": -5, "orgType": 0, "orgWebsite": "www.pilgrimageplanner.com", "orgZip": "37615" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Organization/123")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete organization DELETE https://api-sandbox.payabli.com/api/Organization/{orgId} Delete an organization by ID. Reference: https://docs.payabli.com/developers/api-reference/organization/delete-organization ## SDK Code Examples ```typescript General success response for certain organization operations import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.organization.deleteOrganization(123); } main(); ``` ```python General success response for certain organization operations from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.organization.delete_organization( org_id=123, ) ``` ```csharp General success response for certain organization operations using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Organization.DeleteOrganizationAsync( 123 ); } } ``` ```go General success response for certain organization operations package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Organization/123" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby General success response for certain organization operations require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Organization/123") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java General success response for certain organization operations import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Organization/123") .header("requestToken", "") .asString(); ``` ```php General success response for certain organization operations request('DELETE', 'https://api-sandbox.payabli.com/api/Organization/123', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift General success response for certain organization operations import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Organization/123")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List suborganizations by organization GET https://api-sandbox.payabli.com/api/Query/organizations/{orgId} Retrieves a list of an organization's suborganizations and their full details such as orgId, users, and settings. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/organization/get-list-of-organizations-for-entrypoint ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listOrganizations(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_organizations( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListOrganizationsAsync( 123, new ListOrganizationsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/organizations/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/organizations/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/organizations/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/organizations/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/organizations/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export organizations by paypoint GET https://api-sandbox.payabli.com/api/Export/organizations/{format}/org/{orgId} Export a list of child organizations (suborganizations) for a parent organization. Reference: https://docs.payabli.com/developers/api-reference/organization/export-list-of-child-organization-for-a-parent-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportOrganizations("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_organizations( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportOrganizationsAsync( ExportFormat1.Csv, 123, new ExportOrganizationsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/organizations/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/organizations/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/organizations/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/organizations/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/organizations/csv/org/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get basic paypoint details GET https://api-sandbox.payabli.com/api/Paypoint/basic/{entry} Gets the basic details for a paypoint. Reference: https://docs.payabli.com/developers/api-reference/paypoint/get-basic-paypoint-details ## SDK Code Examples ```typescript Example Paypoint Entry response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paypoint.getBasicEntry("8cfec329267"); } main(); ``` ```python Example Paypoint Entry response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.paypoint.get_basic_entry( entry="8cfec329267", ) ``` ```csharp Example Paypoint Entry response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Paypoint.GetBasicEntryAsync( "8cfec329267" ); } } ``` ```go Example Paypoint Entry response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/basic/8cfec329267" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example Paypoint Entry response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/basic/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example Paypoint Entry response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Paypoint/basic/8cfec329267") .header("requestToken", "") .asString(); ``` ```php Example Paypoint Entry response request('GET', 'https://api-sandbox.payabli.com/api/Paypoint/basic/8cfec329267', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example Paypoint Entry response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/basic/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get basic paypoint details by ID GET https://api-sandbox.payabli.com/api/Paypoint/basicById/{IdPaypoint} Retrieves the basic details for a paypoint by ID. Reference: https://docs.payabli.com/developers/api-reference/paypoint/get-paypoint-details-by-id ## SDK Code Examples ```typescript Example Paypoint Entry response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paypoint.getBasicEntryById("198"); } main(); ``` ```python Example Paypoint Entry response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.paypoint.get_basic_entry_by_id( id_paypoint="198", ) ``` ```csharp Example Paypoint Entry response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Paypoint.GetBasicEntryByIdAsync( "198" ); } } ``` ```go Example Paypoint Entry response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/basicById/198" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example Paypoint Entry response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/basicById/198") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example Paypoint Entry response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Paypoint/basicById/198") .header("requestToken", "") .asString(); ``` ```php Example Paypoint Entry response request('GET', 'https://api-sandbox.payabli.com/api/Paypoint/basicById/198', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example Paypoint Entry response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/basicById/198")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get paypoint details GET https://api-sandbox.payabli.com/api/Paypoint/{entry} Gets the details for a single paypoint. Reference: https://docs.payabli.com/developers/api-reference/paypoint/get-paypoint-details ## SDK Code Examples ```typescript Example Paypoint Entry response import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paypoint.getEntryConfig("8cfec329267", {}); } main(); ``` ```python Example Paypoint Entry response from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.paypoint.get_entry_config( entry="8cfec329267", ) ``` ```csharp Example Paypoint Entry response using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Paypoint.GetEntryConfigAsync( "8cfec329267", new GetEntryConfigRequest() ); } } ``` ```go Example Paypoint Entry response package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example Paypoint Entry response require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example Paypoint Entry response import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Paypoint/8cfec329267") .header("requestToken", "") .asString(); ``` ```php Example Paypoint Entry response request('GET', 'https://api-sandbox.payabli.com/api/Paypoint/8cfec329267', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example Paypoint Entry response import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get paypoint settings GET https://api-sandbox.payabli.com/api/Paypoint/settings/{entry} Retrieves an paypoint's basic settings like custom fields, identifiers, and invoicing settings. Reference: https://docs.payabli.com/developers/api-reference/paypoint/get-paypoint-settings ## SDK Code Examples ```typescript Example settings configuration import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paypoint.settingsPage("8cfec329267"); } main(); ``` ```python Example settings configuration from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.paypoint.settings_page( entry="8cfec329267", ) ``` ```csharp Example settings configuration using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Paypoint.SettingsPageAsync( "8cfec329267" ); } } ``` ```go Example settings configuration package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/settings/8cfec329267" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example settings configuration require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/settings/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Example settings configuration import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Paypoint/settings/8cfec329267") .header("requestToken", "") .asString(); ``` ```php Example settings configuration request('GET', 'https://api-sandbox.payabli.com/api/Paypoint/settings/8cfec329267', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Example settings configuration import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/settings/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Upload logo PUT https://api-sandbox.payabli.com/api/Paypoint/logo/{entry} Content-Type: application/json Updates a paypoint logo. Reference: https://docs.payabli.com/developers/api-reference/paypoint/update-paypoint-logo ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paypoint.saveLogo("8cfec329267", {}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.paypoint.save_logo( entry="8cfec329267", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Paypoint.SaveLogoAsync( "8cfec329267", new FileContent() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/logo/8cfec329267" payload := strings.NewReader("{}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/logo/8cfec329267") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/Paypoint/logo/8cfec329267") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('PUT', 'https://api-sandbox.payabli.com/api/Paypoint/logo/8cfec329267', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/logo/8cfec329267")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List paypoints by organization GET https://api-sandbox.payabli.com/api/Query/paypoints/{orgId} Returns a list of paypoints in an organization. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response. Reference: https://docs.payabli.com/developers/api-reference/paypoint/get-list-of-paypoints-for-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.query.listPaypoints(123, { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.query.list_paypoints( org_id=123, from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Query.ListPaypointsAsync( 123, new ListPaypointsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/paypoints/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/paypoints/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/paypoints/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Query/paypoints/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/paypoints/123?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Export paypoints by organization GET https://api-sandbox.payabli.com/api/Export/paypoints/{format}/{orgId} Export a list of paypoints in an organization. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/paypoint/export-list-of-paypoints-in-an-organization ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.export.exportPaypoints("csv", 123, { columnsExport: "BatchDate:Batch_Date,PaypointName:Legal_name", fromRecord: 251, limitRecord: 1000, }); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.export.export_paypoints( format="csv", org_id=123, columns_export="BatchDate:Batch_Date,PaypointName:Legal_name", from_record=251, limit_record=1000, ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Export.ExportPaypointsAsync( ExportFormat1.Csv, 123, new ExportPaypointsRequest { ColumnsExport = "BatchDate:Batch_Date,PaypointName:Legal_name", FromRecord = 251, LimitRecord = 1000 } ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Export/paypoints/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Export/paypoints/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Export/paypoints/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/Export/paypoints/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Export/paypoints/csv/123?columnsExport=BatchDate%3ABatch_Date%2CPaypointName%3ALegal_name&fromRecord=251&limitRecord=1000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Migrate paypoint POST https://api-sandbox.payabli.com/api/Paypoint/migrate Content-Type: application/json Migrates a paypoint to a new parent organization. Reference: https://docs.payabli.com/developers/api-reference/paypoint/migrate-paypoint-to-another-organization ## SDK Code Examples ```typescript MigrateWithNotification import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paypoint.migrate({ entryPoint: "473abc123def", newParentOrganizationId: 123, notificationRequest: { notificationUrl: "https://webhook-test.yoursie.com", webHeaderParameters: [ { key: "testheader", value: "1234567890", }, ], }, }); } main(); ``` ```python MigrateWithNotification from payabli import payabli from payabli.paypoint import NotificationRequest, WebHeaderParameter client = payabli( api_key="YOUR_API_KEY_HERE", ) client.paypoint.migrate( entry_point="473abc123def", new_parent_organization_id=123, notification_request=NotificationRequest( notification_url="https://webhook-test.yoursie.com", web_header_parameters=[ WebHeaderParameter( key="testheader", value="1234567890", ) ], ), ) ``` ```csharp MigrateWithNotification using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Paypoint.MigrateAsync( new PaypointMoveRequest { EntryPoint = "473abc123def", NewParentOrganizationId = 123, NotificationRequest = new NotificationRequest { NotificationUrl = "https://webhook-test.yoursie.com", WebHeaderParameters = new List(){ new WebHeaderParameter { Key = "testheader", Value = "1234567890" }, } } } ); } } ``` ```go MigrateWithNotification package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Paypoint/migrate" payload := strings.NewReader("{\n \"entryPoint\": \"473abc123def\",\n \"newParentOrganizationId\": 123,\n \"notificationRequest\": {\n \"notificationUrl\": \"https://webhook-test.yoursie.com\",\n \"webHeaderParameters\": [\n {\n \"key\": \"testheader\",\n \"value\": \"1234567890\"\n }\n ]\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby MigrateWithNotification require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Paypoint/migrate") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"entryPoint\": \"473abc123def\",\n \"newParentOrganizationId\": 123,\n \"notificationRequest\": {\n \"notificationUrl\": \"https://webhook-test.yoursie.com\",\n \"webHeaderParameters\": [\n {\n \"key\": \"testheader\",\n \"value\": \"1234567890\"\n }\n ]\n }\n}" response = http.request(request) puts response.read_body ``` ```java MigrateWithNotification import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Paypoint/migrate") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"entryPoint\": \"473abc123def\",\n \"newParentOrganizationId\": 123,\n \"notificationRequest\": {\n \"notificationUrl\": \"https://webhook-test.yoursie.com\",\n \"webHeaderParameters\": [\n {\n \"key\": \"testheader\",\n \"value\": \"1234567890\"\n }\n ]\n }\n}") .asString(); ``` ```php MigrateWithNotification request('POST', 'https://api-sandbox.payabli.com/api/Paypoint/migrate', [ 'body' => '{ "entryPoint": "473abc123def", "newParentOrganizationId": 123, "notificationRequest": { "notificationUrl": "https://webhook-test.yoursie.com", "webHeaderParameters": [ { "key": "testheader", "value": "1234567890" } ] } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift MigrateWithNotification import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "entryPoint": "473abc123def", "newParentOrganizationId": 123, "notificationRequest": [ "notificationUrl": "https://webhook-test.yoursie.com", "webHeaderParameters": [ [ "key": "testheader", "value": "1234567890" ] ] ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Paypoint/migrate")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get stats for an org or paypoint GET https://api-sandbox.payabli.com/api/Statistic/basic/{mode}/{freq}/{level}/{entryId} Retrieves the basic statistics for an organization or a paypoint, for a given time period, grouped by a particular frequency. Reference: https://docs.payabli.com/developers/api-reference/get-basic-statistics-for-a-paypoint-or-organization ## SDK Code Examples ```typescript BasicStatsExample import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.statistic.basicStats(1000000, "m", 1, "ytd", { endDate: "2025-11-01", startDate: "2025-11-30", }); } main(); ``` ```python BasicStatsExample from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.statistic.basic_stats( entry_id=1000000, freq="m", level=1, mode="ytd", end_date="2025-11-01", start_date="2025-11-30", ) ``` ```csharp BasicStatsExample using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Statistic.BasicStatsAsync( "ytd", "m", 1, 1000000L, new BasicStatsRequest { EndDate = "2025-11-01", StartDate = "2025-11-30" } ); } } ``` ```go BasicStatsExample package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Statistic/basic/ytd/m/1/1000000?endDate=2025-11-01&startDate=2025-11-30" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby BasicStatsExample require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Statistic/basic/ytd/m/1/1000000?endDate=2025-11-01&startDate=2025-11-30") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java BasicStatsExample import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Statistic/basic/ytd/m/1/1000000?endDate=2025-11-01&startDate=2025-11-30") .header("requestToken", "") .asString(); ``` ```php BasicStatsExample request('GET', 'https://api-sandbox.payabli.com/api/Statistic/basic/ytd/m/1/1000000?endDate=2025-11-01&startDate=2025-11-30', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift BasicStatsExample import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Statistic/basic/ytd/m/1/1000000?endDate=2025-11-01&startDate=2025-11-30")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create payment link from invoice POST https://api-sandbox.payabli.com/api/PaymentLink/{idInvoice} Content-Type: application/json Generates a payment link for an invoice from the invoice ID. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/generate-payment-link-from-invoice ## SDK Code Examples ```typescript GeneratePaymentLink import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.addPayLinkFromInvoice(23548884, { mail2: "jo@example.com; ceo@example.com", body: { contactUs: { emailLabel: "Email", enabled: true, header: "Contact Us", order: 0, paymentIcons: true, phoneLabel: "Phone", }, invoices: { enabled: true, invoiceLink: { enabled: true, label: "View Invoice", order: 0, }, order: 0, viewInvoiceDetails: { enabled: true, label: "Invoice Details", order: 0, }, }, logo: { enabled: true, order: 0, }, messageBeforePaying: { enabled: true, label: "Please review your payment details", order: 0, }, notes: { enabled: true, header: "Additional Notes", order: 0, placeholder: "Enter any additional notes here", value: "", }, page: { description: "Complete your payment securely", enabled: true, header: "Payment Page", order: 0, }, paymentButton: { enabled: true, label: "Pay Now", order: 0, }, paymentMethods: { allMethodsChecked: true, enabled: true, header: "Payment Methods", methods: { amex: true, applePay: true, discover: true, eCheck: true, mastercard: true, visa: true, }, order: 0, settings: { applePay: { buttonStyle: "black", buttonType: "pay", language: "en-US", }, }, }, payor: { enabled: true, fields: [ { display: true, fixed: true, identifier: true, label: "Full Name", name: "fullName", order: 0, required: true, validation: "alpha", value: "", width: 0, }, ], header: "Payor Information", order: 0, }, review: { enabled: true, header: "Review Payment", order: 0, }, settings: { color: "#000000", customCssUrl: "https://example.com/custom.css", language: "en", pageLogo: { fContent: "PHN2ZyB2aWV3Qm94PSIwIDAgODAwIDEwMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPCEtLSBCYWNrZ3JvdW5kIC0tPgogIDxyZWN0IHdpZHRoPSI4MDAiIGhlaWdodD0iMTAwMCIgZmlsbD0id2hpdGUiLz4KICAKICA8IS0tIENvbXBhbnkgSGVhZGVyIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+R3J1enlhIEFkdmVudHVyZSBPdXRmaXR0ZXJzPC90ZXh0PgogIDxsaW5lIHgxPSI0MCIgeTE9IjgwIiB4Mj0iNzYwIiB5Mj0iODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgCiAgPCEtLSBDb21wYW55IERldGFpbHMgLS0+CiAgPHRleHQgeD0iNDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xMjMgTW91bnRhaW4gVmlldyBSb2FkPC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxMzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGJpbGlzaSwgR2VvcmdpYSAwMTA1PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGVsOiArOTk1IDMyIDEyMyA0NTY3PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+RW1haWw6IGluZm9AZ3J1enlhYWR2ZW50dXJlcy5jb208L3RleHQ+CgogIDwhLS0gSW52b2ljZSBUaXRsZSAtLT4KICA8dGV4dCB4PSI2MDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+SU5WT0lDRTwvdGV4dD4KICA8dGV4dCB4PSI2MDAiIHk9IjE0MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5EYXRlOiAxMi8xMS8yMDI0PC90ZXh0PgogIDx0ZXh0IHg9IjYwMCIgeT0iMTYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkludm9pY2UgIzogR1JaLTIwMjQtMTEyMzwvdGV4dD4KCiAgPCEtLSBCaWxsIFRvIFNlY3Rpb24gLS0+CiAgPHRleHQgeD0iNDAiIHk9IjIyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+QklMTCBUTzo8L3RleHQ+CiAgPHJlY3QgeD0iNDAiIHk9IjIzNSIgd2lkdGg9IjMwMCIgaGVpZ2h0PSI4MCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSIyNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0N1c3RvbWVyIE5hbWVdPC90ZXh0PgogIDx0ZXh0IHg9IjUwIiB5PSIyODAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0FkZHJlc3MgTGluZSAxXTwvdGV4dD4KICA8dGV4dCB4PSI1MCIgeT0iMzAwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPltDaXR5LCBDb3VudHJ5XTwvdGV4dD4KCiAgPCEtLSBUYWJsZSBIZWFkZXJzIC0tPgogIDxyZWN0IHg9IjQwIiB5PSIzNDAiIHdpZHRoPSI3MjAiIGhlaWdodD0iMzAiIGZpbGw9IiMyYzNlNTAiLz4KICA8dGV4dCB4PSI1MCIgeT0iMzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSJ3aGl0ZSI+RGVzY3JpcHRpb248L3RleHQ+CiAgPHRleHQgeD0iNDUwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5RdWFudGl0eTwvdGV4dD4KICA8dGV4dCB4PSI1NTAiIHk9IjM2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0id2hpdGUiPlJhdGU8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5BbW91bnQ8L3RleHQ+CgogIDwhLS0gVGFibGUgUm93cyAtLT4KICA8cmVjdCB4PSI0MCIgeT0iMzcwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSIjZjdmOWZhIi8+CiAgPHRleHQgeD0iNTAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5Nb3VudGFpbiBDbGltYmluZyBFcXVpcG1lbnQgUmVudGFsPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iMzkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSIzOTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDI1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMjUwLjAwPC90ZXh0PgoKICA8cmVjdCB4PSI0MCIgeT0iNDAwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSJ3aGl0ZSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+R3VpZGVkIFRyZWsgUGFja2FnZSAtIDIgRGF5czwvdGV4dD4KICA8dGV4dCB4PSI0NTAiIHk9IjQyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNDIwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQ0MDAuMDA8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDQwMC4wMDwvdGV4dD4KCiAgPHJlY3QgeD0iNDAiIHk9IjQzMCIgd2lkdGg9IjcyMCIgaGVpZ2h0PSIzMCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U2FmZXR5IEVxdWlwbWVudCBQYWNrYWdlPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iNDUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDE1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjQ1MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMTUwLjAwPC90ZXh0PgoKICA8IS0tIFRvdGFscyAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI0ODAiIHgyPSI3NjAiIHkyPSI0ODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNTUwIiB5PSI1MTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMzNDQ5NWUiPlN1YnRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjUxMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kODAwLjAwPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSIjMzQ0OTVlIj5UYXggKDE4JSk6PC90ZXh0PgogIDx0ZXh0IHg9IjY4MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQxNDQuMDA8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI1NzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjU3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+JDk0NC4wMDwvdGV4dD4KCiAgPCEtLSBQYXltZW50IFRlcm1zIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2NDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlBheW1lbnQgVGVybXM8L3RleHQ+CiAgPHRleHQgeD0iNDAiIHk9IjY3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5QYXltZW50IGlzIGR1ZSB3aXRoaW4gMzAgZGF5czwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNjkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPlBsZWFzZSBpbmNsdWRlIGludm9pY2UgbnVtYmVyIG9uIHBheW1lbnQ8L3RleHQ+CgogIDwhLS0gQmFuayBEZXRhaWxzIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI3MzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPkJhbmsgRGV0YWlsczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkJhbms6IEJhbmsgb2YgR2VvcmdpYTwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzgwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPklCQU46IEdFMTIzNDU2Nzg5MDEyMzQ1Njc4PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSI4MDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U1dJRlQ6IEJBR0FHRTIyPC90ZXh0PgoKICA8IS0tIEZvb3RlciAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI5MDAiIHgyPSI3NjAiIHkyPSI5MDAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNDAiIHk9IjkzMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjEyIiBmaWxsPSIjN2Y4YzhkIj5UaGFuayB5b3UgZm9yIGNob29zaW5nIEdydXp5YSBBZHZlbnR1cmUgT3V0Zml0dGVyczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iOTUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTIiIGZpbGw9IiM3ZjhjOGQiPnd3dy5ncnV6eWFhZHZlbnR1cmVzLmNvbTwvdGV4dD4KPC9zdmc+Cg==", filename: "logo.jpg", ftype: "jpg", furl: "", }, redirectAfterApprove: true, redirectAfterApproveUrl: "https://example.com/success", }, }, }); } main(); ``` ```python GeneratePaymentLink from payabli import payabli, ContactElement, InvoiceElement, LabelElement, Element, NoteElement, PageElement, MethodElement, MethodsList, MethodElementSettings, MethodElementSettingsApplePay, PayorElement, PayorFields, HeaderElement, PagelinkSetting, FileContent client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.add_pay_link_from_invoice( id_invoice=23548884, mail_2="jo@example.com; ceo@example.com", contact_us=ContactElement( email_label="Email", enabled=True, header="Contact Us", order=0, payment_icons=True, phone_label="Phone", ), invoices=InvoiceElement( enabled=True, invoice_link=LabelElement( enabled=True, label="View Invoice", order=0, ), order=0, view_invoice_details=LabelElement( enabled=True, label="Invoice Details", order=0, ), ), logo=Element( enabled=True, order=0, ), message_before_paying=LabelElement( enabled=True, label="Please review your payment details", order=0, ), notes=NoteElement( enabled=True, header="Additional Notes", order=0, placeholder="Enter any additional notes here", value="", ), page=PageElement( description="Complete your payment securely", enabled=True, header="Payment Page", order=0, ), payment_button=LabelElement( enabled=True, label="Pay Now", order=0, ), payment_methods=MethodElement( all_methods_checked=True, enabled=True, header="Payment Methods", methods=MethodsList( amex=True, apple_pay=True, discover=True, e_check=True, mastercard=True, visa=True, ), order=0, settings=MethodElementSettings( apple_pay=MethodElementSettingsApplePay( button_style="black", button_type="pay", language="en-US", ), ), ), payor=PayorElement( enabled=True, fields=[ PayorFields( display=True, fixed=True, identifier=True, label="Full Name", name="fullName", order=0, required=True, validation="alpha", value="", width=0, ) ], header="Payor Information", order=0, ), review=HeaderElement( enabled=True, header="Review Payment", order=0, ), settings=PagelinkSetting( color="#000000", custom_css_url="https://example.com/custom.css", language="en", page_logo=FileContent( f_content="PHN2ZyB2aWV3Qm94PSIwIDAgODAwIDEwMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPCEtLSBCYWNrZ3JvdW5kIC0tPgogIDxyZWN0IHdpZHRoPSI4MDAiIGhlaWdodD0iMTAwMCIgZmlsbD0id2hpdGUiLz4KICAKICA8IS0tIENvbXBhbnkgSGVhZGVyIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+R3J1enlhIEFkdmVudHVyZSBPdXRmaXR0ZXJzPC90ZXh0PgogIDxsaW5lIHgxPSI0MCIgeTE9IjgwIiB4Mj0iNzYwIiB5Mj0iODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgCiAgPCEtLSBDb21wYW55IERldGFpbHMgLS0+CiAgPHRleHQgeD0iNDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xMjMgTW91bnRhaW4gVmlldyBSb2FkPC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxMzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGJpbGlzaSwgR2VvcmdpYSAwMTA1PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGVsOiArOTk1IDMyIDEyMyA0NTY3PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+RW1haWw6IGluZm9AZ3J1enlhYWR2ZW50dXJlcy5jb208L3RleHQ+CgogIDwhLS0gSW52b2ljZSBUaXRsZSAtLT4KICA8dGV4dCB4PSI2MDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+SU5WT0lDRTwvdGV4dD4KICA8dGV4dCB4PSI2MDAiIHk9IjE0MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5EYXRlOiAxMi8xMS8yMDI0PC90ZXh0PgogIDx0ZXh0IHg9IjYwMCIgeT0iMTYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkludm9pY2UgIzogR1JaLTIwMjQtMTEyMzwvdGV4dD4KCiAgPCEtLSBCaWxsIFRvIFNlY3Rpb24gLS0+CiAgPHRleHQgeD0iNDAiIHk9IjIyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+QklMTCBUTzo8L3RleHQ+CiAgPHJlY3QgeD0iNDAiIHk9IjIzNSIgd2lkdGg9IjMwMCIgaGVpZ2h0PSI4MCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSIyNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0N1c3RvbWVyIE5hbWVdPC90ZXh0PgogIDx0ZXh0IHg9IjUwIiB5PSIyODAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0FkZHJlc3MgTGluZSAxXTwvdGV4dD4KICA8dGV4dCB4PSI1MCIgeT0iMzAwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPltDaXR5LCBDb3VudHJ5XTwvdGV4dD4KCiAgPCEtLSBUYWJsZSBIZWFkZXJzIC0tPgogIDxyZWN0IHg9IjQwIiB5PSIzNDAiIHdpZHRoPSI3MjAiIGhlaWdodD0iMzAiIGZpbGw9IiMyYzNlNTAiLz4KICA8dGV4dCB4PSI1MCIgeT0iMzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSJ3aGl0ZSI+RGVzY3JpcHRpb248L3RleHQ+CiAgPHRleHQgeD0iNDUwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5RdWFudGl0eTwvdGV4dD4KICA8dGV4dCB4PSI1NTAiIHk9IjM2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0id2hpdGUiPlJhdGU8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5BbW91bnQ8L3RleHQ+CgogIDwhLS0gVGFibGUgUm93cyAtLT4KICA8cmVjdCB4PSI0MCIgeT0iMzcwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSIjZjdmOWZhIi8+CiAgPHRleHQgeD0iNTAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5Nb3VudGFpbiBDbGltYmluZyBFcXVpcG1lbnQgUmVudGFsPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iMzkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSIzOTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDI1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMjUwLjAwPC90ZXh0PgoKICA8cmVjdCB4PSI0MCIgeT0iNDAwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSJ3aGl0ZSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+R3VpZGVkIFRyZWsgUGFja2FnZSAtIDIgRGF5czwvdGV4dD4KICA8dGV4dCB4PSI0NTAiIHk9IjQyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNDIwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQ0MDAuMDA8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDQwMC4wMDwvdGV4dD4KCiAgPHJlY3QgeD0iNDAiIHk9IjQzMCIgd2lkdGg9IjcyMCIgaGVpZ2h0PSIzMCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U2FmZXR5IEVxdWlwbWVudCBQYWNrYWdlPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iNDUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDE1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjQ1MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMTUwLjAwPC90ZXh0PgoKICA8IS0tIFRvdGFscyAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI0ODAiIHgyPSI3NjAiIHkyPSI0ODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNTUwIiB5PSI1MTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMzNDQ5NWUiPlN1YnRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjUxMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kODAwLjAwPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSIjMzQ0OTVlIj5UYXggKDE4JSk6PC90ZXh0PgogIDx0ZXh0IHg9IjY4MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQxNDQuMDA8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI1NzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjU3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+JDk0NC4wMDwvdGV4dD4KCiAgPCEtLSBQYXltZW50IFRlcm1zIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2NDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlBheW1lbnQgVGVybXM8L3RleHQ+CiAgPHRleHQgeD0iNDAiIHk9IjY3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5QYXltZW50IGlzIGR1ZSB3aXRoaW4gMzAgZGF5czwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNjkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPlBsZWFzZSBpbmNsdWRlIGludm9pY2UgbnVtYmVyIG9uIHBheW1lbnQ8L3RleHQ+CgogIDwhLS0gQmFuayBEZXRhaWxzIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI3MzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPkJhbmsgRGV0YWlsczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkJhbms6IEJhbmsgb2YgR2VvcmdpYTwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzgwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPklCQU46IEdFMTIzNDU2Nzg5MDEyMzQ1Njc4PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSI4MDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U1dJRlQ6IEJBR0FHRTIyPC90ZXh0PgoKICA8IS0tIEZvb3RlciAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI5MDAiIHgyPSI3NjAiIHkyPSI5MDAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNDAiIHk9IjkzMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjEyIiBmaWxsPSIjN2Y4YzhkIj5UaGFuayB5b3UgZm9yIGNob29zaW5nIEdydXp5YSBBZHZlbnR1cmUgT3V0Zml0dGVyczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iOTUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTIiIGZpbGw9IiM3ZjhjOGQiPnd3dy5ncnV6eWFhZHZlbnR1cmVzLmNvbTwvdGV4dD4KPC9zdmc+Cg==", filename="logo.jpg", ftype="jpg", furl="", ), redirect_after_approve=True, redirect_after_approve_url="https://example.com/success", ), ) ``` ```csharp GeneratePaymentLink using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.AddPayLinkFromInvoiceAsync( 23548884, new PayLinkDataInvoice { Mail2 = "jo@example.com; ceo@example.com", Body = new PaymentPageRequestBody { ContactUs = new ContactElement { EmailLabel = "Email", Enabled = true, Header = "Contact Us", Order = 0, PaymentIcons = true, PhoneLabel = "Phone" }, Invoices = new InvoiceElement { Enabled = true, InvoiceLink = new LabelElement { Enabled = true, Label = "View Invoice", Order = 0 }, Order = 0, ViewInvoiceDetails = new LabelElement { Enabled = true, Label = "Invoice Details", Order = 0 } }, Logo = new Element { Enabled = true, Order = 0 }, MessageBeforePaying = new LabelElement { Enabled = true, Label = "Please review your payment details", Order = 0 }, Notes = new NoteElement { Enabled = true, Header = "Additional Notes", Order = 0, Placeholder = "Enter any additional notes here", Value = "" }, Page = new PageElement { Description = "Complete your payment securely", Enabled = true, Header = "Payment Page", Order = 0 }, PaymentButton = new LabelElement { Enabled = true, Label = "Pay Now", Order = 0 }, PaymentMethods = new MethodElement { AllMethodsChecked = true, Enabled = true, Header = "Payment Methods", Methods = new MethodsList { Amex = true, ApplePay = true, Discover = true, ECheck = true, Mastercard = true, Visa = true }, Order = 0, Settings = new MethodElementSettings { ApplePay = new MethodElementSettingsApplePay { ButtonStyle = MethodElementSettingsApplePayButtonStyle.Black, ButtonType = MethodElementSettingsApplePayButtonType.Pay, Language = MethodElementSettingsApplePayLanguage.EnUs } } }, Payor = new PayorElement { Enabled = true, Fields = new List(){ new PayorFields { Display = true, Fixed = true, Identifier = true, Label = "Full Name", Name = "fullName", Order = 0, Required = true, Validation = "alpha", Value = "", Width = 0 }, } , Header = "Payor Information", Order = 0 }, Review = new HeaderElement { Enabled = true, Header = "Review Payment", Order = 0 }, Settings = new PagelinkSetting { Color = "#000000", CustomCssUrl = "https://example.com/custom.css", Language = "en", PageLogo = new FileContent { FContent = "PHN2ZyB2aWV3Qm94PSIwIDAgODAwIDEwMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPCEtLSBCYWNrZ3JvdW5kIC0tPgogIDxyZWN0IHdpZHRoPSI4MDAiIGhlaWdodD0iMTAwMCIgZmlsbD0id2hpdGUiLz4KICAKICA8IS0tIENvbXBhbnkgSGVhZGVyIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+R3J1enlhIEFkdmVudHVyZSBPdXRmaXR0ZXJzPC90ZXh0PgogIDxsaW5lIHgxPSI0MCIgeTE9IjgwIiB4Mj0iNzYwIiB5Mj0iODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgCiAgPCEtLSBDb21wYW55IERldGFpbHMgLS0+CiAgPHRleHQgeD0iNDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xMjMgTW91bnRhaW4gVmlldyBSb2FkPC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxMzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGJpbGlzaSwgR2VvcmdpYSAwMTA1PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGVsOiArOTk1IDMyIDEyMyA0NTY3PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+RW1haWw6IGluZm9AZ3J1enlhYWR2ZW50dXJlcy5jb208L3RleHQ+CgogIDwhLS0gSW52b2ljZSBUaXRsZSAtLT4KICA8dGV4dCB4PSI2MDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+SU5WT0lDRTwvdGV4dD4KICA8dGV4dCB4PSI2MDAiIHk9IjE0MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5EYXRlOiAxMi8xMS8yMDI0PC90ZXh0PgogIDx0ZXh0IHg9IjYwMCIgeT0iMTYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkludm9pY2UgIzogR1JaLTIwMjQtMTEyMzwvdGV4dD4KCiAgPCEtLSBCaWxsIFRvIFNlY3Rpb24gLS0+CiAgPHRleHQgeD0iNDAiIHk9IjIyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+QklMTCBUTzo8L3RleHQ+CiAgPHJlY3QgeD0iNDAiIHk9IjIzNSIgd2lkdGg9IjMwMCIgaGVpZ2h0PSI4MCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSIyNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0N1c3RvbWVyIE5hbWVdPC90ZXh0PgogIDx0ZXh0IHg9IjUwIiB5PSIyODAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0FkZHJlc3MgTGluZSAxXTwvdGV4dD4KICA8dGV4dCB4PSI1MCIgeT0iMzAwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPltDaXR5LCBDb3VudHJ5XTwvdGV4dD4KCiAgPCEtLSBUYWJsZSBIZWFkZXJzIC0tPgogIDxyZWN0IHg9IjQwIiB5PSIzNDAiIHdpZHRoPSI3MjAiIGhlaWdodD0iMzAiIGZpbGw9IiMyYzNlNTAiLz4KICA8dGV4dCB4PSI1MCIgeT0iMzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSJ3aGl0ZSI+RGVzY3JpcHRpb248L3RleHQ+CiAgPHRleHQgeD0iNDUwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5RdWFudGl0eTwvdGV4dD4KICA8dGV4dCB4PSI1NTAiIHk9IjM2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0id2hpdGUiPlJhdGU8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5BbW91bnQ8L3RleHQ+CgogIDwhLS0gVGFibGUgUm93cyAtLT4KICA8cmVjdCB4PSI0MCIgeT0iMzcwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSIjZjdmOWZhIi8+CiAgPHRleHQgeD0iNTAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5Nb3VudGFpbiBDbGltYmluZyBFcXVpcG1lbnQgUmVudGFsPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iMzkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSIzOTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDI1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMjUwLjAwPC90ZXh0PgoKICA8cmVjdCB4PSI0MCIgeT0iNDAwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSJ3aGl0ZSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+R3VpZGVkIFRyZWsgUGFja2FnZSAtIDIgRGF5czwvdGV4dD4KICA8dGV4dCB4PSI0NTAiIHk9IjQyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNDIwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQ0MDAuMDA8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDQwMC4wMDwvdGV4dD4KCiAgPHJlY3QgeD0iNDAiIHk9IjQzMCIgd2lkdGg9IjcyMCIgaGVpZ2h0PSIzMCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U2FmZXR5IEVxdWlwbWVudCBQYWNrYWdlPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iNDUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDE1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjQ1MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMTUwLjAwPC90ZXh0PgoKICA8IS0tIFRvdGFscyAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI0ODAiIHgyPSI3NjAiIHkyPSI0ODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNTUwIiB5PSI1MTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMzNDQ5NWUiPlN1YnRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjUxMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kODAwLjAwPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSIjMzQ0OTVlIj5UYXggKDE4JSk6PC90ZXh0PgogIDx0ZXh0IHg9IjY4MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQxNDQuMDA8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI1NzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjU3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+JDk0NC4wMDwvdGV4dD4KCiAgPCEtLSBQYXltZW50IFRlcm1zIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2NDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlBheW1lbnQgVGVybXM8L3RleHQ+CiAgPHRleHQgeD0iNDAiIHk9IjY3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5QYXltZW50IGlzIGR1ZSB3aXRoaW4gMzAgZGF5czwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNjkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPlBsZWFzZSBpbmNsdWRlIGludm9pY2UgbnVtYmVyIG9uIHBheW1lbnQ8L3RleHQ+CgogIDwhLS0gQmFuayBEZXRhaWxzIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI3MzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPkJhbmsgRGV0YWlsczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkJhbms6IEJhbmsgb2YgR2VvcmdpYTwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzgwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPklCQU46IEdFMTIzNDU2Nzg5MDEyMzQ1Njc4PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSI4MDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U1dJRlQ6IEJBR0FHRTIyPC90ZXh0PgoKICA8IS0tIEZvb3RlciAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI5MDAiIHgyPSI3NjAiIHkyPSI5MDAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNDAiIHk9IjkzMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjEyIiBmaWxsPSIjN2Y4YzhkIj5UaGFuayB5b3UgZm9yIGNob29zaW5nIEdydXp5YSBBZHZlbnR1cmUgT3V0Zml0dGVyczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iOTUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTIiIGZpbGw9IiM3ZjhjOGQiPnd3dy5ncnV6eWFhZHZlbnR1cmVzLmNvbTwvdGV4dD4KPC9zdmc+Cg==", Filename = "logo.jpg", Ftype = FileContentFtype.Jpg, Furl = "" }, RedirectAfterApprove = true, RedirectAfterApproveUrl = "https://example.com/success" } } } ); } } ``` ```go GeneratePaymentLink package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/23548884?mail2=jo%40example.com%3B+ceo%40example.com" payload := strings.NewReader("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"invoices\": {\n \"enabled\": true,\n \"invoiceLink\": {\n \"enabled\": true,\n \"label\": \"View Invoice\",\n \"order\": 0\n },\n \"order\": 0,\n \"viewInvoiceDetails\": {\n \"enabled\": true,\n \"label\": \"Invoice Details\",\n \"order\": 0\n }\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Complete your payment securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"amex\": true,\n \"applePay\": true,\n \"discover\": true,\n \"eCheck\": true,\n \"mastercard\": true,\n \"visa\": true\n },\n \"order\": 0,\n \"settings\": {\n \"applePay\": {\n \"buttonStyle\": \"black\",\n \"buttonType\": \"pay\",\n \"language\": \"en-US\"\n }\n }\n },\n \"payor\": {\n \"enabled\": true,\n \"fields\": [\n {\n \"display\": true,\n \"fixed\": true,\n \"identifier\": true,\n \"label\": \"Full Name\",\n \"name\": \"fullName\",\n \"order\": 0,\n \"required\": true,\n \"validation\": \"alpha\",\n \"value\": \"\",\n \"width\": 0\n }\n ],\n \"header\": \"Payor Information\",\n \"order\": 0\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"customCssUrl\": \"https://example.com/custom.css\",\n \"language\": \"en\",\n \"pageLogo\": {\n \"fContent\": \"PHN2ZyB2aWV3Qm94PSIwIDAgODAwIDEwMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPCEtLSBCYWNrZ3JvdW5kIC0tPgogIDxyZWN0IHdpZHRoPSI4MDAiIGhlaWdodD0iMTAwMCIgZmlsbD0id2hpdGUiLz4KICAKICA8IS0tIENvbXBhbnkgSGVhZGVyIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+R3J1enlhIEFkdmVudHVyZSBPdXRmaXR0ZXJzPC90ZXh0PgogIDxsaW5lIHgxPSI0MCIgeTE9IjgwIiB4Mj0iNzYwIiB5Mj0iODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgCiAgPCEtLSBDb21wYW55IERldGFpbHMgLS0+CiAgPHRleHQgeD0iNDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xMjMgTW91bnRhaW4gVmlldyBSb2FkPC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxMzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGJpbGlzaSwgR2VvcmdpYSAwMTA1PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGVsOiArOTk1IDMyIDEyMyA0NTY3PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+RW1haWw6IGluZm9AZ3J1enlhYWR2ZW50dXJlcy5jb208L3RleHQ+CgogIDwhLS0gSW52b2ljZSBUaXRsZSAtLT4KICA8dGV4dCB4PSI2MDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+SU5WT0lDRTwvdGV4dD4KICA8dGV4dCB4PSI2MDAiIHk9IjE0MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5EYXRlOiAxMi8xMS8yMDI0PC90ZXh0PgogIDx0ZXh0IHg9IjYwMCIgeT0iMTYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkludm9pY2UgIzogR1JaLTIwMjQtMTEyMzwvdGV4dD4KCiAgPCEtLSBCaWxsIFRvIFNlY3Rpb24gLS0+CiAgPHRleHQgeD0iNDAiIHk9IjIyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+QklMTCBUTzo8L3RleHQ+CiAgPHJlY3QgeD0iNDAiIHk9IjIzNSIgd2lkdGg9IjMwMCIgaGVpZ2h0PSI4MCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSIyNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0N1c3RvbWVyIE5hbWVdPC90ZXh0PgogIDx0ZXh0IHg9IjUwIiB5PSIyODAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0FkZHJlc3MgTGluZSAxXTwvdGV4dD4KICA8dGV4dCB4PSI1MCIgeT0iMzAwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPltDaXR5LCBDb3VudHJ5XTwvdGV4dD4KCiAgPCEtLSBUYWJsZSBIZWFkZXJzIC0tPgogIDxyZWN0IHg9IjQwIiB5PSIzNDAiIHdpZHRoPSI3MjAiIGhlaWdodD0iMzAiIGZpbGw9IiMyYzNlNTAiLz4KICA8dGV4dCB4PSI1MCIgeT0iMzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSJ3aGl0ZSI+RGVzY3JpcHRpb248L3RleHQ+CiAgPHRleHQgeD0iNDUwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5RdWFudGl0eTwvdGV4dD4KICA8dGV4dCB4PSI1NTAiIHk9IjM2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0id2hpdGUiPlJhdGU8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5BbW91bnQ8L3RleHQ+CgogIDwhLS0gVGFibGUgUm93cyAtLT4KICA8cmVjdCB4PSI0MCIgeT0iMzcwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSIjZjdmOWZhIi8+CiAgPHRleHQgeD0iNTAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5Nb3VudGFpbiBDbGltYmluZyBFcXVpcG1lbnQgUmVudGFsPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iMzkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSIzOTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDI1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMjUwLjAwPC90ZXh0PgoKICA8cmVjdCB4PSI0MCIgeT0iNDAwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSJ3aGl0ZSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+R3VpZGVkIFRyZWsgUGFja2FnZSAtIDIgRGF5czwvdGV4dD4KICA8dGV4dCB4PSI0NTAiIHk9IjQyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNDIwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQ0MDAuMDA8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDQwMC4wMDwvdGV4dD4KCiAgPHJlY3QgeD0iNDAiIHk9IjQzMCIgd2lkdGg9IjcyMCIgaGVpZ2h0PSIzMCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U2FmZXR5IEVxdWlwbWVudCBQYWNrYWdlPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iNDUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDE1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjQ1MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMTUwLjAwPC90ZXh0PgoKICA8IS0tIFRvdGFscyAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI0ODAiIHgyPSI3NjAiIHkyPSI0ODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNTUwIiB5PSI1MTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMzNDQ5NWUiPlN1YnRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjUxMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kODAwLjAwPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSIjMzQ0OTVlIj5UYXggKDE4JSk6PC90ZXh0PgogIDx0ZXh0IHg9IjY4MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQxNDQuMDA8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI1NzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjU3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+JDk0NC4wMDwvdGV4dD4KCiAgPCEtLSBQYXltZW50IFRlcm1zIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2NDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlBheW1lbnQgVGVybXM8L3RleHQ+CiAgPHRleHQgeD0iNDAiIHk9IjY3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5QYXltZW50IGlzIGR1ZSB3aXRoaW4gMzAgZGF5czwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNjkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPlBsZWFzZSBpbmNsdWRlIGludm9pY2UgbnVtYmVyIG9uIHBheW1lbnQ8L3RleHQ+CgogIDwhLS0gQmFuayBEZXRhaWxzIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI3MzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPkJhbmsgRGV0YWlsczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkJhbms6IEJhbmsgb2YgR2VvcmdpYTwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzgwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPklCQU46IEdFMTIzNDU2Nzg5MDEyMzQ1Njc4PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSI4MDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U1dJRlQ6IEJBR0FHRTIyPC90ZXh0PgoKICA8IS0tIEZvb3RlciAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI5MDAiIHgyPSI3NjAiIHkyPSI5MDAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNDAiIHk9IjkzMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjEyIiBmaWxsPSIjN2Y4YzhkIj5UaGFuayB5b3UgZm9yIGNob29zaW5nIEdydXp5YSBBZHZlbnR1cmUgT3V0Zml0dGVyczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iOTUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTIiIGZpbGw9IiM3ZjhjOGQiPnd3dy5ncnV6eWFhZHZlbnR1cmVzLmNvbTwvdGV4dD4KPC9zdmc+Cg==\",\n \"filename\": \"logo.jpg\",\n \"ftype\": \"jpg\",\n \"furl\": \"\"\n },\n \"redirectAfterApprove\": true,\n \"redirectAfterApproveUrl\": \"https://example.com/success\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GeneratePaymentLink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/23548884?mail2=jo%40example.com%3B+ceo%40example.com") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"invoices\": {\n \"enabled\": true,\n \"invoiceLink\": {\n \"enabled\": true,\n \"label\": \"View Invoice\",\n \"order\": 0\n },\n \"order\": 0,\n \"viewInvoiceDetails\": {\n \"enabled\": true,\n \"label\": \"Invoice Details\",\n \"order\": 0\n }\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Complete your payment securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"amex\": true,\n \"applePay\": true,\n \"discover\": true,\n \"eCheck\": true,\n \"mastercard\": true,\n \"visa\": true\n },\n \"order\": 0,\n \"settings\": {\n \"applePay\": {\n \"buttonStyle\": \"black\",\n \"buttonType\": \"pay\",\n \"language\": \"en-US\"\n }\n }\n },\n \"payor\": {\n \"enabled\": true,\n \"fields\": [\n {\n \"display\": true,\n \"fixed\": true,\n \"identifier\": true,\n \"label\": \"Full Name\",\n \"name\": \"fullName\",\n \"order\": 0,\n \"required\": true,\n \"validation\": \"alpha\",\n \"value\": \"\",\n \"width\": 0\n }\n ],\n \"header\": \"Payor Information\",\n \"order\": 0\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"customCssUrl\": \"https://example.com/custom.css\",\n \"language\": \"en\",\n \"pageLogo\": {\n \"fContent\": \"PHN2ZyB2aWV3Qm94PSIwIDAgODAwIDEwMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPCEtLSBCYWNrZ3JvdW5kIC0tPgogIDxyZWN0IHdpZHRoPSI4MDAiIGhlaWdodD0iMTAwMCIgZmlsbD0id2hpdGUiLz4KICAKICA8IS0tIENvbXBhbnkgSGVhZGVyIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+R3J1enlhIEFkdmVudHVyZSBPdXRmaXR0ZXJzPC90ZXh0PgogIDxsaW5lIHgxPSI0MCIgeTE9IjgwIiB4Mj0iNzYwIiB5Mj0iODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgCiAgPCEtLSBDb21wYW55IERldGFpbHMgLS0+CiAgPHRleHQgeD0iNDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xMjMgTW91bnRhaW4gVmlldyBSb2FkPC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxMzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGJpbGlzaSwgR2VvcmdpYSAwMTA1PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGVsOiArOTk1IDMyIDEyMyA0NTY3PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+RW1haWw6IGluZm9AZ3J1enlhYWR2ZW50dXJlcy5jb208L3RleHQ+CgogIDwhLS0gSW52b2ljZSBUaXRsZSAtLT4KICA8dGV4dCB4PSI2MDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+SU5WT0lDRTwvdGV4dD4KICA8dGV4dCB4PSI2MDAiIHk9IjE0MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5EYXRlOiAxMi8xMS8yMDI0PC90ZXh0PgogIDx0ZXh0IHg9IjYwMCIgeT0iMTYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkludm9pY2UgIzogR1JaLTIwMjQtMTEyMzwvdGV4dD4KCiAgPCEtLSBCaWxsIFRvIFNlY3Rpb24gLS0+CiAgPHRleHQgeD0iNDAiIHk9IjIyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+QklMTCBUTzo8L3RleHQ+CiAgPHJlY3QgeD0iNDAiIHk9IjIzNSIgd2lkdGg9IjMwMCIgaGVpZ2h0PSI4MCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSIyNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0N1c3RvbWVyIE5hbWVdPC90ZXh0PgogIDx0ZXh0IHg9IjUwIiB5PSIyODAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0FkZHJlc3MgTGluZSAxXTwvdGV4dD4KICA8dGV4dCB4PSI1MCIgeT0iMzAwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPltDaXR5LCBDb3VudHJ5XTwvdGV4dD4KCiAgPCEtLSBUYWJsZSBIZWFkZXJzIC0tPgogIDxyZWN0IHg9IjQwIiB5PSIzNDAiIHdpZHRoPSI3MjAiIGhlaWdodD0iMzAiIGZpbGw9IiMyYzNlNTAiLz4KICA8dGV4dCB4PSI1MCIgeT0iMzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSJ3aGl0ZSI+RGVzY3JpcHRpb248L3RleHQ+CiAgPHRleHQgeD0iNDUwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5RdWFudGl0eTwvdGV4dD4KICA8dGV4dCB4PSI1NTAiIHk9IjM2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0id2hpdGUiPlJhdGU8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5BbW91bnQ8L3RleHQ+CgogIDwhLS0gVGFibGUgUm93cyAtLT4KICA8cmVjdCB4PSI0MCIgeT0iMzcwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSIjZjdmOWZhIi8+CiAgPHRleHQgeD0iNTAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5Nb3VudGFpbiBDbGltYmluZyBFcXVpcG1lbnQgUmVudGFsPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iMzkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSIzOTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDI1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMjUwLjAwPC90ZXh0PgoKICA8cmVjdCB4PSI0MCIgeT0iNDAwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSJ3aGl0ZSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+R3VpZGVkIFRyZWsgUGFja2FnZSAtIDIgRGF5czwvdGV4dD4KICA8dGV4dCB4PSI0NTAiIHk9IjQyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNDIwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQ0MDAuMDA8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDQwMC4wMDwvdGV4dD4KCiAgPHJlY3QgeD0iNDAiIHk9IjQzMCIgd2lkdGg9IjcyMCIgaGVpZ2h0PSIzMCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U2FmZXR5IEVxdWlwbWVudCBQYWNrYWdlPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iNDUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDE1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjQ1MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMTUwLjAwPC90ZXh0PgoKICA8IS0tIFRvdGFscyAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI0ODAiIHgyPSI3NjAiIHkyPSI0ODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNTUwIiB5PSI1MTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMzNDQ5NWUiPlN1YnRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjUxMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kODAwLjAwPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSIjMzQ0OTVlIj5UYXggKDE4JSk6PC90ZXh0PgogIDx0ZXh0IHg9IjY4MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQxNDQuMDA8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI1NzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjU3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+JDk0NC4wMDwvdGV4dD4KCiAgPCEtLSBQYXltZW50IFRlcm1zIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2NDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlBheW1lbnQgVGVybXM8L3RleHQ+CiAgPHRleHQgeD0iNDAiIHk9IjY3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5QYXltZW50IGlzIGR1ZSB3aXRoaW4gMzAgZGF5czwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNjkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPlBsZWFzZSBpbmNsdWRlIGludm9pY2UgbnVtYmVyIG9uIHBheW1lbnQ8L3RleHQ+CgogIDwhLS0gQmFuayBEZXRhaWxzIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI3MzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPkJhbmsgRGV0YWlsczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkJhbms6IEJhbmsgb2YgR2VvcmdpYTwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzgwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPklCQU46IEdFMTIzNDU2Nzg5MDEyMzQ1Njc4PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSI4MDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U1dJRlQ6IEJBR0FHRTIyPC90ZXh0PgoKICA8IS0tIEZvb3RlciAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI5MDAiIHgyPSI3NjAiIHkyPSI5MDAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNDAiIHk9IjkzMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjEyIiBmaWxsPSIjN2Y4YzhkIj5UaGFuayB5b3UgZm9yIGNob29zaW5nIEdydXp5YSBBZHZlbnR1cmUgT3V0Zml0dGVyczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iOTUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTIiIGZpbGw9IiM3ZjhjOGQiPnd3dy5ncnV6eWFhZHZlbnR1cmVzLmNvbTwvdGV4dD4KPC9zdmc+Cg==\",\n \"filename\": \"logo.jpg\",\n \"ftype\": \"jpg\",\n \"furl\": \"\"\n },\n \"redirectAfterApprove\": true,\n \"redirectAfterApproveUrl\": \"https://example.com/success\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java GeneratePaymentLink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentLink/23548884?mail2=jo%40example.com%3B+ceo%40example.com") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"invoices\": {\n \"enabled\": true,\n \"invoiceLink\": {\n \"enabled\": true,\n \"label\": \"View Invoice\",\n \"order\": 0\n },\n \"order\": 0,\n \"viewInvoiceDetails\": {\n \"enabled\": true,\n \"label\": \"Invoice Details\",\n \"order\": 0\n }\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Complete your payment securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"amex\": true,\n \"applePay\": true,\n \"discover\": true,\n \"eCheck\": true,\n \"mastercard\": true,\n \"visa\": true\n },\n \"order\": 0,\n \"settings\": {\n \"applePay\": {\n \"buttonStyle\": \"black\",\n \"buttonType\": \"pay\",\n \"language\": \"en-US\"\n }\n }\n },\n \"payor\": {\n \"enabled\": true,\n \"fields\": [\n {\n \"display\": true,\n \"fixed\": true,\n \"identifier\": true,\n \"label\": \"Full Name\",\n \"name\": \"fullName\",\n \"order\": 0,\n \"required\": true,\n \"validation\": \"alpha\",\n \"value\": \"\",\n \"width\": 0\n }\n ],\n \"header\": \"Payor Information\",\n \"order\": 0\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"customCssUrl\": \"https://example.com/custom.css\",\n \"language\": \"en\",\n \"pageLogo\": {\n \"fContent\": \"PHN2ZyB2aWV3Qm94PSIwIDAgODAwIDEwMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPCEtLSBCYWNrZ3JvdW5kIC0tPgogIDxyZWN0IHdpZHRoPSI4MDAiIGhlaWdodD0iMTAwMCIgZmlsbD0id2hpdGUiLz4KICAKICA8IS0tIENvbXBhbnkgSGVhZGVyIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+R3J1enlhIEFkdmVudHVyZSBPdXRmaXR0ZXJzPC90ZXh0PgogIDxsaW5lIHgxPSI0MCIgeTE9IjgwIiB4Mj0iNzYwIiB5Mj0iODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgCiAgPCEtLSBDb21wYW55IERldGFpbHMgLS0+CiAgPHRleHQgeD0iNDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xMjMgTW91bnRhaW4gVmlldyBSb2FkPC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxMzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGJpbGlzaSwgR2VvcmdpYSAwMTA1PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGVsOiArOTk1IDMyIDEyMyA0NTY3PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+RW1haWw6IGluZm9AZ3J1enlhYWR2ZW50dXJlcy5jb208L3RleHQ+CgogIDwhLS0gSW52b2ljZSBUaXRsZSAtLT4KICA8dGV4dCB4PSI2MDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+SU5WT0lDRTwvdGV4dD4KICA8dGV4dCB4PSI2MDAiIHk9IjE0MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5EYXRlOiAxMi8xMS8yMDI0PC90ZXh0PgogIDx0ZXh0IHg9IjYwMCIgeT0iMTYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkludm9pY2UgIzogR1JaLTIwMjQtMTEyMzwvdGV4dD4KCiAgPCEtLSBCaWxsIFRvIFNlY3Rpb24gLS0+CiAgPHRleHQgeD0iNDAiIHk9IjIyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+QklMTCBUTzo8L3RleHQ+CiAgPHJlY3QgeD0iNDAiIHk9IjIzNSIgd2lkdGg9IjMwMCIgaGVpZ2h0PSI4MCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSIyNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0N1c3RvbWVyIE5hbWVdPC90ZXh0PgogIDx0ZXh0IHg9IjUwIiB5PSIyODAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0FkZHJlc3MgTGluZSAxXTwvdGV4dD4KICA8dGV4dCB4PSI1MCIgeT0iMzAwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPltDaXR5LCBDb3VudHJ5XTwvdGV4dD4KCiAgPCEtLSBUYWJsZSBIZWFkZXJzIC0tPgogIDxyZWN0IHg9IjQwIiB5PSIzNDAiIHdpZHRoPSI3MjAiIGhlaWdodD0iMzAiIGZpbGw9IiMyYzNlNTAiLz4KICA8dGV4dCB4PSI1MCIgeT0iMzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSJ3aGl0ZSI+RGVzY3JpcHRpb248L3RleHQ+CiAgPHRleHQgeD0iNDUwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5RdWFudGl0eTwvdGV4dD4KICA8dGV4dCB4PSI1NTAiIHk9IjM2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0id2hpdGUiPlJhdGU8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5BbW91bnQ8L3RleHQ+CgogIDwhLS0gVGFibGUgUm93cyAtLT4KICA8cmVjdCB4PSI0MCIgeT0iMzcwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSIjZjdmOWZhIi8+CiAgPHRleHQgeD0iNTAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5Nb3VudGFpbiBDbGltYmluZyBFcXVpcG1lbnQgUmVudGFsPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iMzkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSIzOTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDI1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMjUwLjAwPC90ZXh0PgoKICA8cmVjdCB4PSI0MCIgeT0iNDAwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSJ3aGl0ZSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+R3VpZGVkIFRyZWsgUGFja2FnZSAtIDIgRGF5czwvdGV4dD4KICA8dGV4dCB4PSI0NTAiIHk9IjQyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNDIwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQ0MDAuMDA8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDQwMC4wMDwvdGV4dD4KCiAgPHJlY3QgeD0iNDAiIHk9IjQzMCIgd2lkdGg9IjcyMCIgaGVpZ2h0PSIzMCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U2FmZXR5IEVxdWlwbWVudCBQYWNrYWdlPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iNDUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDE1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjQ1MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMTUwLjAwPC90ZXh0PgoKICA8IS0tIFRvdGFscyAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI0ODAiIHgyPSI3NjAiIHkyPSI0ODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNTUwIiB5PSI1MTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMzNDQ5NWUiPlN1YnRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjUxMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kODAwLjAwPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSIjMzQ0OTVlIj5UYXggKDE4JSk6PC90ZXh0PgogIDx0ZXh0IHg9IjY4MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQxNDQuMDA8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI1NzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjU3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+JDk0NC4wMDwvdGV4dD4KCiAgPCEtLSBQYXltZW50IFRlcm1zIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2NDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlBheW1lbnQgVGVybXM8L3RleHQ+CiAgPHRleHQgeD0iNDAiIHk9IjY3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5QYXltZW50IGlzIGR1ZSB3aXRoaW4gMzAgZGF5czwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNjkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPlBsZWFzZSBpbmNsdWRlIGludm9pY2UgbnVtYmVyIG9uIHBheW1lbnQ8L3RleHQ+CgogIDwhLS0gQmFuayBEZXRhaWxzIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI3MzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPkJhbmsgRGV0YWlsczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkJhbms6IEJhbmsgb2YgR2VvcmdpYTwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzgwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPklCQU46IEdFMTIzNDU2Nzg5MDEyMzQ1Njc4PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSI4MDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U1dJRlQ6IEJBR0FHRTIyPC90ZXh0PgoKICA8IS0tIEZvb3RlciAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI5MDAiIHgyPSI3NjAiIHkyPSI5MDAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNDAiIHk9IjkzMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjEyIiBmaWxsPSIjN2Y4YzhkIj5UaGFuayB5b3UgZm9yIGNob29zaW5nIEdydXp5YSBBZHZlbnR1cmUgT3V0Zml0dGVyczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iOTUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTIiIGZpbGw9IiM3ZjhjOGQiPnd3dy5ncnV6eWFhZHZlbnR1cmVzLmNvbTwvdGV4dD4KPC9zdmc+Cg==\",\n \"filename\": \"logo.jpg\",\n \"ftype\": \"jpg\",\n \"furl\": \"\"\n },\n \"redirectAfterApprove\": true,\n \"redirectAfterApproveUrl\": \"https://example.com/success\"\n }\n}") .asString(); ``` ```php GeneratePaymentLink request('POST', 'https://api-sandbox.payabli.com/api/PaymentLink/23548884?mail2=jo%40example.com%3B+ceo%40example.com', [ 'body' => '{ "contactUs": { "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" }, "invoices": { "enabled": true, "invoiceLink": { "enabled": true, "label": "View Invoice", "order": 0 }, "order": 0, "viewInvoiceDetails": { "enabled": true, "label": "Invoice Details", "order": 0 } }, "logo": { "enabled": true, "order": 0 }, "messageBeforePaying": { "enabled": true, "label": "Please review your payment details", "order": 0 }, "notes": { "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" }, "page": { "description": "Complete your payment securely", "enabled": true, "header": "Payment Page", "order": 0 }, "paymentButton": { "enabled": true, "label": "Pay Now", "order": 0 }, "paymentMethods": { "allMethodsChecked": true, "enabled": true, "header": "Payment Methods", "methods": { "amex": true, "applePay": true, "discover": true, "eCheck": true, "mastercard": true, "visa": true }, "order": 0, "settings": { "applePay": { "buttonStyle": "black", "buttonType": "pay", "language": "en-US" } } }, "payor": { "enabled": true, "fields": [ { "display": true, "fixed": true, "identifier": true, "label": "Full Name", "name": "fullName", "order": 0, "required": true, "validation": "alpha", "value": "", "width": 0 } ], "header": "Payor Information", "order": 0 }, "review": { "enabled": true, "header": "Review Payment", "order": 0 }, "settings": { "color": "#000000", "customCssUrl": "https://example.com/custom.css", "language": "en", "pageLogo": { "fContent": "PHN2ZyB2aWV3Qm94PSIwIDAgODAwIDEwMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPCEtLSBCYWNrZ3JvdW5kIC0tPgogIDxyZWN0IHdpZHRoPSI4MDAiIGhlaWdodD0iMTAwMCIgZmlsbD0id2hpdGUiLz4KICAKICA8IS0tIENvbXBhbnkgSGVhZGVyIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+R3J1enlhIEFkdmVudHVyZSBPdXRmaXR0ZXJzPC90ZXh0PgogIDxsaW5lIHgxPSI0MCIgeTE9IjgwIiB4Mj0iNzYwIiB5Mj0iODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgCiAgPCEtLSBDb21wYW55IERldGFpbHMgLS0+CiAgPHRleHQgeD0iNDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xMjMgTW91bnRhaW4gVmlldyBSb2FkPC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxMzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGJpbGlzaSwgR2VvcmdpYSAwMTA1PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGVsOiArOTk1IDMyIDEyMyA0NTY3PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+RW1haWw6IGluZm9AZ3J1enlhYWR2ZW50dXJlcy5jb208L3RleHQ+CgogIDwhLS0gSW52b2ljZSBUaXRsZSAtLT4KICA8dGV4dCB4PSI2MDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+SU5WT0lDRTwvdGV4dD4KICA8dGV4dCB4PSI2MDAiIHk9IjE0MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5EYXRlOiAxMi8xMS8yMDI0PC90ZXh0PgogIDx0ZXh0IHg9IjYwMCIgeT0iMTYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkludm9pY2UgIzogR1JaLTIwMjQtMTEyMzwvdGV4dD4KCiAgPCEtLSBCaWxsIFRvIFNlY3Rpb24gLS0+CiAgPHRleHQgeD0iNDAiIHk9IjIyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+QklMTCBUTzo8L3RleHQ+CiAgPHJlY3QgeD0iNDAiIHk9IjIzNSIgd2lkdGg9IjMwMCIgaGVpZ2h0PSI4MCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSIyNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0N1c3RvbWVyIE5hbWVdPC90ZXh0PgogIDx0ZXh0IHg9IjUwIiB5PSIyODAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0FkZHJlc3MgTGluZSAxXTwvdGV4dD4KICA8dGV4dCB4PSI1MCIgeT0iMzAwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPltDaXR5LCBDb3VudHJ5XTwvdGV4dD4KCiAgPCEtLSBUYWJsZSBIZWFkZXJzIC0tPgogIDxyZWN0IHg9IjQwIiB5PSIzNDAiIHdpZHRoPSI3MjAiIGhlaWdodD0iMzAiIGZpbGw9IiMyYzNlNTAiLz4KICA8dGV4dCB4PSI1MCIgeT0iMzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSJ3aGl0ZSI+RGVzY3JpcHRpb248L3RleHQ+CiAgPHRleHQgeD0iNDUwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5RdWFudGl0eTwvdGV4dD4KICA8dGV4dCB4PSI1NTAiIHk9IjM2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0id2hpdGUiPlJhdGU8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5BbW91bnQ8L3RleHQ+CgogIDwhLS0gVGFibGUgUm93cyAtLT4KICA8cmVjdCB4PSI0MCIgeT0iMzcwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSIjZjdmOWZhIi8+CiAgPHRleHQgeD0iNTAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5Nb3VudGFpbiBDbGltYmluZyBFcXVpcG1lbnQgUmVudGFsPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iMzkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSIzOTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDI1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMjUwLjAwPC90ZXh0PgoKICA8cmVjdCB4PSI0MCIgeT0iNDAwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSJ3aGl0ZSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+R3VpZGVkIFRyZWsgUGFja2FnZSAtIDIgRGF5czwvdGV4dD4KICA8dGV4dCB4PSI0NTAiIHk9IjQyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNDIwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQ0MDAuMDA8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDQwMC4wMDwvdGV4dD4KCiAgPHJlY3QgeD0iNDAiIHk9IjQzMCIgd2lkdGg9IjcyMCIgaGVpZ2h0PSIzMCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U2FmZXR5IEVxdWlwbWVudCBQYWNrYWdlPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iNDUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDE1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjQ1MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMTUwLjAwPC90ZXh0PgoKICA8IS0tIFRvdGFscyAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI0ODAiIHgyPSI3NjAiIHkyPSI0ODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNTUwIiB5PSI1MTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMzNDQ5NWUiPlN1YnRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjUxMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kODAwLjAwPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSIjMzQ0OTVlIj5UYXggKDE4JSk6PC90ZXh0PgogIDx0ZXh0IHg9IjY4MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQxNDQuMDA8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI1NzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjU3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+JDk0NC4wMDwvdGV4dD4KCiAgPCEtLSBQYXltZW50IFRlcm1zIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2NDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlBheW1lbnQgVGVybXM8L3RleHQ+CiAgPHRleHQgeD0iNDAiIHk9IjY3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5QYXltZW50IGlzIGR1ZSB3aXRoaW4gMzAgZGF5czwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNjkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPlBsZWFzZSBpbmNsdWRlIGludm9pY2UgbnVtYmVyIG9uIHBheW1lbnQ8L3RleHQ+CgogIDwhLS0gQmFuayBEZXRhaWxzIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI3MzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPkJhbmsgRGV0YWlsczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkJhbms6IEJhbmsgb2YgR2VvcmdpYTwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzgwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPklCQU46IEdFMTIzNDU2Nzg5MDEyMzQ1Njc4PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSI4MDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U1dJRlQ6IEJBR0FHRTIyPC90ZXh0PgoKICA8IS0tIEZvb3RlciAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI5MDAiIHgyPSI3NjAiIHkyPSI5MDAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNDAiIHk9IjkzMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjEyIiBmaWxsPSIjN2Y4YzhkIj5UaGFuayB5b3UgZm9yIGNob29zaW5nIEdydXp5YSBBZHZlbnR1cmUgT3V0Zml0dGVyczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iOTUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTIiIGZpbGw9IiM3ZjhjOGQiPnd3dy5ncnV6eWFhZHZlbnR1cmVzLmNvbTwvdGV4dD4KPC9zdmc+Cg==", "filename": "logo.jpg", "ftype": "jpg", "furl": "" }, "redirectAfterApprove": true, "redirectAfterApproveUrl": "https://example.com/success" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GeneratePaymentLink import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "contactUs": [ "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" ], "invoices": [ "enabled": true, "invoiceLink": [ "enabled": true, "label": "View Invoice", "order": 0 ], "order": 0, "viewInvoiceDetails": [ "enabled": true, "label": "Invoice Details", "order": 0 ] ], "logo": [ "enabled": true, "order": 0 ], "messageBeforePaying": [ "enabled": true, "label": "Please review your payment details", "order": 0 ], "notes": [ "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" ], "page": [ "description": "Complete your payment securely", "enabled": true, "header": "Payment Page", "order": 0 ], "paymentButton": [ "enabled": true, "label": "Pay Now", "order": 0 ], "paymentMethods": [ "allMethodsChecked": true, "enabled": true, "header": "Payment Methods", "methods": [ "amex": true, "applePay": true, "discover": true, "eCheck": true, "mastercard": true, "visa": true ], "order": 0, "settings": ["applePay": [ "buttonStyle": "black", "buttonType": "pay", "language": "en-US" ]] ], "payor": [ "enabled": true, "fields": [ [ "display": true, "fixed": true, "identifier": true, "label": "Full Name", "name": "fullName", "order": 0, "required": true, "validation": "alpha", "value": "", "width": 0 ] ], "header": "Payor Information", "order": 0 ], "review": [ "enabled": true, "header": "Review Payment", "order": 0 ], "settings": [ "color": "#000000", "customCssUrl": "https://example.com/custom.css", "language": "en", "pageLogo": [ "fContent": "PHN2ZyB2aWV3Qm94PSIwIDAgODAwIDEwMDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPCEtLSBCYWNrZ3JvdW5kIC0tPgogIDxyZWN0IHdpZHRoPSI4MDAiIGhlaWdodD0iMTAwMCIgZmlsbD0id2hpdGUiLz4KICAKICA8IS0tIENvbXBhbnkgSGVhZGVyIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+R3J1enlhIEFkdmVudHVyZSBPdXRmaXR0ZXJzPC90ZXh0PgogIDxsaW5lIHgxPSI0MCIgeTE9IjgwIiB4Mj0iNzYwIiB5Mj0iODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgCiAgPCEtLSBDb21wYW55IERldGFpbHMgLS0+CiAgPHRleHQgeD0iNDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xMjMgTW91bnRhaW4gVmlldyBSb2FkPC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxMzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGJpbGlzaSwgR2VvcmdpYSAwMTA1PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+VGVsOiArOTk1IDMyIDEyMyA0NTY3PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSIxNzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+RW1haWw6IGluZm9AZ3J1enlhYWR2ZW50dXJlcy5jb208L3RleHQ+CgogIDwhLS0gSW52b2ljZSBUaXRsZSAtLT4KICA8dGV4dCB4PSI2MDAiIHk9IjExMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjI0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+SU5WT0lDRTwvdGV4dD4KICA8dGV4dCB4PSI2MDAiIHk9IjE0MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5EYXRlOiAxMi8xMS8yMDI0PC90ZXh0PgogIDx0ZXh0IHg9IjYwMCIgeT0iMTYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkludm9pY2UgIzogR1JaLTIwMjQtMTEyMzwvdGV4dD4KCiAgPCEtLSBCaWxsIFRvIFNlY3Rpb24gLS0+CiAgPHRleHQgeD0iNDAiIHk9IjIyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+QklMTCBUTzo8L3RleHQ+CiAgPHJlY3QgeD0iNDAiIHk9IjIzNSIgd2lkdGg9IjMwMCIgaGVpZ2h0PSI4MCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSIyNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0N1c3RvbWVyIE5hbWVdPC90ZXh0PgogIDx0ZXh0IHg9IjUwIiB5PSIyODAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+W0FkZHJlc3MgTGluZSAxXTwvdGV4dD4KICA8dGV4dCB4PSI1MCIgeT0iMzAwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPltDaXR5LCBDb3VudHJ5XTwvdGV4dD4KCiAgPCEtLSBUYWJsZSBIZWFkZXJzIC0tPgogIDxyZWN0IHg9IjQwIiB5PSIzNDAiIHdpZHRoPSI3MjAiIGhlaWdodD0iMzAiIGZpbGw9IiMyYzNlNTAiLz4KICA8dGV4dCB4PSI1MCIgeT0iMzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSJ3aGl0ZSI+RGVzY3JpcHRpb248L3RleHQ+CiAgPHRleHQgeD0iNDUwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5RdWFudGl0eTwvdGV4dD4KICA8dGV4dCB4PSI1NTAiIHk9IjM2MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0id2hpdGUiPlJhdGU8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSIzNjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IndoaXRlIj5BbW91bnQ8L3RleHQ+CgogIDwhLS0gVGFibGUgUm93cyAtLT4KICA8cmVjdCB4PSI0MCIgeT0iMzcwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSIjZjdmOWZhIi8+CiAgPHRleHQgeD0iNTAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5Nb3VudGFpbiBDbGltYmluZyBFcXVpcG1lbnQgUmVudGFsPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iMzkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSIzOTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDI1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjM5MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMjUwLjAwPC90ZXh0PgoKICA8cmVjdCB4PSI0MCIgeT0iNDAwIiB3aWR0aD0iNzIwIiBoZWlnaHQ9IjMwIiBmaWxsPSJ3aGl0ZSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+R3VpZGVkIFRyZWsgUGFja2FnZSAtIDIgRGF5czwvdGV4dD4KICA8dGV4dCB4PSI0NTAiIHk9IjQyMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4xPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNDIwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQ0MDAuMDA8L3RleHQ+CiAgPHRleHQgeD0iNjgwIiB5PSI0MjAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDQwMC4wMDwvdGV4dD4KCiAgPHJlY3QgeD0iNDAiIHk9IjQzMCIgd2lkdGg9IjcyMCIgaGVpZ2h0PSIzMCIgZmlsbD0iI2Y3ZjlmYSIvPgogIDx0ZXh0IHg9IjUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U2FmZXR5IEVxdWlwbWVudCBQYWNrYWdlPC90ZXh0PgogIDx0ZXh0IHg9IjQ1MCIgeT0iNDUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPjE8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI0NTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+JDE1MC4wMDwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjQ1MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kMTUwLjAwPC90ZXh0PgoKICA8IS0tIFRvdGFscyAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI0ODAiIHgyPSI3NjAiIHkyPSI0ODAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNTUwIiB5PSI1MTAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMzNDQ5NWUiPlN1YnRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjUxMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj4kODAwLjAwPC90ZXh0PgogIDx0ZXh0IHg9IjU1MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZvbnQtd2VpZ2h0PSJib2xkIiBmaWxsPSIjMzQ0OTVlIj5UYXggKDE4JSk6PC90ZXh0PgogIDx0ZXh0IHg9IjY4MCIgeT0iNTM1IiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPiQxNDQuMDA8L3RleHQ+CiAgPHRleHQgeD0iNTUwIiB5PSI1NzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlRvdGFsOjwvdGV4dD4KICA8dGV4dCB4PSI2ODAiIHk9IjU3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE2IiBmb250LXdlaWdodD0iYm9sZCIgZmlsbD0iIzJjM2U1MCI+JDk0NC4wMDwvdGV4dD4KCiAgPCEtLSBQYXltZW50IFRlcm1zIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI2NDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPlBheW1lbnQgVGVybXM8L3RleHQ+CiAgPHRleHQgeD0iNDAiIHk9IjY3MCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjE0IiBmaWxsPSIjMzQ0OTVlIj5QYXltZW50IGlzIGR1ZSB3aXRoaW4gMzAgZGF5czwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNjkwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPlBsZWFzZSBpbmNsdWRlIGludm9pY2UgbnVtYmVyIG9uIHBheW1lbnQ8L3RleHQ+CgogIDwhLS0gQmFuayBEZXRhaWxzIC0tPgogIDx0ZXh0IHg9IjQwIiB5PSI3MzAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNiIgZm9udC13ZWlnaHQ9ImJvbGQiIGZpbGw9IiMyYzNlNTAiPkJhbmsgRGV0YWlsczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzYwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPkJhbms6IEJhbmsgb2YgR2VvcmdpYTwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iNzgwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTQiIGZpbGw9IiMzNDQ5NWUiPklCQU46IEdFMTIzNDU2Nzg5MDEyMzQ1Njc4PC90ZXh0PgogIDx0ZXh0IHg9IjQwIiB5PSI4MDAiIGZvbnQtZmFtaWx5PSJBcmlhbCIgZm9udC1zaXplPSIxNCIgZmlsbD0iIzM0NDk1ZSI+U1dJRlQ6IEJBR0FHRTIyPC90ZXh0PgoKICA8IS0tIEZvb3RlciAtLT4KICA8bGluZSB4MT0iNDAiIHkxPSI5MDAiIHgyPSI3NjAiIHkyPSI5MDAiIHN0cm9rZT0iIzJjM2U1MCIgc3Ryb2tlLXdpZHRoPSIxIi8+CiAgPHRleHQgeD0iNDAiIHk9IjkzMCIgZm9udC1mYW1pbHk9IkFyaWFsIiBmb250LXNpemU9IjEyIiBmaWxsPSIjN2Y4YzhkIj5UaGFuayB5b3UgZm9yIGNob29zaW5nIEdydXp5YSBBZHZlbnR1cmUgT3V0Zml0dGVyczwvdGV4dD4KICA8dGV4dCB4PSI0MCIgeT0iOTUwIiBmb250LWZhbWlseT0iQXJpYWwiIGZvbnQtc2l6ZT0iMTIiIGZpbGw9IiM3ZjhjOGQiPnd3dy5ncnV6eWFhZHZlbnR1cmVzLmNvbTwvdGV4dD4KPC9zdmc+Cg==", "filename": "logo.jpg", "ftype": "jpg", "furl": "" ], "redirectAfterApprove": true, "redirectAfterApproveUrl": "https://example.com/success" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/23548884?mail2=jo%40example.com%3B+ceo%40example.com")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create payment link from bill POST https://api-sandbox.payabli.com/api/PaymentLink/bill/{billId} Content-Type: application/json Generates a payment link for a bill from the bill ID. The vendor receives a secure page where they can select their preferred payment method (ACH, virtual card, or check) and complete the payment. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/generate-payment-link-from-bill ## SDK Code Examples ```typescript GeneratePaymentLink import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.addPayLinkFromBill(23548884, { mail2: "jo@example.com; ceo@example.com", body: { contactUs: { emailLabel: "Email", enabled: true, header: "Contact Us", order: 0, paymentIcons: true, phoneLabel: "Phone", }, logo: { enabled: true, order: 0, }, messageBeforePaying: { enabled: true, label: "Please review your payment details", order: 0, }, notes: { enabled: true, header: "Additional Notes", order: 0, placeholder: "Enter any additional notes here", value: "", }, page: { description: "Get paid securely", enabled: true, header: "Payment Page", order: 0, }, paymentButton: { enabled: true, label: "Pay Now", order: 0, }, paymentMethods: { allMethodsChecked: true, allowMultipleMethods: true, defaultMethod: "vcard", enabled: true, header: "Payment Methods", methods: { ach: true, check: true, vcard: true, }, order: 0, showPreviewVirtualCard: true, }, review: { enabled: true, header: "Review Payment", order: 0, }, settings: { color: "#000000", language: "en", }, }, }); } main(); ``` ```python GeneratePaymentLink from payabli import payabli, ContactElement, Element, LabelElement, NoteElement, PageElement, HeaderElement, PagelinkSetting from payabli.money_out_types import MethodElementOut, MethodsListOut client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.add_pay_link_from_bill( bill_id=23548884, mail_2="jo@example.com; ceo@example.com", contact_us=ContactElement( email_label="Email", enabled=True, header="Contact Us", order=0, payment_icons=True, phone_label="Phone", ), logo=Element( enabled=True, order=0, ), message_before_paying=LabelElement( enabled=True, label="Please review your payment details", order=0, ), notes=NoteElement( enabled=True, header="Additional Notes", order=0, placeholder="Enter any additional notes here", value="", ), page=PageElement( description="Get paid securely", enabled=True, header="Payment Page", order=0, ), payment_button=LabelElement( enabled=True, label="Pay Now", order=0, ), payment_methods=MethodElementOut( all_methods_checked=True, allow_multiple_methods=True, default_method="vcard", enabled=True, header="Payment Methods", methods=MethodsListOut( ach=True, check=True, vcard=True, ), order=0, show_preview_virtual_card=True, ), review=HeaderElement( enabled=True, header="Review Payment", order=0, ), settings=PagelinkSetting( color="#000000", language="en", ), ) ``` ```csharp GeneratePaymentLink using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.AddPayLinkFromBillAsync( 23548884, new PayLinkDataBill { Mail2 = "jo@example.com; ceo@example.com", Body = new PaymentPageRequestBodyOut { ContactUs = new ContactElement { EmailLabel = "Email", Enabled = true, Header = "Contact Us", Order = 0, PaymentIcons = true, PhoneLabel = "Phone" }, Logo = new Element { Enabled = true, Order = 0 }, MessageBeforePaying = new LabelElement { Enabled = true, Label = "Please review your payment details", Order = 0 }, Notes = new NoteElement { Enabled = true, Header = "Additional Notes", Order = 0, Placeholder = "Enter any additional notes here", Value = "" }, Page = new PageElement { Description = "Get paid securely", Enabled = true, Header = "Payment Page", Order = 0 }, PaymentButton = new LabelElement { Enabled = true, Label = "Pay Now", Order = 0 }, PaymentMethods = new MethodElementOut { AllMethodsChecked = true, AllowMultipleMethods = true, DefaultMethod = "vcard", Enabled = true, Header = "Payment Methods", Methods = new MethodsListOut { Ach = true, Check = true, Vcard = true }, Order = 0, ShowPreviewVirtualCard = true }, Review = new HeaderElement { Enabled = true, Header = "Review Payment", Order = 0 }, Settings = new PagelinkSetting { Color = "#000000", Language = "en" } } } ); } } ``` ```go GeneratePaymentLink package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884?mail2=jo%40example.com%3B+ceo%40example.com" payload := strings.NewReader("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GeneratePaymentLink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884?mail2=jo%40example.com%3B+ceo%40example.com") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java GeneratePaymentLink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884?mail2=jo%40example.com%3B+ceo%40example.com") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}") .asString(); ``` ```php GeneratePaymentLink request('POST', 'https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884?mail2=jo%40example.com%3B+ceo%40example.com', [ 'body' => '{ "contactUs": { "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" }, "logo": { "enabled": true, "order": 0 }, "messageBeforePaying": { "enabled": true, "label": "Please review your payment details", "order": 0 }, "notes": { "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" }, "page": { "description": "Get paid securely", "enabled": true, "header": "Payment Page", "order": 0 }, "paymentButton": { "enabled": true, "label": "Pay Now", "order": 0 }, "paymentMethods": { "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": { "ach": true, "check": true, "vcard": true }, "order": 0, "showPreviewVirtualCard": true }, "review": { "enabled": true, "header": "Review Payment", "order": 0 }, "settings": { "color": "#000000", "language": "en" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GeneratePaymentLink import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "contactUs": [ "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" ], "logo": [ "enabled": true, "order": 0 ], "messageBeforePaying": [ "enabled": true, "label": "Please review your payment details", "order": 0 ], "notes": [ "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" ], "page": [ "description": "Get paid securely", "enabled": true, "header": "Payment Page", "order": 0 ], "paymentButton": [ "enabled": true, "label": "Pay Now", "order": 0 ], "paymentMethods": [ "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": [ "ach": true, "check": true, "vcard": true ], "order": 0, "showPreviewVirtualCard": true ], "review": [ "enabled": true, "header": "Review Payment", "order": 0 ], "settings": [ "color": "#000000", "language": "en" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884?mail2=jo%40example.com%3B+ceo%40example.com")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript GeneratePaymentLinkNoSend import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.addPayLinkFromBill(23548884, { body: { contactUs: { emailLabel: "Email", enabled: true, header: "Contact Us", order: 0, paymentIcons: true, phoneLabel: "Phone", }, logo: { enabled: true, order: 0, }, messageBeforePaying: { enabled: true, label: "Please review your payment details", order: 0, }, notes: { enabled: true, header: "Additional Notes", order: 0, placeholder: "Enter any additional notes here", value: "", }, page: { description: "Get paid securely", enabled: true, header: "Payment Page", order: 0, }, paymentButton: { enabled: true, label: "Pay Now", order: 0, }, paymentMethods: { allMethodsChecked: true, allowMultipleMethods: true, defaultMethod: "vcard", enabled: true, header: "Payment Methods", methods: { ach: true, check: true, vcard: true, }, order: 0, showPreviewVirtualCard: true, }, review: { enabled: true, header: "Review Payment", order: 0, }, settings: { color: "#000000", language: "en", }, }, }); } main(); ``` ```python GeneratePaymentLinkNoSend from payabli import payabli, ContactElement, Element, LabelElement, NoteElement, PageElement, HeaderElement, PagelinkSetting from payabli.money_out_types import MethodElementOut, MethodsListOut client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.add_pay_link_from_bill( bill_id=23548884, contact_us=ContactElement( email_label="Email", enabled=True, header="Contact Us", order=0, payment_icons=True, phone_label="Phone", ), logo=Element( enabled=True, order=0, ), message_before_paying=LabelElement( enabled=True, label="Please review your payment details", order=0, ), notes=NoteElement( enabled=True, header="Additional Notes", order=0, placeholder="Enter any additional notes here", value="", ), page=PageElement( description="Get paid securely", enabled=True, header="Payment Page", order=0, ), payment_button=LabelElement( enabled=True, label="Pay Now", order=0, ), payment_methods=MethodElementOut( all_methods_checked=True, allow_multiple_methods=True, default_method="vcard", enabled=True, header="Payment Methods", methods=MethodsListOut( ach=True, check=True, vcard=True, ), order=0, show_preview_virtual_card=True, ), review=HeaderElement( enabled=True, header="Review Payment", order=0, ), settings=PagelinkSetting( color="#000000", language="en", ), ) ``` ```csharp GeneratePaymentLinkNoSend using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.AddPayLinkFromBillAsync( 23548884, new PayLinkDataBill { Body = new PaymentPageRequestBodyOut { ContactUs = new ContactElement { EmailLabel = "Email", Enabled = true, Header = "Contact Us", Order = 0, PaymentIcons = true, PhoneLabel = "Phone" }, Logo = new Element { Enabled = true, Order = 0 }, MessageBeforePaying = new LabelElement { Enabled = true, Label = "Please review your payment details", Order = 0 }, Notes = new NoteElement { Enabled = true, Header = "Additional Notes", Order = 0, Placeholder = "Enter any additional notes here", Value = "" }, Page = new PageElement { Description = "Get paid securely", Enabled = true, Header = "Payment Page", Order = 0 }, PaymentButton = new LabelElement { Enabled = true, Label = "Pay Now", Order = 0 }, PaymentMethods = new MethodElementOut { AllMethodsChecked = true, AllowMultipleMethods = true, DefaultMethod = "vcard", Enabled = true, Header = "Payment Methods", Methods = new MethodsListOut { Ach = true, Check = true, Vcard = true }, Order = 0, ShowPreviewVirtualCard = true }, Review = new HeaderElement { Enabled = true, Header = "Review Payment", Order = 0 }, Settings = new PagelinkSetting { Color = "#000000", Language = "en" } } } ); } } ``` ```go GeneratePaymentLinkNoSend package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884" payload := strings.NewReader("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GeneratePaymentLinkNoSend require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java GeneratePaymentLinkNoSend import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}") .asString(); ``` ```php GeneratePaymentLinkNoSend request('POST', 'https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884', [ 'body' => '{ "contactUs": { "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" }, "logo": { "enabled": true, "order": 0 }, "messageBeforePaying": { "enabled": true, "label": "Please review your payment details", "order": 0 }, "notes": { "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" }, "page": { "description": "Get paid securely", "enabled": true, "header": "Payment Page", "order": 0 }, "paymentButton": { "enabled": true, "label": "Pay Now", "order": 0 }, "paymentMethods": { "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": { "ach": true, "check": true, "vcard": true }, "order": 0, "showPreviewVirtualCard": true }, "review": { "enabled": true, "header": "Review Payment", "order": 0 }, "settings": { "color": "#000000", "language": "en" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GeneratePaymentLinkNoSend import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "contactUs": [ "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" ], "logo": [ "enabled": true, "order": 0 ], "messageBeforePaying": [ "enabled": true, "label": "Please review your payment details", "order": 0 ], "notes": [ "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" ], "page": [ "description": "Get paid securely", "enabled": true, "header": "Payment Page", "order": 0 ], "paymentButton": [ "enabled": true, "label": "Pay Now", "order": 0 ], "paymentMethods": [ "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": [ "ach": true, "check": true, "vcard": true ], "order": 0, "showPreviewVirtualCard": true ], "review": [ "enabled": true, "header": "Review Payment", "order": 0 ], "settings": [ "color": "#000000", "language": "en" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/bill/23548884")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get payment link GET https://api-sandbox.payabli.com/api/PaymentLink/load/{paylinkId} Retrieves a payment link by ID. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/get-payment-link-from-id ## SDK Code Examples ```typescript GetPaylink import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.getPayLinkFromId("paylinkId"); } main(); ``` ```python GetPaylink from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.get_pay_link_from_id( paylink_id="paylinkId", ) ``` ```csharp GetPaylink using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.GetPayLinkFromIdAsync( "paylinkId" ); } } ``` ```go GetPaylink package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/load/paylinkId" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetPaylink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/load/paylinkId") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetPaylink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/PaymentLink/load/paylinkId") .header("requestToken", "") .asString(); ``` ```php GetPaylink request('GET', 'https://api-sandbox.payabli.com/api/PaymentLink/load/paylinkId', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetPaylink import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/load/paylinkId")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Send payment link POST https://api-sandbox.payabli.com/api/PaymentLink/push/{payLinkId} Content-Type: application/json Send a payment link to the specified email addresses or phone numbers. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/send-payment-link ## SDK Code Examples ```typescript SendSMS import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.pushPayLinkFromId("payLinkId", { channel: "sms", }); } main(); ``` ```python SendSMS from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.push_pay_link_from_id( pay_link_id="payLinkId", request={ "channel": "sms" }, ) ``` ```csharp SendSMS using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.PushPayLinkFromIdAsync( "payLinkId", new PushPayLinkRequest( new PushPayLinkRequestSms() ) ); } } ``` ```go SendSMS package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId" payload := strings.NewReader("{\n \"channel\": \"sms\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby SendSMS require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"channel\": \"sms\"\n}" response = http.request(request) puts response.read_body ``` ```java SendSMS import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"channel\": \"sms\"\n}") .asString(); ``` ```php SendSMS request('POST', 'https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId', [ 'body' => '{ "channel": "sms" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift SendSMS import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["channel": "sms"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript SendEmail import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.pushPayLinkFromId("payLinkId", { channel: "email", additionalEmails: [ "admin@example.com", "accounting@example.com", ], attachFile: true, }); } main(); ``` ```python SendEmail from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.push_pay_link_from_id( pay_link_id="payLinkId", request={ "channel": "email", "additional_emails": [ "admin@example.com", "accounting@example.com" ], "attach_file": True }, ) ``` ```csharp SendEmail using PayabliPayabliApi; using System.Threading.Tasks; using System.Collections.Generic; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.PushPayLinkFromIdAsync( "payLinkId", new PushPayLinkRequest( new PushPayLinkRequestEmail { AdditionalEmails = new List(){ "admin@example.com", "accounting@example.com", } , AttachFile = true } ) ); } } ``` ```go SendEmail package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId" payload := strings.NewReader("{\n \"channel\": \"email\",\n \"additionalEmails\": [\n \"admin@example.com\",\n \"accounting@example.com\"\n ],\n \"attachFile\": true\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby SendEmail require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"channel\": \"email\",\n \"additionalEmails\": [\n \"admin@example.com\",\n \"accounting@example.com\"\n ],\n \"attachFile\": true\n}" response = http.request(request) puts response.read_body ``` ```java SendEmail import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"channel\": \"email\",\n \"additionalEmails\": [\n \"admin@example.com\",\n \"accounting@example.com\"\n ],\n \"attachFile\": true\n}") .asString(); ``` ```php SendEmail request('POST', 'https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId', [ 'body' => '{ "channel": "email", "additionalEmails": [ "admin@example.com", "accounting@example.com" ], "attachFile": true }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift SendEmail import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "channel": "email", "additionalEmails": ["admin@example.com", "accounting@example.com"], "attachFile": true ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/push/payLinkId")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update payment link PUT https://api-sandbox.payabli.com/api/PaymentLink/update/{payLinkId} Content-Type: application/json Updates a payment link's details. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/update-payment-link ## SDK Code Examples ```typescript UpdatePayLink import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.updatePayLinkFromId("332-c277b704-1301", { notes: { enabled: true, header: "Additional Notes", order: 0, placeholder: "Enter any additional notes here", value: "", }, paymentButton: { enabled: true, label: "Pay Now", order: 0, }, }); } main(); ``` ```python UpdatePayLink from payabli import payabli, NoteElement, LabelElement client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.update_pay_link_from_id( pay_link_id="332-c277b704-1301", notes=NoteElement( enabled=True, header="Additional Notes", order=0, placeholder="Enter any additional notes here", value="", ), payment_button=LabelElement( enabled=True, label="Pay Now", order=0, ), ) ``` ```csharp UpdatePayLink using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.UpdatePayLinkFromIdAsync( "332-c277b704-1301", new PayLinkUpdateData { Notes = new NoteElement { Enabled = true, Header = "Additional Notes", Order = 0, Placeholder = "Enter any additional notes here", Value = "" }, PaymentButton = new LabelElement { Enabled = true, Label = "Pay Now", Order = 0 } } ); } } ``` ```go UpdatePayLink package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/update/332-c277b704-1301" payload := strings.NewReader("{\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n }\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdatePayLink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/update/332-c277b704-1301") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdatePayLink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/PaymentLink/update/332-c277b704-1301") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n }\n}") .asString(); ``` ```php UpdatePayLink request('PUT', 'https://api-sandbox.payabli.com/api/PaymentLink/update/332-c277b704-1301', [ 'body' => '{ "notes": { "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" }, "paymentButton": { "enabled": true, "label": "Pay Now", "order": 0 } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdatePayLink import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "notes": [ "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" ], "paymentButton": [ "enabled": true, "label": "Pay Now", "order": 0 ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/update/332-c277b704-1301")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Refresh payment link GET https://api-sandbox.payabli.com/api/PaymentLink/refresh/{payLinkId} Refresh a payment link's content after an update. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/refresh-payment-link-content ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.refreshPayLinkFromId("payLinkId", {}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.refresh_pay_link_from_id( pay_link_id="payLinkId", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.RefreshPayLinkFromIdAsync( "payLinkId", new RefreshPayLinkFromIdRequest() ); } } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/refresh/payLinkId" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/refresh/payLinkId") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/PaymentLink/refresh/payLinkId") .header("requestToken", "") .asString(); ``` ```php request('GET', 'https://api-sandbox.payabli.com/api/PaymentLink/refresh/payLinkId', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/refresh/payLinkId")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete payment link DELETE https://api-sandbox.payabli.com/api/PaymentLink/{payLinkId} Deletes a payment link by ID. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/delete-payment-link ## SDK Code Examples ```typescript DeletePayLink import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.deletePayLinkFromId("2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234"); } main(); ``` ```python DeletePayLink from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.delete_pay_link_from_id( pay_link_id="2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", ) ``` ```csharp DeletePayLink using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.DeletePayLinkFromIdAsync( "2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" ); } } ``` ```go DeletePayLink package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby DeletePayLink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java DeletePayLink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/PaymentLink/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") .header("requestToken", "") .asString(); ``` ```php DeletePayLink request('DELETE', 'https://api-sandbox.payabli.com/api/PaymentLink/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift DeletePayLink import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Generate vendor link for lot number POST https://api-sandbox.payabli.com/api/PaymentLink/bill/lotNumber/{lotNumber} Content-Type: application/json Generates a vendor payment link for a specific bill lot number. This allows you to pay all bills with the same lot number for a vendor with a single payment link. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/generate-payment-link-for-lot-number ## SDK Code Examples ```typescript GeneratePaymentLinkFromLotNumber import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.addPayLinkFromBillLotNumber("LOT-2024-001", { entryPoint: "billing", vendorNumber: "VENDOR-123", mail2: "customer@example.com; billing@example.com", amountFixed: "true", body: { contactUs: { emailLabel: "Email", enabled: true, header: "Contact Us", order: 0, paymentIcons: true, phoneLabel: "Phone", }, logo: { enabled: true, order: 0, }, messageBeforePaying: { enabled: true, label: "Please review your payment details", order: 0, }, notes: { enabled: true, header: "Additional Notes", order: 0, placeholder: "Enter any additional notes here", value: "", }, page: { description: "Get paid securely", enabled: true, header: "Payment Page", order: 0, }, paymentButton: { enabled: true, label: "Pay Now", order: 0, }, paymentMethods: { allMethodsChecked: true, allowMultipleMethods: true, defaultMethod: "vcard", enabled: true, header: "Payment Methods", methods: { ach: true, check: true, vcard: true, }, order: 0, showPreviewVirtualCard: true, }, review: { enabled: true, header: "Review Payment", order: 0, }, settings: { color: "#000000", language: "en", }, }, }); } main(); ``` ```python GeneratePaymentLinkFromLotNumber from payabli import payabli, ContactElement, Element, LabelElement, NoteElement, PageElement, HeaderElement, PagelinkSetting from payabli.money_out_types import MethodElementOut, MethodsListOut client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.add_pay_link_from_bill_lot_number( lot_number="LOT-2024-001", entry_point="billing", vendor_number="VENDOR-123", mail_2="customer@example.com; billing@example.com", amount_fixed="true", contact_us=ContactElement( email_label="Email", enabled=True, header="Contact Us", order=0, payment_icons=True, phone_label="Phone", ), logo=Element( enabled=True, order=0, ), message_before_paying=LabelElement( enabled=True, label="Please review your payment details", order=0, ), notes=NoteElement( enabled=True, header="Additional Notes", order=0, placeholder="Enter any additional notes here", value="", ), page=PageElement( description="Get paid securely", enabled=True, header="Payment Page", order=0, ), payment_button=LabelElement( enabled=True, label="Pay Now", order=0, ), payment_methods=MethodElementOut( all_methods_checked=True, allow_multiple_methods=True, default_method="vcard", enabled=True, header="Payment Methods", methods=MethodsListOut( ach=True, check=True, vcard=True, ), order=0, show_preview_virtual_card=True, ), review=HeaderElement( enabled=True, header="Review Payment", order=0, ), settings=PagelinkSetting( color="#000000", language="en", ), ) ``` ```csharp GeneratePaymentLinkFromLotNumber using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.AddPayLinkFromBillLotNumberAsync( "LOT-2024-001", new PayLinkDataOut { EntryPoint = "billing", VendorNumber = "VENDOR-123", Mail2 = "customer@example.com; billing@example.com", AmountFixed = "true", Body = new PaymentPageRequestBodyOut { ContactUs = new ContactElement { EmailLabel = "Email", Enabled = true, Header = "Contact Us", Order = 0, PaymentIcons = true, PhoneLabel = "Phone" }, Logo = new Element { Enabled = true, Order = 0 }, MessageBeforePaying = new LabelElement { Enabled = true, Label = "Please review your payment details", Order = 0 }, Notes = new NoteElement { Enabled = true, Header = "Additional Notes", Order = 0, Placeholder = "Enter any additional notes here", Value = "" }, Page = new PageElement { Description = "Get paid securely", Enabled = true, Header = "Payment Page", Order = 0 }, PaymentButton = new LabelElement { Enabled = true, Label = "Pay Now", Order = 0 }, PaymentMethods = new MethodElementOut { AllMethodsChecked = true, AllowMultipleMethods = true, DefaultMethod = "vcard", Enabled = true, Header = "Payment Methods", Methods = new MethodsListOut { Ach = true, Check = true, Vcard = true }, Order = 0, ShowPreviewVirtualCard = true }, Review = new HeaderElement { Enabled = true, Header = "Review Payment", Order = 0 }, Settings = new PagelinkSetting { Color = "#000000", Language = "en" } } } ); } } ``` ```go GeneratePaymentLinkFromLotNumber package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/bill/lotNumber/LOT-2024-001?entryPoint=billing&vendorNumber=VENDOR-123&mail2=customer%40example.com%3B+billing%40example.com&amountFixed=true" payload := strings.NewReader("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GeneratePaymentLinkFromLotNumber require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/bill/lotNumber/LOT-2024-001?entryPoint=billing&vendorNumber=VENDOR-123&mail2=customer%40example.com%3B+billing%40example.com&amountFixed=true") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java GeneratePaymentLinkFromLotNumber import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/PaymentLink/bill/lotNumber/LOT-2024-001?entryPoint=billing&vendorNumber=VENDOR-123&mail2=customer%40example.com%3B+billing%40example.com&amountFixed=true") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}") .asString(); ``` ```php GeneratePaymentLinkFromLotNumber request('POST', 'https://api-sandbox.payabli.com/api/PaymentLink/bill/lotNumber/LOT-2024-001?entryPoint=billing&vendorNumber=VENDOR-123&mail2=customer%40example.com%3B+billing%40example.com&amountFixed=true', [ 'body' => '{ "contactUs": { "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" }, "logo": { "enabled": true, "order": 0 }, "messageBeforePaying": { "enabled": true, "label": "Please review your payment details", "order": 0 }, "notes": { "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" }, "page": { "description": "Get paid securely", "enabled": true, "header": "Payment Page", "order": 0 }, "paymentButton": { "enabled": true, "label": "Pay Now", "order": 0 }, "paymentMethods": { "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": { "ach": true, "check": true, "vcard": true }, "order": 0, "showPreviewVirtualCard": true }, "review": { "enabled": true, "header": "Review Payment", "order": 0 }, "settings": { "color": "#000000", "language": "en" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GeneratePaymentLinkFromLotNumber import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "contactUs": [ "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" ], "logo": [ "enabled": true, "order": 0 ], "messageBeforePaying": [ "enabled": true, "label": "Please review your payment details", "order": 0 ], "notes": [ "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" ], "page": [ "description": "Get paid securely", "enabled": true, "header": "Payment Page", "order": 0 ], "paymentButton": [ "enabled": true, "label": "Pay Now", "order": 0 ], "paymentMethods": [ "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": [ "ach": true, "check": true, "vcard": true ], "order": 0, "showPreviewVirtualCard": true ], "review": [ "enabled": true, "header": "Review Payment", "order": 0 ], "settings": [ "color": "#000000", "language": "en" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/bill/lotNumber/LOT-2024-001?entryPoint=billing&vendorNumber=VENDOR-123&mail2=customer%40example.com%3B+billing%40example.com&amountFixed=true")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update Pay Out payment link PATCH https://api-sandbox.payabli.com/api/PaymentLink/out/{paylinkId} Content-Type: application/json Partially updates a Pay Out payment link's content, expiration date, and/or status. Use this to modify the payment page configuration, extend or change the expiration, or cancel a link. Updating the expiration date of an expired link reactivates it to Active status. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/update-payout-payment-link ## SDK Code Examples ```typescript ReactivateExpiredLink import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.patchOutPaymentLink("2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", { expirationDate: "2026-06-01T00:00:00Z", status: "Active", }); } main(); ``` ```python ReactivateExpiredLink from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.patch_out_payment_link( paylink_id="2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", expiration_date="2026-06-01T00:00:00Z", status="Active", ) ``` ```csharp ReactivateExpiredLink using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.PatchOutPaymentLinkAsync( "2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", new PatchOutPaymentLinkRequest { ExpirationDate = "2026-06-01T00:00:00Z", Status = PaymentLinkStatus.Active } ); } } ``` ```go ReactivateExpiredLink package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload := strings.NewReader("{\n \"expirationDate\": \"2026-06-01T00:00:00Z\",\n \"status\": \"Active\"\n}") req, _ := http.NewRequest("PATCH", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ReactivateExpiredLink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"expirationDate\": \"2026-06-01T00:00:00Z\",\n \"status\": \"Active\"\n}" response = http.request(request) puts response.read_body ``` ```java ReactivateExpiredLink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"expirationDate\": \"2026-06-01T00:00:00Z\",\n \"status\": \"Active\"\n}") .asString(); ``` ```php ReactivateExpiredLink request('PATCH', 'https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234', [ 'body' => '{ "expirationDate": "2026-06-01T00:00:00Z", "status": "Active" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ReactivateExpiredLink import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "expirationDate": "2026-06-01T00:00:00Z", "status": "Active" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript CancelPaymentLink import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.patchOutPaymentLink("2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", { status: "Canceled", }); } main(); ``` ```python CancelPaymentLink from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.patch_out_payment_link( paylink_id="2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", status="Canceled", ) ``` ```csharp CancelPaymentLink using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.PatchOutPaymentLinkAsync( "2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", new PatchOutPaymentLinkRequest { Status = PaymentLinkStatus.Canceled } ); } } ``` ```go CancelPaymentLink package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload := strings.NewReader("{\n \"status\": \"Canceled\"\n}") req, _ := http.NewRequest("PATCH", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CancelPaymentLink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"status\": \"Canceled\"\n}" response = http.request(request) puts response.read_body ``` ```java CancelPaymentLink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"status\": \"Canceled\"\n}") .asString(); ``` ```php CancelPaymentLink request('PATCH', 'https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234', [ 'body' => '{ "status": "Canceled" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift CancelPaymentLink import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["status": "Canceled"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript UpdatePageContent import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.patchOutPaymentLink("2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", { billPageData: { page: { description: "You have a payment waiting", enabled: true, header: "Vendor Payment", order: 0, }, paymentButton: { enabled: true, label: "Select Payment Method", order: 0, }, paymentMethods: { allMethodsChecked: true, allowMultipleMethods: true, defaultMethod: "ach", enabled: true, header: "Payment Methods", methods: { ach: true, check: true, vcard: true, }, order: 0, showPreviewVirtualCard: false, }, }, }); } main(); ``` ```python UpdatePageContent from payabli import payabli, PageElement, LabelElement from payabli.payment_link import PaymentPageRequestBodyOut from payabli.money_out_types import MethodElementOut, MethodsListOut client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.patch_out_payment_link( paylink_id="2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", bill_page_data=PaymentPageRequestBodyOut( page=PageElement( description="You have a payment waiting", enabled=True, header="Vendor Payment", order=0, ), payment_button=LabelElement( enabled=True, label="Select Payment Method", order=0, ), payment_methods=MethodElementOut( all_methods_checked=True, allow_multiple_methods=True, default_method="ach", enabled=True, header="Payment Methods", methods=MethodsListOut( ach=True, check=True, vcard=True, ), order=0, show_preview_virtual_card=False, ), ), ) ``` ```csharp UpdatePageContent using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.PatchOutPaymentLinkAsync( "2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", new PatchOutPaymentLinkRequest { BillPageData = new PaymentPageRequestBodyOut { Page = new PageElement { Description = "You have a payment waiting", Enabled = true, Header = "Vendor Payment", Order = 0 }, PaymentButton = new LabelElement { Enabled = true, Label = "Select Payment Method", Order = 0 }, PaymentMethods = new MethodElementOut { AllMethodsChecked = true, AllowMultipleMethods = true, DefaultMethod = "ach", Enabled = true, Header = "Payment Methods", Methods = new MethodsListOut { Ach = true, Check = true, Vcard = true }, Order = 0, ShowPreviewVirtualCard = false } } } ); } } ``` ```go UpdatePageContent package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload := strings.NewReader("{\n \"billPageData\": {\n \"page\": {\n \"description\": \"You have a payment waiting\",\n \"enabled\": true,\n \"header\": \"Vendor Payment\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Select Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"ach\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": false\n }\n }\n}") req, _ := http.NewRequest("PATCH", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdatePageContent require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"billPageData\": {\n \"page\": {\n \"description\": \"You have a payment waiting\",\n \"enabled\": true,\n \"header\": \"Vendor Payment\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Select Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"ach\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": false\n }\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdatePageContent import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"billPageData\": {\n \"page\": {\n \"description\": \"You have a payment waiting\",\n \"enabled\": true,\n \"header\": \"Vendor Payment\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Select Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"ach\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": false\n }\n }\n}") .asString(); ``` ```php UpdatePageContent request('PATCH', 'https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234', [ 'body' => '{ "billPageData": { "page": { "description": "You have a payment waiting", "enabled": true, "header": "Vendor Payment", "order": 0 }, "paymentButton": { "enabled": true, "label": "Select Payment Method", "order": 0 }, "paymentMethods": { "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "ach", "enabled": true, "header": "Payment Methods", "methods": { "ach": true, "check": true, "vcard": true }, "order": 0, "showPreviewVirtualCard": false } } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdatePageContent import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["billPageData": [ "page": [ "description": "You have a payment waiting", "enabled": true, "header": "Vendor Payment", "order": 0 ], "paymentButton": [ "enabled": true, "label": "Select Payment Method", "order": 0 ], "paymentMethods": [ "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "ach", "enabled": true, "header": "Payment Methods", "methods": [ "ach": true, "check": true, "vcard": true ], "order": 0, "showPreviewVirtualCard": false ] ]] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update Pay Out payment link content PATCH https://api-sandbox.payabli.com/api/PaymentLink/updateOut/{paylinkId} Content-Type: application/json Updates the payment page content for a Pay Out payment link. Use this to change the branding, messaging, payment methods offered, or other page configuration. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/update-payout-payment-link-content ## SDK Code Examples ```typescript UpdatePayLinkOutFull import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.updatePayLinkOutFromId("2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", { contactUs: { emailLabel: "Email", enabled: true, header: "Contact Us", order: 0, paymentIcons: true, phoneLabel: "Phone", }, logo: { enabled: true, order: 0, }, messageBeforePaying: { enabled: true, label: "Please review your payment details", order: 0, }, notes: { enabled: true, header: "Additional Notes", order: 0, placeholder: "Enter any additional notes here", value: "", }, page: { description: "Get paid securely", enabled: true, header: "Payment Page", order: 0, }, paymentButton: { enabled: true, label: "Pay Now", order: 0, }, paymentMethods: { allMethodsChecked: true, allowMultipleMethods: true, defaultMethod: "vcard", enabled: true, header: "Payment Methods", methods: { ach: true, check: true, vcard: true, }, order: 0, showPreviewVirtualCard: true, }, review: { enabled: true, header: "Review Payment", order: 0, }, settings: { color: "#000000", language: "en", }, }); } main(); ``` ```python UpdatePayLinkOutFull from payabli import payabli, ContactElement, Element, LabelElement, NoteElement, PageElement, HeaderElement, PagelinkSetting from payabli.money_out_types import MethodElementOut, MethodsListOut client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.update_pay_link_out_from_id( paylink_id="2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", contact_us=ContactElement( email_label="Email", enabled=True, header="Contact Us", order=0, payment_icons=True, phone_label="Phone", ), logo=Element( enabled=True, order=0, ), message_before_paying=LabelElement( enabled=True, label="Please review your payment details", order=0, ), notes=NoteElement( enabled=True, header="Additional Notes", order=0, placeholder="Enter any additional notes here", value="", ), page=PageElement( description="Get paid securely", enabled=True, header="Payment Page", order=0, ), payment_button=LabelElement( enabled=True, label="Pay Now", order=0, ), payment_methods=MethodElementOut( all_methods_checked=True, allow_multiple_methods=True, default_method="vcard", enabled=True, header="Payment Methods", methods=MethodsListOut( ach=True, check=True, vcard=True, ), order=0, show_preview_virtual_card=True, ), review=HeaderElement( enabled=True, header="Review Payment", order=0, ), settings=PagelinkSetting( color="#000000", language="en", ), ) ``` ```csharp UpdatePayLinkOutFull using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.UpdatePayLinkOutFromIdAsync( "2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", new PaymentPageRequestBodyOut { ContactUs = new ContactElement { EmailLabel = "Email", Enabled = true, Header = "Contact Us", Order = 0, PaymentIcons = true, PhoneLabel = "Phone" }, Logo = new Element { Enabled = true, Order = 0 }, MessageBeforePaying = new LabelElement { Enabled = true, Label = "Please review your payment details", Order = 0 }, Notes = new NoteElement { Enabled = true, Header = "Additional Notes", Order = 0, Placeholder = "Enter any additional notes here", Value = "" }, Page = new PageElement { Description = "Get paid securely", Enabled = true, Header = "Payment Page", Order = 0 }, PaymentButton = new LabelElement { Enabled = true, Label = "Pay Now", Order = 0 }, PaymentMethods = new MethodElementOut { AllMethodsChecked = true, AllowMultipleMethods = true, DefaultMethod = "vcard", Enabled = true, Header = "Payment Methods", Methods = new MethodsListOut { Ach = true, Check = true, Vcard = true }, Order = 0, ShowPreviewVirtualCard = true }, Review = new HeaderElement { Enabled = true, Header = "Review Payment", Order = 0 }, Settings = new PagelinkSetting { Color = "#000000", Language = "en" } } ); } } ``` ```go UpdatePayLinkOutFull package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload := strings.NewReader("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}") req, _ := http.NewRequest("PATCH", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdatePayLinkOutFull require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdatePayLinkOutFull import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"contactUs\": {\n \"emailLabel\": \"Email\",\n \"enabled\": true,\n \"header\": \"Contact Us\",\n \"order\": 0,\n \"paymentIcons\": true,\n \"phoneLabel\": \"Phone\"\n },\n \"logo\": {\n \"enabled\": true,\n \"order\": 0\n },\n \"messageBeforePaying\": {\n \"enabled\": true,\n \"label\": \"Please review your payment details\",\n \"order\": 0\n },\n \"notes\": {\n \"enabled\": true,\n \"header\": \"Additional Notes\",\n \"order\": 0,\n \"placeholder\": \"Enter any additional notes here\",\n \"value\": \"\"\n },\n \"page\": {\n \"description\": \"Get paid securely\",\n \"enabled\": true,\n \"header\": \"Payment Page\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Pay Now\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n },\n \"review\": {\n \"enabled\": true,\n \"header\": \"Review Payment\",\n \"order\": 0\n },\n \"settings\": {\n \"color\": \"#000000\",\n \"language\": \"en\"\n }\n}") .asString(); ``` ```php UpdatePayLinkOutFull request('PATCH', 'https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234', [ 'body' => '{ "contactUs": { "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" }, "logo": { "enabled": true, "order": 0 }, "messageBeforePaying": { "enabled": true, "label": "Please review your payment details", "order": 0 }, "notes": { "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" }, "page": { "description": "Get paid securely", "enabled": true, "header": "Payment Page", "order": 0 }, "paymentButton": { "enabled": true, "label": "Pay Now", "order": 0 }, "paymentMethods": { "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": { "ach": true, "check": true, "vcard": true }, "order": 0, "showPreviewVirtualCard": true }, "review": { "enabled": true, "header": "Review Payment", "order": 0 }, "settings": { "color": "#000000", "language": "en" } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdatePayLinkOutFull import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "contactUs": [ "emailLabel": "Email", "enabled": true, "header": "Contact Us", "order": 0, "paymentIcons": true, "phoneLabel": "Phone" ], "logo": [ "enabled": true, "order": 0 ], "messageBeforePaying": [ "enabled": true, "label": "Please review your payment details", "order": 0 ], "notes": [ "enabled": true, "header": "Additional Notes", "order": 0, "placeholder": "Enter any additional notes here", "value": "" ], "page": [ "description": "Get paid securely", "enabled": true, "header": "Payment Page", "order": 0 ], "paymentButton": [ "enabled": true, "label": "Pay Now", "order": 0 ], "paymentMethods": [ "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": [ "ach": true, "check": true, "vcard": true ], "order": 0, "showPreviewVirtualCard": true ], "review": [ "enabled": true, "header": "Review Payment", "order": 0 ], "settings": [ "color": "#000000", "language": "en" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```typescript ChangeOfferedMethods import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.paymentLink.updatePayLinkOutFromId("2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", { paymentButton: { enabled: true, label: "Choose Payment Method", order: 0, }, paymentMethods: { allMethodsChecked: false, allowMultipleMethods: true, defaultMethod: "vcard", enabled: true, header: "Payment Methods", methods: { ach: true, check: false, vcard: true, }, order: 0, showPreviewVirtualCard: true, }, }); } main(); ``` ```python ChangeOfferedMethods from payabli import payabli, LabelElement from payabli.money_out_types import MethodElementOut, MethodsListOut client = payabli( api_key="YOUR_API_KEY_HERE", ) client.payment_link.update_pay_link_out_from_id( paylink_id="2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", payment_button=LabelElement( enabled=True, label="Choose Payment Method", order=0, ), payment_methods=MethodElementOut( all_methods_checked=False, allow_multiple_methods=True, default_method="vcard", enabled=True, header="Payment Methods", methods=MethodsListOut( ach=True, check=False, vcard=True, ), order=0, show_preview_virtual_card=True, ), ) ``` ```csharp ChangeOfferedMethods using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.PaymentLink.UpdatePayLinkOutFromIdAsync( "2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234", new PaymentPageRequestBodyOut { PaymentButton = new LabelElement { Enabled = true, Label = "Choose Payment Method", Order = 0 }, PaymentMethods = new MethodElementOut { AllMethodsChecked = false, AllowMultipleMethods = true, DefaultMethod = "vcard", Enabled = true, Header = "Payment Methods", Methods = new MethodsListOut { Ach = true, Check = false, Vcard = true }, Order = 0, ShowPreviewVirtualCard = true } } ); } } ``` ```go ChangeOfferedMethods package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload := strings.NewReader("{\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Choose Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": false,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": false,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n }\n}") req, _ := http.NewRequest("PATCH", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ChangeOfferedMethods require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Choose Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": false,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": false,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n }\n}" response = http.request(request) puts response.read_body ``` ```java ChangeOfferedMethods import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Choose Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": false,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"vcard\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": false,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": true\n }\n}") .asString(); ``` ```php ChangeOfferedMethods request('PATCH', 'https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234', [ 'body' => '{ "paymentButton": { "enabled": true, "label": "Choose Payment Method", "order": 0 }, "paymentMethods": { "allMethodsChecked": false, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": { "ach": true, "check": false, "vcard": true }, "order": 0, "showPreviewVirtualCard": true } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ChangeOfferedMethods import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "paymentButton": [ "enabled": true, "label": "Choose Payment Method", "order": 0 ], "paymentMethods": [ "allMethodsChecked": false, "allowMultipleMethods": true, "defaultMethod": "vcard", "enabled": true, "header": "Payment Methods", "methods": [ "ach": true, "check": false, "vcard": true ], "order": 0, "showPreviewVirtualCard": true ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/updateOut/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Create item POST https://api-sandbox.payabli.com/api/LineItem/{entry} Content-Type: application/json Adds products and services to an entrypoint's catalog. These are used as line items for invoicing and transactions. In the response, "responseData" displays the item's code. Reference: https://docs.payabli.com/developers/api-reference/lineitem/add-item-to-entrypoint-catalog ## SDK Code Examples ```typescript AddItem import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.lineItem.addItem("47cae3d74", { body: { itemCost: 12.45, itemQty: 1, itemCommodityCode: "010", itemDescription: "Deposit for materials", itemMode: 0, itemProductCode: "M-DEPOSIT", itemProductName: "Materials deposit", itemUnitOfMeasure: "SqFt", }, }); } main(); ``` ```python AddItem from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.line_item.add_item( entry="47cae3d74", item_cost=12.45, item_qty=1, item_commodity_code="010", item_description="Deposit for materials", item_mode=0, item_product_code="M-DEPOSIT", item_product_name="Materials deposit", item_unit_of_measure="SqFt", ) ``` ```csharp AddItem using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.LineItem.AddItemAsync( "47cae3d74", new AddItemRequest { Body = new LineItem { ItemCost = 12.45, ItemQty = 1, ItemCommodityCode = "010", ItemDescription = "Deposit for materials", ItemMode = 0, ItemProductCode = "M-DEPOSIT", ItemProductName = "Materials deposit", ItemUnitOfMeasure = "SqFt" } } ); } } ``` ```go AddItem package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/LineItem/47cae3d74" payload := strings.NewReader("{\n \"itemCost\": 12.45,\n \"itemQty\": 1,\n \"itemCommodityCode\": \"010\",\n \"itemDescription\": \"Deposit for materials\",\n \"itemMode\": 0,\n \"itemProductCode\": \"M-DEPOSIT\",\n \"itemProductName\": \"Materials deposit\",\n \"itemUnitOfMeasure\": \"SqFt\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby AddItem require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/LineItem/47cae3d74") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"itemCost\": 12.45,\n \"itemQty\": 1,\n \"itemCommodityCode\": \"010\",\n \"itemDescription\": \"Deposit for materials\",\n \"itemMode\": 0,\n \"itemProductCode\": \"M-DEPOSIT\",\n \"itemProductName\": \"Materials deposit\",\n \"itemUnitOfMeasure\": \"SqFt\"\n}" response = http.request(request) puts response.read_body ``` ```java AddItem import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/LineItem/47cae3d74") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"itemCost\": 12.45,\n \"itemQty\": 1,\n \"itemCommodityCode\": \"010\",\n \"itemDescription\": \"Deposit for materials\",\n \"itemMode\": 0,\n \"itemProductCode\": \"M-DEPOSIT\",\n \"itemProductName\": \"Materials deposit\",\n \"itemUnitOfMeasure\": \"SqFt\"\n}") .asString(); ``` ```php AddItem request('POST', 'https://api-sandbox.payabli.com/api/LineItem/47cae3d74', [ 'body' => '{ "itemCost": 12.45, "itemQty": 1, "itemCommodityCode": "010", "itemDescription": "Deposit for materials", "itemMode": 0, "itemProductCode": "M-DEPOSIT", "itemProductName": "Materials deposit", "itemUnitOfMeasure": "SqFt" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift AddItem import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "itemCost": 12.45, "itemQty": 1, "itemCommodityCode": "010", "itemDescription": "Deposit for materials", "itemMode": 0, "itemProductCode": "M-DEPOSIT", "itemProductName": "Materials deposit", "itemUnitOfMeasure": "SqFt" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/LineItem/47cae3d74")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Get item GET https://api-sandbox.payabli.com/api/LineItem/{lineItemId} Gets an item by ID. Reference: https://docs.payabli.com/developers/api-reference/lineitem/get-item-in-entrypoint ## SDK Code Examples ```typescript GetItem import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.lineItem.getItem(700); } main(); ``` ```python GetItem from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.line_item.get_item( line_item_id=700, ) ``` ```csharp GetItem using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.LineItem.GetItemAsync( 700 ); } } ``` ```go GetItem package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/LineItem/700" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby GetItem require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/LineItem/700") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java GetItem import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/LineItem/700") .header("requestToken", "") .asString(); ``` ```php GetItem request('GET', 'https://api-sandbox.payabli.com/api/LineItem/700', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift GetItem import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/LineItem/700")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # List items GET https://api-sandbox.payabli.com/api/Query/lineitems/{entry} Retrieves a list of line items and their details from an entrypoint. Line items are also known as items, products, and services. Use filters to limit results. Reference: https://docs.payabli.com/developers/api-reference/lineitem/get-list-of-items-for-entrypoint ## SDK Code Examples ```typescript ListItems import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.lineItem.listLineItems("8cfec329267", { fromRecord: 251, limitRecord: 0, sortBy: "desc(field_name)", }); } main(); ``` ```python ListItems from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.line_item.list_line_items( entry="8cfec329267", from_record=251, limit_record=0, sort_by="desc(field_name)", ) ``` ```csharp ListItems using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.LineItem.ListLineItemsAsync( "8cfec329267", new ListLineItemsRequest { FromRecord = 251, LimitRecord = 0, SortBy = "desc(field_name)" } ); } } ``` ```go ListItems package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Query/lineitems/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ListItems require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Query/lineitems/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java ListItems import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api-sandbox.payabli.com/api/Query/lineitems/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29") .header("requestToken", "") .asString(); ``` ```php ListItems request('GET', 'https://api-sandbox.payabli.com/api/Query/lineitems/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift ListItems import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/lineitems/8cfec329267?fromRecord=251&limitRecord=0&sortBy=desc%28field_name%29")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Update item PUT https://api-sandbox.payabli.com/api/LineItem/{lineItemId} Content-Type: application/json Updates an item. Reference: https://docs.payabli.com/developers/api-reference/lineitem/update-item-in-entrypoint ## SDK Code Examples ```typescript UpdateItem import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.lineItem.updateItem(700, { itemCost: 12.45, itemQty: 1, }); } main(); ``` ```python UpdateItem from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.line_item.update_item( line_item_id=700, item_cost=12.45, item_qty=1, ) ``` ```csharp UpdateItem using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.LineItem.UpdateItemAsync( 700, new LineItem { ItemCost = 12.45, ItemQty = 1 } ); } } ``` ```go UpdateItem package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/LineItem/700" payload := strings.NewReader("{\n \"itemCost\": 12.45,\n \"itemQty\": 1\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdateItem require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/LineItem/700") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"itemCost\": 12.45,\n \"itemQty\": 1\n}" response = http.request(request) puts response.read_body ``` ```java UpdateItem import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://api-sandbox.payabli.com/api/LineItem/700") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"itemCost\": 12.45,\n \"itemQty\": 1\n}") .asString(); ``` ```php UpdateItem request('PUT', 'https://api-sandbox.payabli.com/api/LineItem/700', [ 'body' => '{ "itemCost": 12.45, "itemQty": 1 }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift UpdateItem import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "itemCost": 12.45, "itemQty": 1 ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/LineItem/700")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Delete line item DELETE https://api-sandbox.payabli.com/api/LineItem/{lineItemId} Deletes an item. Reference: https://docs.payabli.com/developers/api-reference/lineitem/delete-item-in-entrypoint ## SDK Code Examples ```typescript DeleteItem import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.lineItem.deleteItem(700); } main(); ``` ```python DeleteItem from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.line_item.delete_item( line_item_id=700, ) ``` ```csharp DeleteItem using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.LineItem.DeleteItemAsync( 700 ); } } ``` ```go DeleteItem package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/LineItem/700" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("requestToken", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby DeleteItem require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/LineItem/700") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java DeleteItem import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/LineItem/700") .header("requestToken", "") .asString(); ``` ```php DeleteItem request('DELETE', 'https://api-sandbox.payabli.com/api/LineItem/700', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift DeleteItem import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/LineItem/700")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # OCR PDF or image POST https://api-sandbox.payabli.com/api/Import/ocrDocumentForm/{typeResult} Content-Type: application/json Use this endpoint to upload an image file for OCR processing. The accepted file formats include PDF, JPG, JPEG, PNG, and GIF. Specify the desired type of result (either 'bill' or 'invoice') in the path parameter `typeResult`. The response will contain the OCR processing results, including extracted data such as bill number, vendor information, bill items, and more. Reference: https://docs.payabli.com/developers/api-reference/import/ocr-a-file ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.ocr.ocrDocumentForm("typeResult", {}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.ocr.ocr_document_form( type_result="typeResult", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Ocr.OcrDocumentFormAsync( "typeResult", new FileContentImageOnly() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Import/ocrDocumentForm/typeResult" payload := strings.NewReader("{}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Import/ocrDocumentForm/typeResult") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Import/ocrDocumentForm/typeResult") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/Import/ocrDocumentForm/typeResult', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Import/ocrDocumentForm/typeResult")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # OCR a base64-encoded string POST https://api-sandbox.payabli.com/api/Import/ocrDocumentJson/{typeResult} Content-Type: application/json Use this endpoint to submit a Base64-encoded image file for OCR processing. The accepted file formats include PDF, JPG, JPEG, PNG, and GIF. Specify the desired type of result (either 'bill' or 'invoice') in the path parameter `typeResult`. The response will contain the OCR processing results, including extracted data such as bill number, vendor information, bill items, and more. Reference: https://docs.payabli.com/developers/api-reference/import/ocr-a-base64-encoded-string ## SDK Code Examples ```typescript import { PayabliClient } from "@payabli/sdk-node"; async function main() { const client = new PayabliClient({ apiKey: "YOUR_API_KEY_HERE", }); await client.ocr.ocrDocumentJson("typeResult", {}); } main(); ``` ```python from payabli import payabli client = payabli( api_key="YOUR_API_KEY_HERE", ) client.ocr.ocr_document_json( type_result="typeResult", ) ``` ```csharp using PayabliPayabliApi; using System.Threading.Tasks; namespace Usage; public class Example { public async Task Do() { var client = new PayabliPayabliApiClient( apiKey: "YOUR_API_KEY_HERE" ); await client.Ocr.OcrDocumentJsonAsync( "typeResult", new FileContentImageOnly() ); } } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/Import/ocrDocumentJson/typeResult" payload := strings.NewReader("{}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Import/ocrDocumentJson/typeResult") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/Import/ocrDocumentJson/typeResult") .header("requestToken", "") .header("Content-Type", "application/json") .body("{}") .asString(); ``` ```php request('POST', 'https://api-sandbox.payabli.com/api/Import/ocrDocumentJson/typeResult', [ 'body' => '{}', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Import/ocrDocumentJson/typeResult")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` # Transaction Canceled POST Triggered when a Pay Out transaction (a payout) is voided or canceled. Notification name: `payout_transaction_voidedcancelled` Legacy notification name: `PayOutCanceled` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-voided-canceled # Transaction Processing POST Triggered when a pay out transaction enters processing status. Notification name: `payout_transaction_processing` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-processing # Transaction Processed POST Triggered when a pay out transaction is processed. Notification name: `payout_transaction_processed` Legacy notification name: `PayOutProcessed` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-processed # Transaction On Hold POST Triggered when a pay out transaction is placed on hold. Notification name: `payout_transaction_onhold` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-onhold # Transaction Released POST Triggered when a pay out transaction is released from hold. Notification name: `payout_transaction_released` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-released # Transaction Recovered POST Triggered when a pay out transaction is recovered. Notification name: `payout_transaction_recovered` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-recovered # Transaction Initiated POST Triggered when a pay out transaction is initiated. Notification name: `payout_transaction_initiated` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-initiated # Transaction Authorized POST Triggered when a pay out transaction is authorized. Notification name: `payout_transaction_authorized` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-authorized # Transaction Approved/Captured POST Triggered when a pay out transaction is approved and captured. Notification name: `payout_transaction_approvedcaptured` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-approved-captured # Transaction Declined POST Triggered when a pay out transaction is declined. Notification name: `payout_transaction_declined` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-declined # Transaction Technical Decline POST Triggered when a pay out transaction is declined due to technical reasons. Notification name: `payout_transaction_technicaldecline` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-technical-decline # Transaction Failed POST Triggered when a pay out transaction fails. Notification name: `payout_transaction_failed` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-failed # Transaction Error POST Triggered when a pay out transaction encounters an error. Notification name: `payout_transaction_error` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-error # Transaction Paid POST Triggered when a pay out transaction is paid. Notification name: `payout_transaction_paid` Legacy notification name: `PayOutPaid` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-paid # Transaction Returned POST Triggered when a pay out transaction is returned. Notification name: `payout_transaction_returned` Legacy notification name: `PayOutReturned` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-returned # Transaction Rejected POST Triggered when a pay out transaction is rejected. Notification name: `payout_transaction_rejected` Reference: https://docs.payabli.com/developers/webhooks/payout-transaction-rejected # Settlement Pending POST Triggered when a pay out batch settlement is pending. Notification name: `payout_batch_settlement_pending` Reference: https://docs.payabli.com/developers/webhooks/payout-settlement-pending # Settlement In Transit POST Triggered when a pay out batch settlement is in transit. Notification name: `payout_batch_settlement_intransit` Reference: https://docs.payabli.com/developers/webhooks/payout-settlement-intransit # Settlement Transferred POST Triggered when a pay out batch settlement is transferred. Notification name: `payout_batch_settlement_transferred` Reference: https://docs.payabli.com/developers/webhooks/payout-settlement-transferred # Settlement Funded POST Triggered when a pay out batch settlement is funded. Notification name: `payout_batch_settlement_funded` Reference: https://docs.payabli.com/developers/webhooks/payout-settlement-funded # Settlement Resolved POST Triggered when a pay out batch settlement is resolved. Notification name: `payout_batch_settlement_resolved` Reference: https://docs.payabli.com/developers/webhooks/payout-settlement-resolved # Settlement Exception POST Triggered when a pay out batch settlement encounters an exception. Notification name: `payout_batch_settlement_exception` Reference: https://docs.payabli.com/developers/webhooks/payout-settlement-exception # Settlement ACH Return/Chargeback POST Triggered when a pay out batch settlement has an ACH return or chargeback. Notification name: `payout_batch_settlement_achreturnchargeback` Reference: https://docs.payabli.com/developers/webhooks/payout-settlement-ach-return-chargeback # Settlement Held POST Triggered when a pay out batch settlement is held. Notification name: `payout_batch_settlement_held` Reference: https://docs.payabli.com/developers/webhooks/payout-settlement-held # Settlement Released POST Triggered when a pay out batch settlement is released from hold. Notification name: `payout_batch_settlement_released` Reference: https://docs.payabli.com/developers/webhooks/payout-settlement-released # Batch Funded POST Triggered when a pay out batch is funded (replaces payoutbatchfunded). - Notification name: `payout_batch_funded` - Legacy notification name: `payoutbatchfunded` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-funded # Batch Processed POST Triggered when a pay out batch is processed (replaces payoutbatchprocessed). - Notification name: `payout_batch_processed` - Legacy notification name: `payoutbatchprocessed` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-processed # Batch Paid POST Triggered when a pay out batch is paid (replaces payoutbatchpaid). - Notification name: `payout_batch_paid` - Legacy notification name: `payoutbatchpaid` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-paid # Batch Fund Pending POST Triggered when a pay out batch has funding pending (replaces payoutbatchfundingpending). - Notification name: `payout_batch_fundpending` - Legacy notification name: `payoutbatchfundingpending` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-fund-pending # Batch Open POST Triggered when a pay out batch is opened. Notification name: `payout_batch_open` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-open # Batch Closed POST Triggered when a pay out batch is closed. - Notification name: `payout_batch_closed` - Legacy notification name: `payoutbatchclosed` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-closed # Batch Not Closed POST Triggered when a pay out batch is not closed. Notification name: `payout_batch_notclosed` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-not-closed # Batch Canceled POST Triggered when a pay out batch is cancelled (replaces payoutbatchcancelled). - Notification name: `payout_batch_cancelled` - Legacy notification name: `payoutbatchcancelled` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-canceled # Batch Transferred POST Triggered when a pay out batch is transferred. Notification name: `payout_batch_transferred` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-transferred # Batch Resolved POST Triggered when a pay out batch is resolved. Notification name: `payout_batch_resolved` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-resolved # Batch On Hold POST Triggered when a pay out batch is placed on hold. Notification name: `payout_batch_onhold` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-on-hold # Batch Released POST Triggered when a pay out batch is released from hold. Notification name: `payout_batch_released` Reference: https://docs.payabli.com/developers/webhooks/payout-batch-released *** title: Embedded components overview subtitle: >- Learn how to use Payabli's embedded components to create customized checkout experiences without handling sensitive payment information yourself description: >- Integrate embedded components to build customized checkout flows without handling sensitive payment data. Explore component types, styling, and configurations 'og:description': >- Integrate embedded components to build customized checkout flows without handling sensitive payment data. Explore component types, styling, and configurations keywords: >- embedded payments, embedded components, payment UI, checkout experience, PCI compliance, payment integration, drop-in payments icon: puzzle slug: guides/pay-in-components-overview area: * Pay In subArea: * Components audience: * developers *** Payabli offers a set of embedded JavaScript UI components that let you create customized checkout experiences without handling sensitive payment information. You can use the embedded components to process transactions or save payment methods while remaining PCI compliant. Payment methods saved via the embedded components can be used with the Payabli API to perform functions like subscriptions, queries, and more. See [Tokenization Overview](/guides/platform-tokenization-overview) for more information. ## Choose a component Use the interactive quiz below to find the right embedded component for your application. ### Component chooser quiz The component chooser helps you pick the right Payabli embedded component. It asks up to three questions: 1. **What do you need to do?** Process payments, save payment methods, or both. 2. **Which payment methods do you want to accept?** Credit cards, debit cards, and ACH; digital wallets; RDC (check capture); or all payment methods. 3. **How do you want to display the component?** Embedded in the page, in a modal window, or in a terminal. This question is only asked if you chose traditional payment methods. Based on your answers, it recommends one of these components: * **EmbeddedMethod UI** — The most flexible option. Processes payments and saves payment methods. Supports cards and ACH. Recommended for most use cases. * **ExpressCheckout UI** — Supports Apple Pay and Google Pay. Best for digital wallet payments. * **VirtualTerminal UI** — Full terminal interface. Best for processing payments on behalf of customers. * **PayMethod UI** — Displays in a modal window. Saves payment methods only and doesn't process payments. * **ExpressCheckout UI + EmbeddedMethod UI** — A combined setup that supports digital wallets, cards, ACH, and tokenization. To decide which embedded component to use, consider the functionality you need for your app. Payabli offers embedded components tailored to different use cases: * [EmbeddedMethod UI](/guides/pay-in-components-embeddedmethod-ui) — Capture a payment method or make a sale using any payment method. This is the most flexible component. It's ideal for tokenizing payment methods or making sales directly from your page. * [ExpressCheckout UI](/guides/pay-in-components-express-checkout) — Add acceptance for digital wallet payments like Apple Pay. It can be paired with other components to give your customer a range of options. * [VirtualTerminal UI](/guides/pay-in-components-virtual-terminal-ui) — Embed a virtual terminal tool in your page or app, letting you add secure payment acceptance in a contained environment. * [PayMethod UI](/guides/pay-in-components-paymethod-ui) — Save payment method data without expanding your PCI scope. This component is a modal that opens over content, and is designed only for storing payment methods. Which component is right for you depends on whether you need to make transactions, save payment method data, or both. For example, if you need to both save a payment method and execute payments, the EmbeddedMethod UI might be the best choice. If you just need to make transactions from your website or app, the VirtualTerminal UI could be the right choice. Overall, the EmbeddedMethod UI is the most popular and flexible option. You can extend the EmbeddedMethod UI and PayMethod UI components even further by using a flow designed around returning a temporary payment token. See [Extend Embedded Components with the Temporary Token Flow](/guides/platform-developer-tokenization-temp-flow) for more. ## Generate LLM integration prompt Click the button below to open a prompt configuration form. The form generates a custom LLM prompt designed to guide an LLM in helping you integrate Payabli's embedded components. For best results, copy the prompt into an IDE or code editor that has the Payabli MCP server enabled. For more information on the Payabli MCP server, see [Use the Payabli MCP server](/developers/platform-developer-mcp). LLMs are non-deterministic, meaning that the same prompt can produce different outputs each time it's run. Payabli can't guarantee that generated prompts always produce the same results or function perfectly on the first try. Always review output before using it in production. ### Embedded component prompt generator The prompt generator is a configuration form that creates a custom LLM prompt to help you integrate Payabli's embedded components. You can configure the environment (sandbox or production), UI style (embedded or modal), theme, color mode, accent color, and framework (vanilla JS, React, or Vue). You can also choose a use case (payment or tokenization) and enable specific payment methods including card, ACH, RDC, Apple Pay, and Google Pay. Copy the generated prompt into an IDE with the Payabli MCP server enabled for best results. ## Usage Payabli's embedded components are customizable and easy to implement. To load Payabli's embedded components, add a script tag that points to Payabli's `component.js` library. After adding the script tag, create an instance of the `PayabliComponent` class with your configuration. See the [Configuration reference](/guides/pay-in-components-embeddedmethod-ui#configuration-reference) for each component for more information about configuration options. ```javascript Sandbox ``` ```javascript Production ``` ### Library URLs See the [component.js Changelog](/changelog/embedded-components) to see the latest changes. Beginning October 22, 2023 embedded components no longer supports versions older than 1.9.0. The sandbox and production library URLs are evergreen, meaning that the URL always points to the latest version. * Sandbox: `https://embedded-component-sandbox.payabli.com/component.js` * Production: `https://embedded-component.payabli.com/component.js` You must add the `data-test` configuration variable to your script tag when using the sandbox library. Don't include `data-test` when working with the production library. ### Authentication Payabli's embedded components authenticate with the `token` field passed in the embedded component's configuration. The API token must be a public token. If you are using a Creator component, the API token must be set up for the Creator. See [Payabli API tokens](/developers/api-reference/api-overview#authentication) for more information. ### `PayabliComponent` class The `PayabliComponent` class has the following methods: Show the component if it's hidden. Hide the component. Replace the component configuration. Trigger an action. Valid actions are `method`, `pay`, `auth` and `reinit`. `parameters` is an optional structure that lets you dynamically overwrite the matching fields passed via configuration for `customerData` and `paymentDetail`. This action executes a tokenization of the payment information (saves the payment method). This action doesn't process a payment. This is the default action. This action processes a payment. This action processes an authorization that needs to be captured later. This action doesn't process a payment. This action resets the component state. We recommend using this method when the component is in an error or declined state and you want to retry a transaction. ```javascript payabliExec example var dynamicData= { customerData: { firstName: 'John', lastName: 'Doe' }, paymentDetails: { totalAmount: 11.55 } }; // This action executes a payment using the customerData and paymentDetails objects // declared in the dynamicData variable mycomponent.payabliExec('pay', dynamicData); ``` ## Customize styles To customize the component's styles, you can pass a URL to a CSS file in the `customCssUrl` parameter of the component configuration. ```js customCssUrl example const payabliConfig0 = { type: "methodLightbox", rootContainer: "pay-component-1", buttonLabelInModal: 'Save Payment Method', defaultOpen: 'ach', hideComponent: true, customCssUrl: 'www.example.com/mycssfile.css', ... } ``` ### Make the component background transparent By default, the embedded components have a white background. To make the component's background transparent, add the following CSS to the stylesheet that's linked with the `customCssUrl` parameter: ```css /* ... the rest of your custom css ... */ /* transparent while loading */ #main-loading-layer { background-color: transparent !important; } /* transparent after loading */ body { background-color: transparent !important; } ``` ### Component containers The embedded components are loaded inside of an iframe. Each component creates a container for the iframe with a specific ID. You can use these IDs to target the component container in your CSS or JavaScript code. Here are the IDs for each component: * EmbeddedMethod: `payabliComponentsIframeContainerMethodEmbedded` * PayMethod: `payabliComponentsIframeContainerMethod ` * VirtualTerminal: `payabliComponentsIframeContainerEterminal` * ExpressCheckout: `payabliComponentsIframeContainerExpressCheckout` ### Component elements You can also reference specific elements inside of the component and create custom styles for them. The elements inside the component have the following IDs:
ID Element
`cardNumber` Card number input
`cardNumberContainer` Card number container
`cardExpirationDate` Card expiration date input
`cardExpirationDateContainer` Card expiration date container
`cardCvv` Card CVV input
`cardCvvContainer` Card CVV container
`cardZipcode` Card zip code input
`cardZipcodeContainer` Card zip code container
`cardHolderName` Cardholder name input
`cardHolderNameContainer` Cardholder name container
`achAccountType` Bank account type selector
`achAccountTypeContainer` Bank account type container
`achAccountHolderName` Bank account holder input
`achAccountHolderNameContainer` Bank account holder container
`achRouting` Bank routing input
`achRoutingContainer` Bank routing container
`achAccount` Bank account input
`achAccountContainer` Bank account container
This example targets the card number, expiration date, CVV, ZIP code, and cardholder name fields. It adds a solid, 1 pixel black border to the fields. ```css Form style example #cardNumber, #cardExpirationDate, #cardCvv, #cardZipcode, #cardHolderName { border: solid 1px #000000; } ``` ## Customize input fields The input fields inside of the component can be styled individually via the component's configuration object. ### Input grid layout The component's inputs are laid out in a grid with 3 rows and 12 columns. You can specify size and placement of each input in the grid without any CSS by using the `row`, `order`, and `size` fields.
Row 0 Size=1 Size=1 Size=1 Size=1 Size=1 Size=1 Size=1 Size=1 Size=1 Size=1 Size=1 Size=1
Row 1 Size=2 Size=3 Size=5 Size=1 Size=1
Row 2 Size=8 Size=4
### Input configuration reference You can style inputs in the component configuration using the following parameters: Label for input field. Placeholder for input field. Enable/disable floating label within input field. Value for input field. Size of input field in columns (1-12). Row to place the input within component grid (0-2), 0 being the top row. Order of input field within the row (0-99+), 0 being the left position. For `achRouting` and `achAccount` inputs only. When `true`, duplicates the ACH account number and routing number fields and requires that the fields match. This helps make sure the user enters valid account and routing numbers. Only available for the EmbeddedMethod UI. For `cardZipcode` input only. Accepted values are `us` and `ca`. Controls which zip code formats are accepted. If `ca` is included, then Canadian payments are enabled. ### Input configuration examples Here are some examples of different input configurations: ```js Card field configuration example card: { enabled: true, amex: true, discover: true, visa: true, mastercard: true, jcb: true, diners: true, inputs: { cardNumber: { size: 4, row: 1, order: 0, label: "Your Card Number" }, cardExpirationDate: { size: 4, row: 1, order: 1, }, cardZipcode: { label: "ZIP/POSTAL CODE", placeholder: "Zip/Postal Code", floating: false, size: 6, row: 2, order: 1, country: ["us", "ca"] } } }, ``` ```js ACH field configuration example ach: { enabled: true, checking: true, savings: true, inputs: { achRouting: { label: "Routing Number", size: 6, row: 1, order: 0, confirm: false // Display the field twice to ensure the fields match }, achAccount: { label: "Account Number", size: 6, row: 2, order: 0, confirm: true } } } ``` ## Interactive demos The following demos show the EmbeddedMethod UI component with different configurations. ### Card This is a basic example of the EmbeddedMethod UI component with default card configuration. This demo shows the component in action with transaction processing and visual feedback. When the component processes a transaction, the demo displays the JSON response. ### ACH This is a basic example of the EmbeddedMethod UI component with default ACH configuration. This demo shows the component in action with transaction processing and visual feedback. When the component processes a transaction, the demo displays the JSON response. ### RDC This is a basic example of the EmbeddedMethod UI component with default RDC configuration. This demo shows the component in action with transaction processing and visual feedback. When the component processes a transaction, the demo displays the JSON response. ### Customized This is an example of the EmbeddedMethod component with customized input fields and configuration switching logic. See the [Interactive demo for EmbeddedMethod UI](/guides/pay-in-components-embeddedmethod-ui#interactive-demo) for a live preview of this example. Customized EmbeddedMethod UI ## Handle responses and errors The embedded components return response objects to callback functions that you define in the component configuration. You can use these callback functions to handle responses and errors, such as displaying messages to users. There are four possible callback functions that are triggered based on the component's state: * `functionCallBackSuccess`: Triggered for successful transactions (2XX responses) and declined transactions (4XX responses). * `functionCallBackError`: Triggered for validation errors. * `functionCallBackReady`: Triggered when the component is ready to process a transaction. * `functionCallBackCancel`: Triggered when the user closes the component's modal. ### Callback support reference The callback functions supported are different for each component type. The following table shows which callback functions are supported by each component type:
Component Callback
EmbeddedMethod UI functionCallBackSuccess, functionCallBackReady, functionCallBackError
PayMethod UI functionCallBackSuccess, functionCallBackError
VirtualTerminal UI functionCallBackSuccess, functionCallBackError
ExpressCheckout UI functionCallBackSuccess, functionCallBackReady, functionCallBackError, functionCallBackCancel
### Declined transactions For a declined transaction, the `functionCallBackSuccess` callback is triggered. To determine whether a transaction was successful or declined, check the `responseText` field in the response object. A successful transaction returns `"Success"` in the `responseText` field, and a declined transaction returns `"Declined"`. After a declined transaction, we recommend calling the `payabliExec("reinit")` method to reinitialize the component so that the user can try again. This example shows how to handle successful transactions, declined transactions, and internal Payabli processing errors. See the [Response reference](/guides/pay-in-components-embeddedmethod-ui#response-reference) for each component to see more information about the response object. ```js functionCallBackSuccess example functionCallBackSuccess: function (response) { // This callback covers both 2XX and 4XX responses console.log(response); switch (response.responseText) { case "Success": // Tokenization was successful alert(`Success: ${response.responseData.resultText}`); break; case "Declined": /* Transaction or tokenization failed due to processor decline or validation errors Recommend reinitialization of the component so that the user can try again with different card data */ alert(`Declined: ${response.responseData.resultText}`); paycomponent0.payabliExec("reinit"); break; default: /* Other response text. These are normally errors with Payabli internal validations before processor engagement. We recommend reinitializing the component. If the problem persists, contact Payabli to help debug */ alert(`Error: ${response.responseText}`); paycomponent0.payabliExec("reinit"); break; } } ``` See [Payment response codes and errors](/guides/platform-return-codes-and-errors-reference#ach-response-codes) for more information about server errors and response codes. ### Error handling The `functionCallbackError` callback is triggered for validation errors. You can use this callback to display custom error messages to users or log errors for debugging. The `functionCallBackError` callback has a different response object based on the component type: * EmbeddedMethod UI, PayMethod UI, VirtualTerminal UI: [`functionCallBackError` response](/guides/pay-in-components-embeddedmethod-ui#functioncallbackerror-response) * ExpressCheckout UI: [ExpressCheckout UI documentation](/guides/pay-in-components-express-checkout#functioncallbackerror-response). ## Playground The [Embedded Component Playground](https://playground.payabli.com) lets you experiment with some component types with a live preview in your browser. ## Related resources See these related resources to help you get the most out of Payabli. * **[EmbeddedMethod UI](/guides/pay-in-components-embeddedmethod-ui)** - Learn how to use the EmbeddedMethod UI embedded component to add the ability to securely store a payment profile or execute a sale * **[ExpressCheckout UI](/guides/pay-in-components-express-checkout)** - Learn how to use the ExpressCheckout UI component on your site or in your app to securely accept digital wallet payments * **[Embedded components framework integrations](/guides/pay-in-developer-components-frameworks)** - Learn how to use Payabli's embedded components with front-end frameworks like React and Vue * **[PayMethod UI](/guides/pay-in-components-paymethod-ui)** - Learn how to use the PayMethod UI embedded component to securely store a payment profile with a low-code modal-based UI. * **[VirtualTerminal UI](/guides/pay-in-components-virtual-terminal-ui)** - Learn how to use the VirtualTerminal UI component on your site or in your app to securely accept payments * **[Payment methods for testing](/guides/test-accounts-reference)** - Use these payment methods to test your integration with Payabli * **[Payment response codes and errors](/guides/platform-return-codes-and-errors-reference)** - Learn about payment response codes for different payment methods * **[Extend embedded components with the temporary token flow (for developers)](/guides/platform-developer-tokenization-temp-flow)** - Use the temporary token flow with embedded components to have complete control over user transaction experience without expanding PCI scope *** title: EmbeddedMethod UI subtitle: >- Learn how to use the EmbeddedMethod UI embedded component to add the ability to securely store a payment profile or execute a sale description: >- Integrate EmbeddedMethod UI to securely store payment profiles or execute sales. Configure card, ACH, and check inputs with full styling and behavior control 'og:description': >- Integrate EmbeddedMethod UI to securely store payment profiles or execute sales. Configure card, ACH, and check inputs with full styling and behavior control keywords: >- embedded payments, EmbeddedMethod UI, embedded components, payment form, card payments, ACH payments, checkout integration icon: puzzle-piece slug: guides/pay-in-components-embeddedmethod-ui area: * Pay In subArea: * Components * Tokenization audience: * developers *** Use the EmbeddedMethod component to capture a payment method or make a sale using any payment method. This is the most flexible and customizable component Payabli offers to developers. This component is supported in the Playground. Use the [Embedded Component Playground](https://playground.payabli.com) to edit and design embedded components in real time, and export the code to use in your own site or app. ## Usage This section shows how to use the EmbeddedMethod UI component in your project. Use the interactive demo to see how the component works, then follow the configuration walkthrough to set it up in your project. See [Library URLs](/guides/pay-in-components-overview#library-urls) for important information about embedded components library URLs. ### Interactive demo This demo shows the component in action with transaction processing and visual feedback. When the component processes a transaction, the demo displays the JSON response. ### Configuration walkthrough
/// Include the Payabli Script First, add the Payabli embedded component script to your HTML. Make sure to include the `data-test` attribute for testing in the sandbox environment. Including `` in the `` element prevents problems with special characters such as 'á' or 'ñ'. ```html Payabli Integration ``` /// Create the Container and Tab Structure Add a container element where the embedded component will render. The `id` attribute becomes the `rootContainer` in your configuration. Create tabs to switch between card, ACH, and RDC payment methods. ```html focus=8-19 Payabli Integration

Payment Form

``` /// Add Basic Styling Add CSS styles for the tabs to handle active and focus states. ```html focus=6-53 Payabli Integration

Payment Form

``` /// Configure Card Payment Method Create the configuration object for card payments. The `token` must be a **public API token**. ```html focus=70-159 Payabli Integration

Payment Form

``` /// Configure ACH Payment Method Create the configuration object for ACH payments. The `token` must be a **public API token**. ```html focus=160-243 Payabli Integration

Payment Form

``` /// Configure RDC Payment Method Create the configuration object for RDC (Remote Deposit Capture) payments. The `token` must be a **public API token**. ```html focus=227-278 Payabli Integration

Payment Form

``` /// Add Tab Switching Logic Add JavaScript code for the tabs. The code handles reinitializing the component when users change payment methods. ```html focus=280-298 Payabli Integration

Payment Form

``` /// Initialize and Execute Payment Use the `payabliExec('pay')` function to perform payment processing logic. This function processes a secure one-time payment with the embedded component. ```html focus=301-322 Payabli Integration

Payment Form

Enter your payment information below:

```
/// Include the Payabli Script First, add the Payabli embedded component script to your HTML. Make sure to include the `data-test` attribute for testing in the sandbox environment. This loads the core `PayabliComponent` class that powers all embedded components. Including `` in the `` element prevents problems with special characters such as 'á' or 'ñ'. ```html Payabli Integration - Temporary Token Flow ``` /// Create the Container and Tab Structure Add a container element where the embedded component will render. The `id` attribute becomes the `rootContainer` in your configuration. Create tabs to switch between card and ACH payment methods. ```html focus=8-18 Payabli Integration

Payment Form

``` /// Add Basic Styling Add CSS styles for the tabs to handle active and focus states. ```html focus=6-52 Payabli Integration

Payment Form

``` /// Configure Card Payment Method Create the configuration object for card payments with `temporaryToken: true`. This setting enables the temporary token flow. See [Temp token flow](/guides/platform-developer-tokenization-temp-flow) for more information about the temporary token flow. The `token` must be a **public API token**. ```html focus=68-157 Payabli Integration

Payment Form

``` /// Configure ACH Payment Method Create the configuration object for ACH payments with `temporaryToken: true`. The `token` must be a **public API token**. ```html focus=158-241 Payabli Integration

Payment Form

``` /// Add Tab Switching Logic Add JavaScript code for the tabs. The code handles reinitializing the component when users change payment methods. ```html focus=226-241 Payabli Integration

Payment Form

``` /// Initialize and Execute Token Generation Use the `payabliExec('method')` function to trigger temporary token generation. This function generates a secure temporary token for the payment method entered into the embedded component. For more information on using temporary tokens, see [Extend embedded components with the temporary token flow](/guides/platform-developer-tokenization-temp-flow). ```html focus=245-257 Payabli Integration

Payment Form

Enter your payment information to generate a temporary token:

```
### Configuration reference These are the configuration parameters available for the EmbeddedMethod component. If you need to pass more than data than what's supported, consider using the temporary token flow. See [Temporary Token Flow](/guides/platform-developer-tokenization-temp-flow) for more information. This value determines the type of embedded component to render.\ Accepted values are: `methodEmbedded`, `methodLightbox`, `vterminal`, or `expressCheckout`.\ For the EmbeddedMethod UI, this value is `methodEmbedded`. See the [Embedded Components Overview](/guides/pay-in-components-overview) for more information on other component types. Container ID used for the component. Sets the default payment method that's shown. Accepted values are: `card` or `ach`. When true the component is hidden when it's instanced. API token for authentication. This should be a **public** API token, as described [here](/developers/api-reference/api-overview#authentication#organization-token-most-common). When `true`, the component uses the `customerData` object to create a new customer record. When `temporaryToken` is `true` and `forceCustomerCreation` is `false`, the component doesn't create a new customer record. See [Temporary Token Flow](/guides/platform-developer-tokenization-temp-flow#disable-customer-creation) for more information. Complete URL of a custom CSS stylesheet to use with the component. When `true`, the entered values on the form are cleared when submitted. When `true`, the token created for the payment is temporary. Set this parameter to false to create a storedMethodId and save the payment profile. When `false`, the validation error appears below the field instead of above it in a popover. When the API token belongs to an organization, the entrypoint name identifies the target paypoint (merchant). `cardService` object used to configure accepted card types. Enable/disable card option. Enable/disable acceptance of American Express cards. Enable/disable acceptance of Discover cards. Enable/disable acceptance of Visa cards. Enable/disable acceptance of MasterCard cards. Enable/disable acceptance of Diner's Club cards. Enable/disable acceptance of JCB cards. Card input fields descriptors. This object applies only to the EmbeddedMethod UI component. Optional, but *strongly recommended*. Descriptor object for input field. Descriptor object for input field. Descriptor object for input field. Descriptor object for input field. Optional, but *strongly recommended*. Descriptor object for input field. `achService` object used to configure accepted ACH types. Enable/disable ACH option. Enable/disable acceptance of Checking account. Enable/disable acceptance of Savings account. When set to true, the embedded component will validate ACH account and routing numbers in real time. This is an add-on feature. Contact the Payabli team for more information. ACH input field descriptors. This only applies to the EmbeddedMethod UI component. Required. Descriptor object for input field. Required. Descriptor object for input field. Required. Descriptor object for input field. Use the `confirm` input descriptor to add matching validation to this field. See [Style Individual Fields](/guides/pay-in-components-overview#style-individual-fields) for more. Required. Descriptor object for input field. Use the `confirm` input descriptor to add matching validation to this field. See [Style Individual Fields](/guides/pay-in-components-overview#style-individual-fields) for more. `rdcService` object used to configure accepted RDC types. Enable/disable RDC option. Amount to collect via RDC. RDC input field descriptors. Descriptor object for input field. Descriptor object for input field. `paymentMethod` object with data related to the payment method. **Required when saving a payment method or executing a payment**. Can be passed to the component via payabliExec method. Customer Object with data related to customer. Can be passed to the component as a parameter with the `payabliExec` method. **Required when saving a payment method**. Which fields are required depends on whether the paypoint has custom identifiers. If you aren't using custom identifiers, then you must include at least one of these values: `firstname` and `lastname`, `email`, or `customerId`. `paymentDetails` object with data related to the payment. **Required to save a payment method**. Can be passed to the component via payabliExec method. When `true`, if tokenization fails, Payabli will attempt an authorization transaction to request a permanent token for the card. If the authorization is successful, the card will be tokenized and the authorization will be voided automatically. The amount for the `fallbackAuth` transaction. Defaults to one dollar. The callback function called when the component executes successfully. The callback function called when the component receives an error. See [functionCallBackError response](#functioncallbackerror-response) in the next section for a complete reference. The callback function called when the component's status changes. Used to poll the form's completeness before showing the submit button. ## Response The embedded component returns a response object to the callback functions defined in the configuration. The response object contains the result of the transaction (success, declined, or error) and details about the transaction. ### Response examples Click the tab to see an example response returned by the embedded component for each result. ```js Payment success { responseText: "Success", responseData: { authCode: "123456", referenceId: "40-692c62895d1541d28c0bf77b275a26e4", resultCode: 1, resultText: "Approved", avsResponseText: "", cvvResponseText: "", customerId: 706, methodReferenceId: null } } ``` ```js Payment decline { responseText: "Declined", responseData: { authCode: null, referenceId: "40-2c437c3dcdc242bea96f52bdf42d2eeb", resultCode: 2, resultText: "200: Decline. Generally insufficient funds or incorrect card data supplied, for example, expiry date or security code.. DECLINE", avsResponseText: "", cvvResponseText: "", customerId: 706, methodReferenceId: null } } ``` ```js Stored method success { responseText: "Success", responseData: { referenceId: "187-c5892026d9f345ffa63bf909d574fe92", resultCode: 1, resultText: "Added", customerId: 1636, methodReferenceId: "187-c5892026d9f345ffa63bf909d574fe92" } } ``` ```js Stored method decline { responseText: "Declined", responseData: { referenceId: "187-d2a29970fa604edba5a6dbec67ace3ae", resultCode: 2, resultText: "200: Transaction was declined by processor.. DECLINE", customerId: 1636, methodReferenceId: "187-d2a29970fa604edba5a6dbec67ace3ae" } } ``` ### Response reference The response object passed to a callback function has the following structure: "Success" or "Declined" Container for response details. Authorization code for payments. This field has a value of `null` for saved payment methods. Identifier for the transaction (for payments) or the stored payment method (for save payment method). Result of operation. 1 is success, 2 is declined, and 3 is error. Message related the result. If the operation was successful, it returns "Added"/"Approved". If there was an error, it returns error details. Result of address validation for card transactions. This field is an empty string when processing ACH transactions. This field doesn't exist when saving payment methods. Result of CVV validation for card transactions. This field is an empty string when processing ACH transactions. This field doesn't exist when saving payment methods. ID for the customer owner of payment or saved payment method. Identifier for stored payment method for saved payment methods. This field has a value of `null` for payment transactions. The `methodReferenceId` is used as the `storedMethodId` in other operations. See [Handling responses and errors](/guides/pay-in-components-overview#handling-responses-and-errors) for more. ### `functionCallBackError` response The `functionCallBackError` function is called when the component can't validate the payment information before submitting it to Payabli's API. The response object passed to `functionCallBackError` contains an array with codes, keys, and descriptions of failed validations. You can check the values in the array to offer your customized error message.
Code Key Description
802 paymentMethodsCardNumberError Error in Card number field
803 paymentMethodsCardExpirationDateError Error in Card Expiration field
804 paymentMethodsCardCvvError Error in CardCVV field
805 paymentMethodsCardZipcodeError Error in Card Zip code field
901 paymentMethodsAchAccountHolderNameError Error in ACH Holder field
902 paymentMethodsAchAccountTypeError Error in ACH Account type field
903 paymentMethodsAchRoutingError Error in ACH Routing field
904 paymentMethodsAchAccountError Error in ACH Account number field
## Usage Flows These flowcharts illustrate the path to making a payment or storing a payment method using an embedded component. ### Make a payment To make a payment with an embedded component, your component configuration should contain `payabliExec(pay, parameters)`. In the `parameters` argument, include `customerData` and `paymentDetails` objects. When the payment is executed, the request returns response data. *This flowchart explains the basic steps for the task. Hover over a step for more information.*
Run `payabliExec(pay, parameters)` The action is set to `pay` here. Send the `paymentDetail` and `customerData` object in `parameters`.
Payment executed The transaction is executed and includes the data sent as parameters
Response
### Save a payment method To save a payment method with an embedded component, your component configuration should contain `payabliExec(method, parameters)`. In the `parameters` argument, include `customerData` and `paymentDetails` objects. When the payment method is saved, the request returns response data. *This flowchart explains the basic steps for the task. Hover over a step for more information.*
Run `payabliExec(method, parameters)` The action is set to `method` here. Send the `paymentDetail` and `customerData` object in `parameters`.
Payment method saved The payment method is saved and includes the data sent as parameters
Response
### Save a payment method and make a payment You can save a payment method and make a payment with the EmbeddedMethod UI component by writing a callback function to execute the payment after successfully saving the payment method. To save a payment method and then execute a transaction with the saved payment method, your component configuration should contain `payabliExec(method, parameters)`. In the `parameters` argument, include the `customerData` and `paymentDetails` objects. When the payment method is saved, use a callback function to execute the transaction. Remember to never make payment transactions via client-side API requests. Your callback function should make the payment transaction using a server-side function. *This flowchart explains the basic steps for the task. Hover over a step for more information.*
Run `payabliExec(method, parameters)` Here, the action is set to `method`. Send the `paymentDetail` and `customerData` object in `parameters`.
Payment method saved The payment method is saved and includes the data sent as parameters. An ID for the payment method is returned, which is then used to make transactions.
Callback function Use a callback function to send a transaction that uses the new payment method.
Response
## Related resources See these related resources to help you get the most out of Payabli. * **[Embedded components framework integrations](/guides/pay-in-developer-components-frameworks)** - Learn how to use Payabli's embedded components with front-end frameworks like React and Vue * **[Temporary token example app (for developers)](/guides/platform-tokenization-temp-token-app)** - Go through a guided checkout experience using the temporary token flow * **[Extend embedded components with the temporary token flow (for developers)](/guides/platform-developer-tokenization-temp-flow)** - Use the temporary token flow with embedded components to have complete control over user transaction experience without expanding PCI scope * **[Embedded components overview](/guides/pay-in-components-overview)** - Learn how to use Payabli's embedded components to create customized checkout experiences without handling sensitive payment information yourself *** title: PayMethod UI subtitle: >- Learn how to use the PayMethod UI embedded component to securely store a payment profile with a low-code modal-based UI. description: >- Integrate PayMethod UI to securely save customer payment profiles through a low-code, modal-based experience. Support card and ACH with minimal frontend effort 'og:description': >- Integrate PayMethod UI to securely save customer payment profiles through a low-code, modal-based experience. Support card and ACH with minimal frontend effort keywords: >- embedded payments, PayMethod UI, embedded components, save payment method, payment profile, low-code payments icon: puzzle-piece slug: guides/pay-in-components-paymethod-ui area: * Pay In subArea: * Components * Tokenization audience: * developers *** Before integrating with this component, we highly recommend reading [Embedded Components Overview](/guides/pay-in-components-overview) to make sure you select the right component for your use case, authenticate properly, and understand how to style the components. This page covers only the configuration unique to this component, and doesn't cover all the basic usage for embedded components. Use the PayMethod UI component to open a modal that captures a customer payment method for tokenization. The captured payment method is returned as an ID. Use the ID make future transactions via API with the `storedMethodId` field. This component is supported in the Playground. Use the [Embedded Component Playground](https://playground.payabli.com) to edit and design embedded components in real time, and export the code to use in your own site or app. ## Usage The PayMethod UI component is a modal that's displayed over content and can be triggered via an event listener or function. Use the interactive demo to see how the component works, then follow the configuration walkthrough to set it up in your project. See [Library URLs](/guides/pay-in-components-overview#library-urls) for important information about embedded components library URLs. ### Interactive demo This demo shows the component in action with transaction processing and visual feedback. When the component processes a transaction, the demo displays the JSON response. ### Configuration walkthrough
/// Include the Payabli Script First, add the Payabli embedded component script to your HTML. Make sure to include the `data-test` attribute for testing in the sandbox environment. Including `` in the `` element prevents problems with special characters such as ‘á’ or ‘ñ’. ```html Payabli Integration ``` /// Create the Container Add a container element where the embedded component renders. The configuration references this element by its `id` attribute. This `
` element serves as the mounting point where the embedded component renders. ```html focus=8-9 Payabli Integration

Payment Form

``` /// Configure the Component Create the configuration object that defines how your embedded component behaves. This configuration includes authentication tokens, payment method settings, and callback functions. The `rootContainer` property connects the component to your HTML element by matching the `id` attribute value. The `token` value must be a **public API token**. See the [Configuration Reference](#configuration-reference) for more information. ```html focus=12-50 Payabli Integration
``` /// Add Callback Functions Implement success and error callback functions to handle component responses and form validation states. These callback functions execute after the user submits payment information and the component receives a response from Payabli's API. These functions can call the `closeModal` and `payabliExec` methods to manage the embedded component's state. ```html focus=54-91 Payabli Integration

Payment Form

``` /// Initialize and Show Modal The final step creates a working payment method component that can securely save payment methods for future transactions. Add a click handler to the button that calls the `showModal` method to display the embedded component. ```html focus=94-100 Payabli Integration

Payment Form

Click below to save a payment method:

```
### Configuration reference These are the configuration parameters available for the PayMethod component. If you need to pass more than data than what's supported, consider using the temporary token flow. See [Temporary Token Flow](/guides/platform-developer-tokenization-temp-flow) for more information. This value determines the type of embedded component to render.\ Accepted values are: `methodEmbedded`, `methodLightbox`, `vterminal`, or `expressCheckout`.\ For the PayMethod UI, this value is `methodLightbox`. See the [Embedded Components Overview](/guides/pay-in-components-overview) for more information on other component types. Container ID used for the component. Sets the default payment method that's shown. Accepted values are: `card` or `ach`. Text label for the action button. When true the component is hidden when it's instanced. API token for authentication. When `true`, the component uses the `customerData` object to create a new customer record. When `temporaryToken` is `true` and `forceCustomerCreation` is `false`, the component doesn't create a new customer record. See [Temporary Token Flow](/guides/platform-developer-tokenization-temp-flow#disable-customer-creation) for more information. Complete URL of a custom CSS stylesheet to use with the component. When `true`, the token created for the payment is temporary. Set this parameter to false to create a storedMethodId and save the payment profile. `cardService` object used to configure accepted card types. Enable/disable card option. Enable/disable acceptance of American Express cards. Enable/disable acceptance of Discover cards. Enable/disable acceptance of Visa cards. Enable/disable acceptance of MasterCard cards. Enable/disable acceptance of Diner's Club cards. Enable/disable acceptance of JCB cards. Card input fields descriptors. This object applies only to the EmbeddedMethod UI component. Optional, but *strongly recommended*. Descriptor object for input field. Descriptor object for input field. Descriptor object for input field. Descriptor object for input field. Optional, but *strongly recommended*. Descriptor object for input field. `achService` object used to configure accepted ACH types. Enable/disable ACH option. Enable/disable acceptance of Checking account. Enable/disable acceptance of Savings account. When set to true, the embedded component will validate ACH account and routing numbers in real time. This is an add-on feature. Contact the Payabli team for more information. ACH input field descriptors. This only applies to the EmbeddedMethod UI component. Required. Descriptor object for input field. Required. Descriptor object for input field. Required. Descriptor object for input field. Use the `confirm` input descriptor to add matching validation to this field. See [Style Individual Fields](/guides/pay-in-components-overview#style-individual-fields) for more. Required. Descriptor object for input field. Use the `confirm` input descriptor to add matching validation to this field. See [Style Individual Fields](/guides/pay-in-components-overview#style-individual-fields) for more. `paymentMethod` object with data related to the payment method. **Required when saving a payment method or executing a payment**. Can be passed to the component via payabliExec method. Customer Object with data related to customer. Can be passed to the component via payabliExec method. **Required when saving a payment method**. Which fields are required depends on whether the paypoint has custom identifiers. If you aren't using custom identifiers, then you must include at least one of these values: `firstname` and `lastname`, `email`, or `customerId`. When `true`, if tokenization fails, Payabli will attempt an authorization transaction to request a permanent token for the card. If the authorization is successful, the card will be tokenized and the authorization will be voided automatically. The amount for the `fallbackAuth` transaction. Defaults to one dollar. The callback function called when the component executes successfully. The callback function called when the component receives an error. See [functionCallBackError response](#functioncallbackerror-response) in the next section for a complete reference. ## Response The embedded component returns a response object to the callback functions defined in the configuration. The response object contains the result of the transaction (success, declined, or error) and details about the transaction. ### Response examples Click the tab to see an example response returned by the embedded component for each result. ```js Stored method success { responseText: "Success", responseData: { referenceId: "187-c5892026d9f345ffa63bf909d574fe92", resultCode: 1, resultText: "Added", customerId: 1636, methodReferenceId: "187-c5892026d9f345ffa63bf909d574fe92" } } ``` ```js Stored method decline { responseText: "Declined", responseData: { referenceId: "187-d2a29970fa604edba5a6dbec67ace3ae", resultCode: 2, resultText: "200: Transaction was declined by processor.. DECLINE", customerId: 1636, methodReferenceId: "187-d2a29970fa604edba5a6dbec67ace3ae" } } ``` ### Response reference The response object passed to a callback function has the following structure: "Success" or "Declined" Container for response details. Identifier for the transaction (for payments) or the stored payment method (for save payment method). The `referenceId` is used as the `storedMethodId` in other operations. See [Handling responses and errors](/guides/pay-in-components-overview#handling-responses-and-errors) for more. Result of operation. 1 is success, 2 is declined, and 3 is error. Message related the result. If the operation was successful, it returns "Added"/"Approved". If there was an error, it returns error details. ID for the customer owner of payment or saved payment method. Identifier for stored payment method for saved payment methods. This field has a value of `null` for payment transactions. The `methodReferenceId` is used as the `storedMethodId` in other operations. See [Handling responses and errors](/guides/pay-in-components-overview#handling-responses-and-errors) for more. ### `functionCallBackError` response The `functionCallBackError` function is called when the component can't validate the payment information before submitting it to Payabli's API. The response object passed to `functionCallBackError` contains an array with codes, keys, and descriptions of failed validations. You can check the values in the array to offer your customized error message.
Code Key Description
802 paymentMethodsCardNumberError Error in Card number field
803 paymentMethodsCardExpirationDateError Error in Card Expiration field
804 paymentMethodsCardCvvError Error in CardCVV field
805 paymentMethodsCardZipcodeError Error in Card Zip code field
901 paymentMethodsAchAccountHolderNameError Error in ACH Holder field
902 paymentMethodsAchAccountTypeError Error in ACH Account type field
903 paymentMethodsAchRoutingError Error in ACH Routing field
904 paymentMethodsAchAccountError Error in ACH Account number field
## Related resources See these related resources to help you get the most out of Payabli. * **[Embedded components overview](/guides/pay-in-components-overview)** - Learn how to use Payabli's embedded components to create customized checkout experiences without handling sensitive payment information yourself * **[Extend embedded components with the temporary token flow (for developers)](/guides/platform-developer-tokenization-temp-flow)** - Use the temporary token flow with embedded components to have complete control over user transaction experience without expanding PCI scope *** title: VirtualTerminal UI subtitle: >- Learn how to use the VirtualTerminal UI component on your site or in your app to securely accept payments description: >- Embed VirtualTerminal UI on your site to securely accept card and ACH payments. Configure fields, styling, and response handling with a customizable component 'og:description': >- Embed VirtualTerminal UI on your site to securely accept card and ACH payments. Configure fields, styling, and response handling with a customizable component keywords: >- embedded payments, VirtualTerminal UI, virtual terminal, embedded components, accept payments, card payments, ACH payments icon: puzzle-piece slug: guides/pay-in-components-virtual-terminal-ui area: * Pay In subArea: * Components audience: * developers *** The VirtualTerminal UI component lets you embed a payment terminal inside your website or application. This modal-based component is perfect for admin interfaces, customer service tools, and any application where you need to process payments on behalf of customers. an image of a virtual terminal component window ## Usage This component lets you add a robust virtual terminal tool to your pages or apps. Follow the configuration walkthrough to set it up in your project. See [Library URLs](/guides/pay-in-components-overview#library-urls) for important information about embedded components library URLs. ### Configuration walkthrough
/// Include the Payabli Script First, add the Payabli embedded component script to your HTML. Make sure to include the `data-test` attribute for testing in the sandbox environment. Including `` in the `` element prevents problems with special characters such as ‘á’ or ‘ñ’. ```html Payabli Integration ``` /// Create the Container Add a container element where the embedded component renders. The configuration references this element by its `id` attribute. This `
` element serves as the mounting point where the embedded component renders. ```html focus=8-9 Payabli Integration

Virtual Terminal

``` /// Configure the Component Create the configuration object that defines how your embedded component behaves. This configuration includes authentication tokens, payment method settings, and callback functions. The `rootContainer` property connects the component to your HTML element by matching the `id` attribute value. The `token` value must be a **public API token**. See the [Configuration Reference](#configuration-reference) for more information. ```html focus=13-62 Payabli Integration

Virtual Terminal

``` /// Add Callback Functions Implement success and error callback functions to handle component responses and form validation states. These callback functions execute after the user submits payment information and the component receives a response from Payabli's API. ```html focus=82-101 Payabli Integration

Virtual Terminal

``` /// Initialize and Show Terminal The final step creates a working virtual terminal that can process transactions with both card and ACH payment methods. ```html focus=108-114 Payabli Integration

Virtual Terminal

Click below to open the payment terminal:

```
### Configuration reference These are the configuration parameters available for the VirtualTerminal component. If you need to pass more than data than what's supported, consider using the temporary token flow. See [Temporary Token Flow](/guides/platform-developer-tokenization-temp-flow) for more information. This value determines the type of embedded component to render.\ Accepted values are: `methodEmbedded`, `methodLightbox`, `vterminal`, or `expressCheckout`.\ For the VirtualTerminal UI, this value is `vterminal`. See the [Embedded Components Overview](/guides/pay-in-components-overview) for more information on other component types. Container ID used for the component. Sets the default payment method that's shown. Accepted values are: `card` or `ach`. Text label for the action button. When true the component is hidden when it's instanced. API token for authentication. Complete URL of a custom CSS stylesheet to use with the component. When `true`, enables the recurring payment option in terminal. When `true`, enables the one-time payment option in terminal. `lineItem` objects with data related to the line items for the transaction. `cardService` object used to configure accepted card types. Enable/disable card option. Enable/disable acceptance of American Express cards. Enable/disable acceptance of Discover cards. Enable/disable acceptance of Visa cards. Enable/disable acceptance of MasterCard cards. Enable/disable acceptance of Diner's Club cards. Enable/disable acceptance of JCB cards. Card input fields descriptors. This object applies only to the EmbeddedMethod UI component. Optional, but *strongly recommended*. Descriptor object for input field. Descriptor object for input field. Descriptor object for input field. Descriptor object for input field. Optional, but *strongly recommended*. Descriptor object for input field. `achService` object used to configure accepted ACH types. Enable/disable ACH option. Enable/disable acceptance of Checking account. Enable/disable acceptance of Savings account. When set to true, the embedded component will validate ACH account and routing numbers in real time. This is an add-on feature. Contact the Payabli team for more information. ACH input field descriptors. This only applies to the EmbeddedMethod UI component. Required. Descriptor object for input field. Required. Descriptor object for input field. Required. Descriptor object for input field. Use the `confirm` input descriptor to add matching validation to this field. See [Style Individual Fields](/guides/pay-in-components-overview#style-individual-fields) for more. Required. Descriptor object for input field. Use the `confirm` input descriptor to add matching validation to this field. See [Style Individual Fields](/guides/pay-in-components-overview#style-individual-fields) for more. `paymentMethod` object with data related to the payment method. **Required when saving a payment method or executing a payment**. Can be passed to the component via payabliExec method. Customer Object with data related to customer. Can be passed to the component via payabliExec method. **Required when saving a payment method**. Which fields are required depends on whether the paypoint has custom identifiers. If you aren't using custom identifiers, then you must include at least one of these values: `firstname` and `lastname`, `email`, or `customerId`. `paymentDetails` object with data related to the payment. **Required when running a payment**. Can be passed to the component via payabliExec method. See [paymentDetails Object]() for a full reference. When `true`, if tokenization fails, Payabli will attempt an authorization transaction to request a permanent token for the card. If the authorization is successful, the card will be tokenized and the authorization will be voided automatically. The amount for the `fallbackAuth` transaction. Defaults to one dollar. The callback function called when the component executes successfully. The callback function called when the component receives an error. See **functionCallBackError response** in the next section for a complete reference. ## Response The embedded component returns a response object to the callback functions defined in the configuration. The response object contains the result of the transaction (success, declined, or error) and details about the transaction. ### Response examples Click the tab to see an example response returned by the embedded component for each result. ```js Payment success { responseText: "Success", responseData: { authCode: "123456", referenceId: "40-692c62895d1541d28c0bf77b275a26e4", resultCode: 1, resultText: "Approved", avsResponseText: "", cvvResponseText: "", customerId: 706, methodReferenceId: null } } ``` ```js Payment decline { responseText: "Declined", responseData: { authCode: null, referenceId: "40-2c437c3dcdc242bea96f52bdf42d2eeb", resultCode: 2, resultText: "200: Decline. Generally insufficient funds or incorrect card data supplied, for example, expiry date or security code.. DECLINE", avsResponseText: "", cvvResponseText: "", customerId: 706, methodReferenceId: null } } ``` ```js Stored method success { responseText: "Success", responseData: { referenceId: "187-c5892026d9f345ffa63bf909d574fe92", resultCode: 1, resultText: "Added", customerId: 1636, methodReferenceId: "187-c5892026d9f345ffa63bf909d574fe92" } } ``` ```js Stored method decline { responseText: "Declined" responseData: { referenceId: "187-d2a29970fa604edba5a6dbec67ace3ae", resultCode: 2, resultText: "200: Transaction was declined by processor.. DECLINE", customerId: 1636, methodReferenceId: "187-d2a29970fa604edba5a6dbec67ace3ae" } } ``` ### Response reference The response object passed to a callback function has the following structure: "Success" or "Declined" Container for response details. Authorization code for payments. Identifier for the transaction (for payments) or the stored payment method (for save payment method). The `referenceId` is used as the `storedMethodId` in other operations. See [Handling responses and errors](/guides/pay-in-components-overview#handling-responses-and-errors) for more. Result of operation. 1 is success, 2 is declined, and 3 is error. Message related the result. If the operation was successful, it returns "Added"/"Approved". If there was an error, it returns error details. ID for the customer owner of payment or saved payment method. ## Related resources See these related resources to help you get the most out of Payabli. * **[Embedded components overview](/guides/pay-in-components-overview)** - Learn how to use Payabli's embedded components to create customized checkout experiences without handling sensitive payment information yourself *** title: ExpressCheckout UI subtitle: >- Learn how to use the ExpressCheckout UI component on your site or in your app to securely accept digital wallet payments description: >- Add ExpressCheckout UI to your site to accept Apple Pay and Google Pay. Integrate digital wallet payments with minimal code using a drop-in checkout component 'og:description': >- Add ExpressCheckout UI to your site to accept Apple Pay and Google Pay. Integrate digital wallet payments with minimal code using a drop-in checkout component keywords: >- embedded payments, ExpressCheckout UI, Apple Pay, Google Pay, digital wallets, embedded components, checkout component icon: puzzle-piece slug: guides/pay-in-components-express-checkout area: * Pay In subArea: * Components * Wallets audience: * developers *** The ExpressCheckout component lets you embed an express checkout for digital wallets inside your website or application. This component provides seamless integration with Apple Pay and Google Pay. an image of an ExpressCheckout component rendered on a site ## Usage This component lets you add a robust low-code way to accept payments from digital wallets to your pages or apps with automatic device compatibility detection. Follow the configuration walkthrough to set it up in your project. See [Library URLs](/guides/pay-in-components-overview#library-urls) for important information about embedded components library URLs. ### Configuration walkthrough
/// Include the Payabli Script First, add the Payabli embedded component script to your HTML. Make sure to include the `data-test` attribute for testing in the sandbox environment. Including `` in the `` element prevents problems with special characters such as ‘á’ or ‘ñ’. ```html Payabli Integration ``` /// Create the Container Add a container element where the embedded component renders. The configuration references this element by its `id` attribute. This `
` element serves as the mounting point where the embedded component renders. ```html focus=8-9 Payabli Integration

Express Checkout

``` /// Configure the Component Create the configuration object that defines how your embedded component behaves. This configuration includes authentication tokens, payment method settings, and callback functions. The `rootContainer` property connects the component to your HTML element by matching the `id` attribute value. The `token` value must be a **public API token**. See the [Configuration Reference](#configuration-reference) for more information. ```html focus=12-52 Payabli Integration

Express Checkout

``` /// Add Callback Functions Implement success, error, ready, and cancel callback functions to handle component responses and form validation states. These callback functions execute after the user interacts with the digital wallet buttons and the component receives a response from Payabli's API. ```html focus=63-105 Payabli Integration

Express Checkout

``` /// Initialize the Component The final step creates a working express checkout that can process transactions with digital wallets. ```html focus=112-113 Payabli Integration

Express Checkout

Pay securely with your digital wallet:

```
### Configuration reference These are the configuration parameters available for the ExpressCheckout component. This value determines the type of embedded component to render.\ Accepted values are: `methodEmbedded`, `methodLightbox`, `vterminal`, or `expressCheckout`.\ For the ExpressCheckout UI, this value is `expressCheckout`. See the [Embedded Components Overview](/guides/pay-in-components-overview) for more information on other component types. Container ID used for the component. When `true`, transactionDetails object is returned in the response. See a full example of the `transactionDetails` object in the [Transaction integration guide](/guides/pay-in-developer-transactions-create#includedetailstrue-response). API token for authentication. This should be a **public** API token, as described [here](/developers/api-reference/api-overview#authentication#organization-token-most-common). When the API token belongs to an organization, the entrypoint name identifies the target paypoint (merchant). Complete URL of a custom CSS stylesheet to use with the component. Configuration for the express checkout functionality. The amount for the transaction. The fee for the transaction. The currency for the transaction. Define the number of columns to use for digital wallet display. Card networks to accept payments from. Suggested options: * `amex` * `visa` * `discover` * `masterCard` * `jcb` When `true`, Apple Pay is enabled. The Apple Pay button style. Supported options: * “black”: Default black button. * “white-outline”: White button with an outline. * “white”: Solid white button. The text on Apple Pay button. Supported options: | Button Type | Description | Text on Apple Pay Button | | -------------- | -------------------------------------------------------------------------------------------------------- | ------------------------------ | | `"plain"` | An Apple Pay button with the Apple Pay logo only, useful when an additional call to action isn't needed. | Apple Pay logo only (no text) | | `"buy"` | Use this button for product purchases. | Buy with Apple Pay logo | | `"donate"` | Used by approved nonprofits. Lets people make donations. | Donate with Apple Pay logo | | `"check-out"` | Use this button for purchase experiences that include other payment buttons that start with "Check out". | Check Out with Apple Pay logo | | `"book"` | Use this button for booking appointments, flights, or other experiences. | Book with Apple Pay logo | | `"continue"` | Use this button for general purchases. | Continue with Apple Pay logo | | `"top-up"` | Use this button for adding money to an account, or payment system. | Top Up with Apple Pay logo | | `"order"` | Use this button for placing orders for items. | Order with Apple Pay logo | | `"rent"` | Use this button for renting items such as equipment or cars. | Rent with Apple Pay logo | | `"support"` | Use this button for helping people give money to projects, causes, organizations, and other entities. | Support with Apple Pay logo | | `"contribute"` | Use this button to help people give money to projects, causes, organizations, and other entities. | Contribute with Apple Pay logo | | `"tip"` | Use this button to let people tip for goods or services. | Tip with Apple Pay logo | | `"pay"` | Use this button for general purchases. | Pay with Apple Pay logo | The Apple Pay button locale. Supported options: * **en-US**: English (US) * **ar-AB**: Arabic * **ca-ES**: Catalan * **zh-CN**: Chinese (China) * **zh-HK**: Chinese (Hong Kong) * **zh-TW**: Chinese (Taiwan) * **hr-HR**: Croatian * **cs-CZ**: Czech * **da-DK**: Danish * **de-DE**: German * **nl-NL**: Dutch * **en-AU**: English (Australia) * **en-GB**: English (UK) * **fi-FI**: Finnish * **fr-CA**: French (Canada) * **fr-FR**: French (France) * **el-GR**: Greek * **he-IL**: Hebrew * **hi-IN**: Hindi * **hu-HU**: Hungarian * **id-ID**: Indonesian * **it-IT**: Italian * **ja-JP**: Japanese * **ko-KR**: Korean * **ms-MY**: Malay * **nb-NO**: Norwegian * **pl-PL**: Polish * **pt-BR**: Portuguese (Brazil) * **pt-PT**: Portuguese (Portugal) * **ro-RO**: Romanian * **ru-RU**: Russian * **sk-SK**: Slovak * **es-MX**: Spanish (Mexico) * **es-ES**: Spanish (Spain) * **sv-SE**: Swedish * **th-TH**: Thai * **tr-TR**: Turkish * **uk-UA**: Ukrainian * **vi-VN**: Vietnamese When `true`, Google Pay is enabled. The Google Pay button style. Supported options: * “dark”: Solid black button. * “light”: Solid white button. The text on Google Pay button. Supported options: | Button Type | Description | Text on Google Pay Button | | ------------ | ---------------------------------------------------------------------------------------------------------- | ------------------------------ | | `"plain"` | An Google Pay button with the Google Pay logo only, useful when an additional call to action isn't needed. | Google Pay logo only (no text) | | `"buy"` | Use this button for product purchases. | Buy with Google Pay logo | | `"donate"` | Used by approved nonprofits. Lets people make donations. | Donate with Google Pay logo | | `"checkout"` | Use this button for purchase experiences that include other payment buttons that start with "Check out". | Check Out with Google Pay logo | | `"book"` | Use this button for booking appointments, flights, or other experiences. | Book with Google Pay logo | | `"order"` | Use this button for placing orders for items. | Order with Google Pay logo | | `"pay"` | Use this button for general purchases. | Pay with Google Pay logo | The Google Pay button locale. Supported options: * **en**: English * **ar**: Arabic * **bg**: Bulgarian * **ca**: Catalan * **cs**: Czech * **da**: Danish * **de**: German * **el**: Greek * **es**: Spanish * **et**: Estonian * **fi**: Finnish * **fr**: French * **hr**: Croatian * **id**: Indonesian * **it**: Italian * **ja**: Japanese * **ko**: Korean * **ms**: Malay * **nl**: Dutch * **no**: Norwegian * **pl**: Polish * **pt**: Portuguese * **ru**: Russian * **sk**: Slovak * **sl**: Slovenian * **sr**: Serbian * **sv**: Swedish * **th**: Thai * **tr**: Turkish * **uk**: Ukrainian * **zh**: Chinese When this field is `true`, the following fields `["postalAddress", "name", "phoneticName", "phone", "email"]` are required. They will be sent with the payment and can be read through the callbacks. Height of the button. Border radius of the button. Horizontal padding. Vertical padding. Customer's identification number. Customer's first name. Customer's last name. Customer's billing email address. Triggered when the ExpressCheckout component is ready to use. Triggered upon successful completion of a digital wallet transaction. Triggered if an error occurs during the digital wallet transaction. Triggered if the user cancels the digital wallet transaction. ## Response The ExpressCheckout component uses callback functions to handle responses. The callback functions are triggered based on the component's state. There are four callback functions you can define in the configuration: * `functionCallBackReady`: Triggered when the component is ready to use. * `functionCallBackSuccess`: Triggered when a transaction is successfully completed. * `functionCallBackError`: Triggered if an error occurs during the transaction. * `functionCallBackCancel`: Triggered if the user cancels the transaction. Each callback function receives a different response object that contains information about the component's state. ### `functionCallbackReady` response The `functionCallbackReady` response is triggered when the component is ready to use. ```js Ready response { applePay: true, googlePay: false } ``` When `true`, the component is ready to accept Apple Pay. When `true`, the component is ready to accept Google Pay. ### `functionCallbackSuccess` response The `functionCallBackSuccess` response is triggered when a transaction is successfully completed with the ExpressCheckout component. The `referenceId` field of the response object is the transaction ID. The `referenceId` field can be used in other operations. ```js title="Success response" { data: { isSuccess: true, pageIdentifier: "t.XMzKRgtV6eJrI2Fsn45RLKuRujHi53qDnsizyJXNM7ChdejoRNOdb0Dm7VXQ3H/aBVMu+14IB9sOS1hbZF/kXMKgUY94nspVI+mRSphe8HeSwbr5OxLUSmu0Uuc6RmDzaLUYXn8eDr…", responseData: { authCode: "", avsResponseText: null, billingContact: { addressLines: ["9425 SW 172nd Pl"], administrativeArea: "FL", country: "United States", countryCode: "US", familyName: "Martinez", givenName: "Fernando", locality: "Miami", phoneticFamilyName: "", phoneticGivenName: "", postalCode: "33197", subAdministrativeArea: "", subLocality: "" }, customerId: 6886, cvvResponseText: null, methodReferenceId: null, referenceId: "1148-2305e2cb80eb5969920f2cf9f2565455", resultCode: 1, resultText: "Approved", shippingContact: { addressLines: ["9425 SW 172nd Pl"], administrativeArea: "FL", country: "United States", countryCode: "US", emailAddress: "fernandotest@payabli.com", familyName: "Martinez", givenName: "Fernando", locality: "Miami", phoneNumber: "4089752020", phoneticFamilyName: "4192412942195", phoneticGivenName: "941924129412943", postalCode: "33197", subAdministrativeArea: "", subLocality: "" } }, responseText: "Success" }, paymentMethod: "apple_pay" } ``` ```js title="Success response (includeDetails: true)" { data: { isSuccess: true, pageIdentifier: "t.Z...60=", responseData: { transactionDetails: { parentOrgName: "Compare2", paypointDbaname: "Homeowners Association of Antarctica", paypointLegalname: "Homeowners Association of Antarctica", paypointEntryname: "5b819b4b43", paymentTransId: "598-dfb15b5d43e198458fa453f5d392cbe5", connectorName: "gp", externalProcessorInformation: "", gatewayTransId: "TRN_stQI1cBclkHarUYJXqQ8L5pA5WQEW9", orderId: "", method: "wallet", batchNumber: "901_combined_2025...cce80", batchAmount: 12, payorId: 109018, paymentData: { maskedAccount: "XXXXXXXXXXXX1111", accountType: "VISA", accountExp: "12/27", holderName: "Card Holder Name", storedId: null, initiator: null, storedMethodUsageType: null, sequence: null, orderDescription: null, accountId: null, signatureData: null, binData: null, paymentDetails: { totalAmount: 32, serviceFee: 12, checkNumber: null, checkImage: null, checkUniqueId: "", currency: "USD", orderDescription: null, orderId: null, orderIdAlternative: null, paymentDescription: null, groupNumber: null, source: null, payabliTransId: null, unbundled: null, categories: [], splitFunding: [] } }, transStatus: 1, paypointId: 901, totalAmount: 32, netAmount: 20, feeAmount: 12, settlementStatus: 0, operation: "Sale", responseData: { response: null, responsetext: "CAPTURED", authcode: "", transactionid: "TRN_stLO1nYnaiCvmUGUXqQ9Y5pA5YBKW9", avsresponse: null, avsresponse_text: "", cvvresponse: null, cvvresponse_text: "", orderid: null, type: null, response_code: "100", response_code_text: "Operation successful", customer_vault_id: null, emv_auth_response_data: null }, source: "express_checkout_google_pay", scheduleReference: 0, orgId: 5607, refundId: 0, returnedId: 0, chargebackId: 0, retrievalId: 0, transAdditionalData: null, invoiceData: { invoiceNumber: null, invoiceDate: null, invoiceDueDate: null, invoiceEndDate: null, invoiceStatus: null, invoiceType: null, frequency: null, paymentTerms: null, termsConditions: null, notes: null, tax: null, discount: null, invoiceAmount: null, freightAmount: null, dutyAmount: null, purchaseOrder: null, firstName: null, lastName: null, company: null, shippingAddress1: null, shippingAddress2: null, shippingCity: null, shippingState: null, shippingZip: null, shippingCountry: null, shippingEmail: null, shippingPhone: null, shippingFromZip: null, summaryCommodityCode: null, items: null, attachments: null, additionalData: null }, entrypageId: 0, externalPaypointID: "0582-5", isValidatedACH: false, transactionTime: "2025-10-06T19:28:17.666", customer: { identifiers: null, firstName: "Marin", lastName: "Test", companyName: null, billingAddress1: "717 Road St", billingAddress2: null, billingCity: "Dukuth", billingState: "AK", billingZip: "383828283", billingCountry: null, billingPhone: "(123) 123-1234", billingEmail: "marin@test.com", customerNumber: "2652", shippingAddress1: null, shippingAddress2: null, shippingCity: null, shippingState: null, shippingZip: null, shippingCountry: null, customerId: 105128, customerStatus: 0, additionalData: {} }, splitFundingInstructions: null, cfeeTransactions: [ { cFeeTransId: "901-dfa95b5d...392cbe5", transStatus: 1, feeAmount: 12, settlementStatus: 0, operation: "Sale", responseData: { response: null, responsetext: null, authcode: null, transactionid: null, avsresponse: null, avsresponse_text: null, cvvresponse: null, cvvresponse_text: null, orderid: null, type: null, response_code: null, response_code_text: null, customer_vault_id: null, emv_auth_response_data: null, additional_response_text: null, processor_batch_id: null }, refundId: 0, transactionTime: "2025-10-06T19:28:17.666", gatewayTransId: null, transactionEvents: [ { transEvent: "Approved", eventData: null, eventTime: "2025-10-06T19:28:17.734001" } ] } ], transactionEvents: [ { transEvent: "Created", eventData: "0HNG1P12AP11I:000000E9", eventTime: "2025-10-06T19:28:14.306424" }, { transEvent: "Approved", eventData: "0HNG1P12AP11I:000000E9", eventTime: "2025-10-06T19:28:17.725458" } ], pendingFeeAmount: 0, riskFlagged: false, riskFlaggedOn: "2025-10-06T19:28:14.2971252", riskStatus: "PASSED", riskReason: "", riskAction: "", riskActionCode: 0, deviceId: "", achSecCode: "", achHolderType: "", ipAddress: "73.245.4.228", isSameDayACH: false, walletType: "google_pay" }, authCode: "", referenceId: "901-dfa95...cbe5", resultCode: 1, resultText: "Approved", avsResponseText: "", cvvResponseText: "", customerId: 105128, methodReferenceId: null }, responseText: "Success" }, paymentMethod: "google_pay" } ``` "Success" or "Declined" Container for response details. Authorization code for payments. Identifier for the transaction (for payments) or the stored payment method (for save payment method). Result of operation. 1 is success, 2 is declined, and 3 is error. Message related the result. If the operation was successful, it returns "Added"/"Approved". If there was an error, it returns error details. ID for the customer owner of payment. Text code describing the result for address validation. Text code describing the result for CVV validation. The stored method's identifier (sometimes referred to as 'token') in Payabli. When `null`, the method wasn't created, or doesn't exist, depending on the operation performed. The billing contact information. The street portion of the address for the contact. For example: 123 Main Street. The contact's state. For example, CA. Billing country. The contact's ISO 3166 country code. The contact's email address. The contact's family name, also known as last name. The contact's given name, also known as first name. The contact's city. For example, Los Angeles. Specifies the pronunciation of the contact's last name. Specifies the pronunciation of the contact's first name. The contact's postal code. The contact's county or other region. Additional information associated with the contact's address. Shipping address and contact information for the transaction. The street portion of the address for the contact. For example: 123 Main Street. The contact's state. For example, CA. Billing country. The contact's ISO 3166 country code. The contact's email address. The contact's family name, also known as last name. The contact's given name, also known as first name. The contact's city. For example, Los Angeles. The contact's phone number. Specifies the pronunciation of the contact's last name. Specifies the pronunciation of the contact's first name. The contact's postal code. The contact's county or other region. Additional information associated with the contact's address. Boolean indicating whether the operation was successful. A `true` value indicates success. A `false` value indicates failure. Auxiliary validation used by Payabli in payment pages and components. The payment method used. Possible values include "apple\_pay", "google\_pay", etc. ### `functionCallBackError` response This response is triggered if an error occurs during the transaction. ```js Error response { paymentMethod: "apple_pay", // apple_pay, google_pay etc error: { isSuccess: false, pageIdentifier: null, responseCode: 5005, responseData: { explanation: "", todoAction: "" }, responseText: "", roomId: null } } ``` The payment method used. Possible values include "apple\_pay", "google\_pay", etc. Container for error details when an error occurs. Indicates whether the operation was successful. In error cases, this will be false. Auxiliary validation used by Payabli in payment pages and components. The error code. For example, 5005. See [API responseCode and resultCode Reference](/developers/api-reference/api-responses) for a full list of error codes. Additional details about the error. A detailed explanation of the error. Suggested action to resolve the error. A brief description of the error. Internal field used by Payabli. ### `functionCallBackCancel` response This response is triggered if the user cancels the transaction while the modal is shown. ```js Cancel response { data: { isTrusted: true }, paymentMethod: "apple_pay" } ``` Container for response data. In this field, `true` indicates that the event was triggered by a user action, such as a user manually canceling the payment process. The digital wallet method used. ## Combine components If you want to accept digital wallet payments along with card or ACH payments, you can load both the [EmbeddedMethod UI](../guides/pay-in-components-embeddedmethod-ui) and ExpressCheckout UI components on the same webpage. You can also use `updateConfig` to switch between component configurations on your page. The code example renders the components in this image: an image of an ExpressCheckout component rendered on a site ```html ExpressCheckout, ACH, and Card example

Pay your order

``` ## Related resources See these related resources to help you get the most out of Payabli. * **[Apple Pay overview](/guides/pay-in-wallets-apple-pay-overview)** - You must have at least one wallet service implemented before using Express Checkout * **[Google Pay™ overview](/guides/pay-in-wallets-google-pay-overview)** - You must have at least one wallet service implemented before using Express Checkout * **[Embedded components overview](/guides/pay-in-components-overview)** - Learn how to use Payabli's embedded components to create customized checkout experiences without handling sensitive payment information yourself *** title: Embedded component playground subtitle: 'Design, test, and preview the embedded components from your browser' description: >- Design, test, and preview embedded component configurations in real time from your browser. Experiment with styling, fields, and layouts before writing code 'og:description': >- Design, test, and preview embedded component configurations in real time from your browser. Experiment with styling, fields, and layouts before writing code keywords: >- embedded payments, component playground, embedded components, payment UI preview, developer tools, checkout design slug: guides/pay-in-components-playground icon: display-code area: * Pay In subArea: * Components audience: * developers *** The Embedded Component Playground is a live test environment that lets you edit configurations, test themes and component types, and change up styling on the fly. The Playground aims to dramatically boost your developer productivity. Every code change gets instant feedback from the live coding environment. You can even choose to open your work in Code Sandbox, where you can download the code and integrate into your project or work with friends.
a graphic showing the playground UI a graphic showing the playground UI
Check out the [Playground](https://playground.payabli.com) to get started! ## Using the Playground Using the Playground is a breeze. Go to [https://playground.payabli.com](https://playground.payabli.com) and add your Payabli entrypoint and API token values. After you've done that, your component renders in real time and you can work on configuring it. ## Configuration drawer Open the configuration drawer by clicking the gear icon on the top left or using the keyboard shortcut \[Ctrl + K]. The drawer contains several helpful options to help you craft your component. Choose the type of component you want to use. The most popular and flexible option is EmbeddedMethod, but PayMethod is available too. This determines which UI preset to use to switch between configurations, such as Card or ACH payments. Controls what type of data the component will display, such as payment type, input field names, accepted card brands, and more. This is the theme that's used by the embedded component to style the container and fields. This supplementary theme styles some external UI controls, such as tabs, toggles, and trigger buttons that go with the embedded component. ## Experimenting with the code After you've set up your component's basic options, it's time to start experimenting with the code directly. In the code editor, there are three files which each control different functions: This file contains the setup that links your configuration and style together, and also contains the switcher mechanism and trigger buttons. This file contains the configuration for your component, like payment methods and input field names. For demo purposes in the Playground, it also contains the CSS to style the container and input fields. When you implement your own component, we *strongly* recommend that you export your theme's CSS to an external file and link it to your component using [customCssUrl](/guides/pay-in-components-overview#customize-component-styling). This file is where the control theme is located, which affects external UI controls such as the tabs, toggles, or trigger buttons. It also contains other important CSS that enables the components to function. ## Next steps Go ahead and experiment with the Playground. When you're done, you can either copy the content from the editor or open your work in Code Sandbox to download it. *** title: Extend embedded components with the temporary token flow (for developers) subtitle: >- Use the temporary token flow with embedded components to have complete control over user transaction experience without expanding PCI scope description: >- Use the temporary token flow with embedded components for full control over checkout. Capture tokens client-side, then process payments on your server securely 'og:description': >- Use the temporary token flow with embedded components for full control over checkout. Capture tokens client-side, then process payments on your server securely keywords: >- embedded payments, temporary tokens, embedded components, client-side tokenization, checkout flow, PCI compliance, payment security slug: guides/platform-developer-tokenization-temp-flow icon: binary-lock area: * Pay In subArea: * Tokenization * Components audience: * developers *** If you need more flexibility than Payabli's low-code embedded components provide, you can use a workflow that gives you the best of both worlds: the security and ease of embedded components and the flexibility of direct-access APIs. This temporary token flow lets you use the EmbeddedMethod UI and PayMethod UI embedded components to create a temporary payment token. Then you use that token for further actions like creating a permanent token or processing a payment. Using this approach, you can have more control over the transaction request. You can pass additional transaction parameters that can't be passed through the EmbeddedMethod configuration without expanding your PCI scope. This approach also provides flexibility for you to implement solutions for different use cases, like: * Allowing the customer to choose whether to save the payment method permanently or not by presenting a checkbox in your UI. * Displaying payment status or results to the customer after processing the payment via API. * Handling errors that occur during the API calls. * Using split funding functionality. * Incorporating idempotency and timeout handling. This workflow has two main steps: Use a component to generate a one-time use payment token. Use the payment token in a request to make the token permanent or process a transaction (or both). Temporary token flow from user to API with three processing options

Diagram: Temporary Token Flow Process

This diagram shows the complete flow for using temporary tokens with embedded components:

  1. User interacts with your app
  2. Your app configures embedded component with `temporaryToken` set to true
  3. Embedded component returns temporary token to your app
  4. Your app uses temporary token with Payabli API in one of three ways:
    • Option 1: Create permanent token via TokenStorage/Add endpoint
    • Option 2: Process payment via MoneyIn/GetPaid endpoint
    • Option 3: Process payment and create permanent token simultaneously via MoneyIn/GetPaid with saveIfSuccess parameter set to true
  5. App sends response to user

This approach allows complete control over transaction parameters without expanding PCI scope, combining the security of embedded components with API flexibility.

## Generate a temporary token The first step is to use the PayMethod UI or EmbeddedMethod UI embedded component to create a temporary token. Choose a component based on the experience you prefer: the PayMethod UI opens in a modal, and the EmbeddedMethod UI displays inline on the page. Whichever component you choose must be configured to create a temporary payment token, by setting `temporaryToken` to `true`. ```js PayMethod UI config example var payabliConfig0 = { type: "methodLightbox", rootContainer: "pay-component-1", defaultOpen: 'card', buttonLabelInModal: 'Save Payment Method', hideComponent: false, token: "YOUR_API_TOKEN", temporaryToken: true, // Set the token to be temporary customCssUrl: 'www.example.com/mycssfile.css', // other configuration options }; ``` ```js EmbeddedMethod UI config example var payabliConfig0 = { type: "methodEmbedded", rootContainer: "pay-component-1", defaultOpen: 'card', hideComponent: false, token: "YOUR_API_TOKEN", temporaryToken: true, // Set the token to be temporary customCssUrl: "www.example.com/mycssfile.css", // other configuration options }; ``` For full configuration options and examples, see [EmbeddedMethod UI Configuration Reference](/guides/pay-in-components-embeddedmethod-ui#configuration-reference) and [PayMethod UI Configuration Reference](/guides/pay-in-components-paymethod-ui#configuration-reference). When used, the component returns the temporary payment token in the response as `referenceId`. For example: ```json Example response response.responseText: "Success" response.responseData {"referenceId":"30e7658e-5c2c-4638-8308-b48edec0718b-1647","resultCode":1,"resultText":"Added","customerId":1647} ``` The response looks the same when saving a payment method with either component. ## Use the temporary token After you get the temporary token from the component, you have different options for using it. You can convert it to a permanent token, process a payment, or process a payment and save the token. The payment token is passed as `tokenId` only in requests to the `TokenStorage` endpoints. If you are using a payment token to make a transaction with a `MoneyIn` endpoint, it's passed as `storedMethodId`. Pay close attention when working with these code examples. ### Option 1: Create a permanent token To convert the temporary token returned by the component to a permanent one, make a request to the `TokenStorage/Add` endpoint, passing the temporary token with `tokenId`. ```bash Convert a temporary token to permanent curl --request POST \ --url https://api-sandbox.payabli.com/api/TokenStorage/add?temporary=false \ --header 'accept: application/json' \ --header 'content-type: application/*+json' \ --header 'requestToken: ' \ --header 'idempotencyKey: 6B29FC40-CA47-1067-B31D-00DD010662DA' \ --data ' { "paymentMethod": { "method": "card", "tokenId": "c9700e93-b2ed-4b75-b1e4-ca4fb04fbe45-224" }, "customerData": { "customerId": 0, "firstName": "John", "lastName": "Doe", "company": "Sunshine LLC", "customerNumber": "3456-7645A", "billingAddress1": "123 Main Street", "billingCity": "Johnson City", "billingState": "TN", "billingZip": "37612", }, "entryPoint": "mypaypoint", "source": "web", "methodDescription": "Main card", "fallbackAuth": true, } ' ``` A successful request returns a 200 response with a JSON body. The value in "ReferenceId" is both the `storedMethodId` for transactions, and the `methodId` for managing the payment method. ```json Success response example { "isSuccess": true, "responseText": "Success", "responseData": { "ReferenceId": "32-8877drt65345632-678", "ResultCode": 1, "ResultText": "Approved", "CustomerId": 0 } } ``` Include `fallbackAuth` to prevent problems with processors that can't use a zero dollar authorization. ### Option 2: Process a payment To process a one-time payment, call `MoneyIn/GetPaid` endpoint and pass the temporary token as `storedMethodId` along with other parameters, such as `OrderID` and `idempotencyKey`. Make a payment with a saved payment method ```bash Make a payment with a saved payment method curl --request POST \ --url https://api-sandbox.payabli.com/api/MoneyIn/getpaid \ --header 'Content-Type: application/json' \ --header 'idempotencyKey: bf21c30673244141b39d81d73a42613d' \ --header 'requestToken: ' \ --data '{ "paymentMethod": { "method": "card", "storedMethodId": "f4ee4209bbc347248dbc97ab09f17820" }, "orderId": "1009-WEB", "entryPoint": "47a9s3e200o", "paymentDetails": { "totalAmount": 129.35, "serviceFee": 0 }, "customerData": { "customerId": 253, "firstName": "Rachel", "lastName": "Borodino", "customerNumber": "12345679" } }' ``` This is just like processing a transaction with any other payment method. See [Make a Sale Transaction](/guides/pay-in-developer-transactions-create) for more information and example requests and responses. ### Option 3: Process a payment and create a permanent token Use the `saveIfSuccess` parameter when calling `MoneyIn/GetPaid`, to process a payment and generate a permanent payment method token in a single API call. ```bash Process a payment and create a permanent token curl --request POST \ --url https://api-sandbox.payabli.com/api/MoneyIn/getpaid \ --header 'Content-Type: application/json' \ --header 'idempotencyKey: bf21c30673244141b39d81d73a42613d' \ --header 'requestToken: ' \ --data '{ "paymentMethod": { "method": "card", "storedMethodId": "728e2ba3-5526-4fe6-ac14-59c438beb436-0", "saveIfSuccess": true }, "orderId": "1009-WEB", "entryPoint": "47a9s3e200o", "paymentDetails": { "totalAmount": 129.35, "serviceFee": 0 }, "customerData": { "customerId": 253, "firstName": "Rachel", "lastName": "Borodino", "customerNumber": "12345679" } }' ``` You should expect to see a response like the following: ```json { "responseText": "Success", "isSuccess": true, "pageIdentifier": null, "responseData": { "authCode": "123456", "referenceId": "227-d30f8a47ddaf4fa989016d21d08000abd", "resultCode": 1, "resultText": "Approved", "avsResponseText": "No address or ZIP match only", "cvvResponseText": "CVV2/CVC2 no match", "customerId": 1409, "methodReferenceId": "1ed73dfa-3c67-4076-8f8c-9f26317993ed" } } ``` The transaction's ID is returned as `referenceId`, and the saved payment method ID is `methodReferenceId`. ## Disable customer creation When using the temporary token flow, you can prevent the embedded component from creating a customer record and associating the temporary token with it by setting `forceCustomerCreation` to `false` in the config. When the temporary token is converted to a permanent token or used to process a payment, the customer record is then associated with the token or transaction at that time. This is useful when you want to anonymously save a payment method and then associate it with a customer record later. ```js var payabliConfig0 = { type: "methodEmbedded", rootContainer: "pay-component-1", defaultOpen: 'card', token: "YOUR_API_TOKEN", temporaryToken: true, // Use temporary token flow forceCustomerCreation: false, // Disable customer creation // other configuration options // no customerData object is passed }; ``` You should expect to see a response like this: ```json { "responseText": "Success", "isSuccess": true, "pageIdentifier": "t.VL...qza72w=", "responseData": { "referenceId": "23b0775b-9b7e-4576-98b8-c791d052b714-0" // temp token, "resultCode": 1, "resultText": "Added", "customerId": null, "methodReferenceId": "23b0775b-9b7e-4576-98b8-c791d052b714-0" } } ``` The `customerId` field is `null` in the response because the config didn't contain a `customerData` object. You can then use the temporary token to create a permanent token or process a payment, and the customer record will be associated with the token or transaction at that time. ```bash Convert a temporary token to permanent curl --request POST \ --url https://api-sandbox.payabli.com/api/TokenStorage/add?temporary=false \ --header 'accept: application/json' \ --header 'content-type: application/*+json' \ --header 'requestToken: ' \ --header 'idempotencyKey: 6B29FC40-CA47-1067-B31D-00DD010662DA' \ --data ' { "paymentMethod": { "method": "card", "tokenId": "23b0775b-9b7e-4576-98b8-c791d052b714-0" }, "customerData": { "customerId": 0, "firstName": "John", "lastName": "Doe", "company": "Sunshine LLC", "customerNumber": "3456-7645A", "billingAddress1": "123 Main Street", "billingCity": "Johnson City", "billingState": "TN", "billingZip": "37612", }, "entryPoint": "mypaypoint", "source": "web", "methodDescription": "Main card", "fallbackAuth": true, } ' ``` ```bash Make a payment with a saved payment method curl --request POST \ --url https://api-sandbox.payabli.com/api/MoneyIn/getpaid \ --header 'Content-Type: application/json' \ --header 'idempotencyKey: bf21c30673244141b39d81d73a42613d' \ --header 'requestToken: ' \ --data '{ "paymentMethod": { "method": "card", "storedMethodId": "23b0775b-9b7e-4576-98b8-c791d052b714-0" }, "orderId": "1009-WEB", "entryPoint": "47a9s3e200o", "paymentDetails": { "totalAmount": 129.35, "serviceFee": 0 }, "customerData": { "customerId": 253, "firstName": "Rachel", "lastName": "Borodino", "customerNumber": "12345679" } }' ``` ```bash Process a payment and create a permanent token curl --request POST \ --url https://api-sandbox.payabli.com/api/MoneyIn/getpaid \ --header 'Content-Type: application/json' \ --header 'idempotencyKey: bf21c30673244141b39d81d73a42613d' \ --header 'requestToken: ' \ --data '{ "paymentMethod": { "method": "card", "storedMethodId": "23b0775b-9b7e-4576-98b8-c791d052b714-0", "saveIfSuccess": true }, "orderId": "1009-WEB", "entryPoint": "47a9s3e200o", "paymentDetails": { "totalAmount": 129.35, "serviceFee": 0 }, "customerData": { "customerId": 253, "firstName": "Rachel", "lastName": "Borodino", "customerNumber": "12345679" } }' ``` ## Example app This section covers setting up a demo app that uses the [EmbeddedMethod UI](/guides/pay-in-components-embeddedmethod-ui) and custom API calls to drive the [temporary token flow](/guides/platform-developer-tokenization-temp-flow). The demo app walks the user through a checkout experience with an interactive guide that updates while the transaction processes. Visit the [repository](https://github.com/payabli/examples/tree/main/temp-token) to see the code. screenshot of the demo app running ### Dependencies Before you begin, make sure you have the following installed on your machine: * [npm](https://nodejs.org/en/download/) * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) ### Set up the app Run these commands in your terminal to configure the demo app on your local machine: ```bash git clone https://github.com/payabli/examples ``` ```bash cd examples/temp-token ``` ```bash npm install ``` ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_API_TOKEN` to your Payabli API token and `PAYABLI_API_PAYPOINT` to your Payabli API paypoint: ```txt # your Payabli API token PAYABLI_API_TOKEN="123...XYZ" # your Payabli API paypoint PAYABLI_API_PAYPOINT="123...XYZ" ``` ```bash npm run dev ``` ### Use the app The app is a single-page application with a sidebar that contains an interactive guide. When you click the "Confirm order" button to complete the checkout, the state of the transaction will update the sidebar guide. Inside of the guide, there are example code snippets that you can copy and paste to help you get started using the temporary token flow in your own applications. The app has two ways to toggle the sidebar: * Click the button on the bottom-left (desktop) or bottom-right (mobile) of the screen with a book icon. * Press the `Ctrl + K` key combination on your keyboard (desktop only). ## Related resources See these related resources to help you get the most out of Payabli. * **[Payment method tokenization](/guides/platform-tokenization-overview)** - Learn how payment method tokenization secures sensitive data and enhances security for your payments * **[Temporary token example app (for developers)](/guides/platform-tokenization-temp-token-app)** - Go through a guided checkout experience using the temporary token flow * **[EmbeddedMethod UI](/guides/pay-in-components-embeddedmethod-ui)** - Learn how to use the EmbeddedMethod UI embedded component to add the ability to securely store a payment profile or execute a sale * **[PayMethod UI](/guides/pay-in-components-paymethod-ui)** - Learn how to use the PayMethod UI embedded component to securely store a payment profile with a low-code modal-based UI. *** title: Temporary token example app (for developers) subtitle: Go through a guided checkout experience using the temporary token flow description: >- Walk through a guided checkout using the temporary token flow example app. See how client-side tokenization and server-side payment processing work together 'og:description': >- Walk through a guided checkout using the temporary token flow example app. See how client-side tokenization and server-side payment processing work together keywords: >- embedded payments, temporary token, example app, checkout flow, client-side tokenization, payment integration, developer quickstart slug: guides/platform-tokenization-temp-token-app icon: cash-register area: * Pay In subArea: * Tokenization * Components audience: * developers *** This guide covers setting up a demo app that uses the [EmbeddedMethod UI](/guides/pay-in-components-embeddedmethod-ui) and custom API calls to drive the [temporary token flow](/guides/platform-developer-tokenization-temp-flow). The demo app walks the user through a checkout experience with an interactive guide that updates while the transaction processes. Visit the [repository](https://github.com/payabli/examples/tree/main/temp-token) to see the code. screenshot of the demo app running ## Dependencies Before you begin, make sure you have the following installed on your machine: * [npm](https://nodejs.org/en/download/) * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) ## Set up the app Run these commands in your terminal to configure the demo app on your local machine: ```bash git clone https://github.com/payabli/examples ``` ```bash cd examples/temp-token ``` ```bash npm install ``` ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_API_TOKEN` to your Payabli API token and `PAYABLI_API_PAYPOINT` to your Payabli API paypoint: ```txt # your Payabli API token PAYABLI_API_TOKEN="123...XYZ" # your Payabli API paypoint PAYABLI_API_PAYPOINT="123...XYZ" ``` ```bash npm run dev ``` ## Use the app The app is a single-page application with a sidebar that contains an interactive guide. When you click the "Confirm order" button to complete the checkout, the state of the transaction will update the sidebar guide. Inside of the guide, there are example code snippets that you can copy and paste to help you get started using the temporary token flow in your own applications. The app has two ways to toggle the sidebar: * Click the button on the bottom-left (desktop) or bottom-right (mobile) of the screen with a book icon. * Press the `Ctrl + K` key combination on your keyboard (desktop only). *** title: Embedded components framework integrations subtitle: >- Learn how to use Payabli's embedded components with front-end frameworks like React and Vue description: >- Integrate embedded components with React, Vue, and other JavaScript frameworks. Follow framework-specific setup guides to add payment UI to your application 'og:description': >- Integrate embedded components with React, Vue, and other JavaScript frameworks. Follow framework-specific setup guides to add payment UI to your application keywords: >- embedded payments, React payments, Vue payments, framework integration, embedded components, frontend payments, JavaScript payments icon: brands react slug: guides/pay-in-developer-components-frameworks area: * Pay In subArea: * Components audience: * developers *** You can use Payabli's embedded components in a React or Vue application following the same configuration patterns as in a vanilla JavaScript application. ## React Visit the [React Integration Example](https://github.com/payabli/examples/tree/main/react-integration) to see Payabli's embedded components in a React application. ### Step 1: Create the hook Create a hook that allows you to use the embedded component and execute its methods. The hook needs to inject the Payabli library script and initialize the embedded component with the provided configuration. Make a new file for the `usePayabli` hook and add the following code: ```ts TypeScript // usePayabli.ts import { useState, useEffect, useRef, useCallback } from "react"; const useScript = (src: string) => { const [isLoaded, setIsLoaded] = useState(false); useEffect(() => { const existingScript = document.querySelector(`script[src="${src}"]`); const onLoad = () => { setIsLoaded(true); }; if (!existingScript) { const script = document.createElement("script"); script.src = src; script.async = true; script.addEventListener("load", onLoad); document.body.appendChild(script); return () => { script.removeEventListener("load", onLoad); document.body.removeChild(script); }; } else { if (existingScript.getAttribute("data-loaded") === "true") { setIsLoaded(true); } else { existingScript.addEventListener("load", onLoad); } } }, [src]); return isLoaded; }; declare var PayabliComponent: any; export const usePayabli = ( options: any, method: string, parameters: any = null, production: boolean = false ) => { const [payOptions, setPayOptions] = useState(options); const [isInitialized, setIsInitialized] = useState(false); const payComponentRef = useRef(null); const initCallbacks = useRef<(() => void)[]>([]); // Queue for functions waiting on initialization const scriptSrc = production ? "https://embedded-component.payabli.com/component.js" : "https://embedded-component-sandbox.payabli.com/component.js"; const isScriptLoaded = useScript(scriptSrc); useEffect(() => { if (isScriptLoaded) { payComponentRef.current = new PayabliComponent(payOptions); setIsInitialized(true); // payabliExecute queued callbacks initCallbacks.current.forEach((cb) => cb()); initCallbacks.current = []; // Clear the queue } }, [isScriptLoaded, payOptions]); useEffect(() => { if (isInitialized && payComponentRef.current) { payComponentRef.current.updateConfig(payOptions); } }, [isInitialized, payOptions]); const payabliReinit = useCallback(() => { if (isInitialized && payComponentRef.current) { payComponentRef.current.payabliExec("reinit"); } }, [isInitialized]); const payabliExec = useCallback(() => { const payabliExecuteMethod = () => { if (parameters != null) { payComponentRef.current.payabliExec(method, parameters); } else { payComponentRef.current.payabliExec(method); } }; if (isInitialized && payComponentRef.current) { payabliExecuteMethod(); } else { initCallbacks.current.push(payabliExecuteMethod); // Queue the payabliExecution } }, [isInitialized, method, parameters]); return [payOptions, setPayOptions, payabliExec, payabliReinit]; }; ``` ```js JavaScript // usePayabli.js import { useState, useEffect, useRef, useCallback } from "react"; const useScript = (src) => { const [isLoaded, setIsLoaded] = useState(false); useEffect(() => { const existingScript = document.querySelector(`script[src="${src}"]`); const onLoad = () => { setIsLoaded(true); }; if (!existingScript) { const script = document.createElement("script"); script.src = src; script.async = true; script.addEventListener("load", onLoad); document.body.appendChild(script); return () => { script.removeEventListener("load", onLoad); document.body.removeChild(script); }; } else { if (existingScript.getAttribute("data-loaded") === "true") { setIsLoaded(true); } else { existingScript.addEventListener("load", onLoad); } } }, [src]); return isLoaded; }; export const usePayabli = ( options, method, parameters = null, production = false ) => { const [payOptions, setPayOptions] = useState(options); const [isInitialized, setIsInitialized] = useState(false); const payComponentRef = useRef(null); const initCallbacks = useRef([]); // Queue for functions waiting on initialization const scriptSrc = production ? "https://embedded-component.payabli.com/component.js" : "https://embedded-component-sandbox.payabli.com/component.js"; const isScriptLoaded = useScript(scriptSrc); useEffect(() => { if (isScriptLoaded) { payComponentRef.current = new PayabliComponent(payOptions); setIsInitialized(true); // Execute queued callbacks initCallbacks.current.forEach((cb) => cb()); initCallbacks.current = []; // Clear the queue } }, [isScriptLoaded, payOptions]); useEffect(() => { if (isInitialized && payComponentRef.current) { payComponentRef.current.updateConfig(payOptions); } }, [isInitialized, payOptions]); const payabliReinit = useCallback(() => { if (isInitialized && payComponentRef.current) { payComponentRef.current.payabliExec("reinit"); } }, [isInitialized]); const payabliExec = useCallback(() => { const payabliExecuteMethod = () => { if (parameters != null) { payComponentRef.current[method](parameters); } else { payComponentRef.current[method](); } }; if (isInitialized && payComponentRef.current) { payabliExecuteMethod(); } else { initCallbacks.current.push(payabliExecuteMethod); // Queue the execution } }, [isInitialized, method, parameters]); return [payOptions, setPayOptions, payabliExec, payabliReinit]; }; ``` ### Step 2: Create the component Create a new `PayabliCheckout` component that passes in the configuration object for the embedded component to the `usePayabli` hook. The `PayabliCheckout` component uses the `payabliExec` function to execute the embedded component's method. Create a new file in the same directory and add the following code: There are multiple types of embedded components with different use cases. See the [Embedded Components Overview](/guides/pay-in-components-overview#choose-a-component) to decide which component type is best for you. ```tsx TSX // PayabliCheckout.tsx import { usePayabli } from './usePayabli'; export const PayabliCheckout = () => { const token = "o.z8j8aaztW9tUtUg4d.." const entryPoint = "bozeman-aikido" const rootContainer = "pay-component-1" const payabliButton = "btnx" const [payabliConfig, setPayabliConfig, payabliExec] = usePayabli({ type: "methodEmbedded", rootContainer: rootContainer, defaultOpen: 'card', // offering only Card method - Embedded UI can only show a payment method // customCssUrl: "your url to a custom css file", token: token, entryPoint: entryPoint, card: { enabled: true, amex: true, discover: true, visa: true, mastercard: true, jcb: true, diners: true, inputs: { // here we are customizing the input fields cardHolderName: { label: "NAME ON CARD", placeholder: "", floating: false, value: "John Doe", size: 12, row: 0, order: 0 }, cardNumber: { label: "CARD NUMBER", placeholder: "1234 1234 1234 1234", floating: false, size: 6, row: 1, order: 0 }, cardExpirationDate: { label: "EXPIRATION DATE", placeholder: "MM/YY", floating: false, size: 6, row: 1, order: 1 }, cardCvv: { label: "CVV/CVC", placeholder: "CVV/CVC", floating: false, size: 6, row: 2, order: 0, }, cardZipcode: { label: "ZIP/POSTAL CODE", placeholder: "ZIP/POSTAL CODE", floating: false, size: 6, row: 2, order: 1, country: ["us", "ca"], } } }, ach: { enabled: false, checking: true, savings: true }, customerData: { customerNumber: "00001", firstName: "John", lastName: "Doe", billingEmail: "johndoe@email.com" }, functionCallBackSuccess: (response: any) => { const containerEl = document.getElementById(rootContainer); const responseText = JSON.stringify(response.responseText); const responseData = JSON.stringify(response.responseData); alert(responseText + " " + responseData); containerEl!.innerHTML += `

Embedded Component Response:

${responseText}

${responseData}


`; }, functionCallBackReady: (data: any) => { var btn = document.getElementById(payabliButton); if (data[1] === true) { btn!.classList.remove("hidden"); } else { if (!btn!.classList.contains("hidden")) { btn!.classList.add("hidden"); } } }, functionCallBackError: (errors: any) => { alert('Error!'); console.log(errors); } }, "pay", { paymentDetails: { totalAmount: 100, serviceFee: 0, categories: [ { label: "payment", amount: 100, qty: 1, }, ], }, }) return (
) } ``` ```jsx JSX // PayabliCheckout.jsx import { usePayabli } from './usePayabli'; export const PayabliCheckout = () => { const token = "o.z8j8aaztW9tUtUg4d.." const entryPoint = "bozeman-aikido" const rootContainer = "pay-component-1" const payabliButton = "btnx" const [payabliConfig, setPayabliConfig, payabliExec] = usePayabli({ type: "methodEmbedded", rootContainer: rootContainer, defaultOpen: 'card', // offering only Card method - Embedded UI can only show a payment method // customCssUrl: "your url to a custom css file", token: token, entryPoint: entryPoint, card: { enabled: true, amex: true, discover: true, visa: true, mastercard: true, jcb: true, diners: true, inputs: { // here we are customizing the input fields cardHolderName: { label: "NAME ON CARD", placeholder: "", floating: false, value: "John Doe", size: 12, row: 0, order: 0 }, cardNumber: { label: "CARD NUMBER", placeholder: "1234 1234 1234 1234", floating: false, size: 6, row: 1, order: 0 }, cardExpirationDate: { label: "EXPIRATION DATE", placeholder: "MM/YY", floating: false, size: 6, row: 1, order: 1 }, cardCvv: { label: "CVV/CVC", placeholder: "CVV/CVC", floating: false, size: 6, row: 2, order: 0, }, cardZipcode: { label: "ZIP/POSTAL CODE", placeholder: "ZIP/POSTAL CODE", floating: false, size: 6, row: 2, order: 1, country: ["us", "ca"], } } }, ach: { enabled: false, checking: true, savings: true }, customerData: { customerNumber: "00001", firstName: "John", lastName: "Doe", billingEmail: "johndoe@email.com" }, functionCallBackSuccess: (response) => { const containerEl = document.getElementById(rootContainer); const responseText = JSON.stringify(response.responseText); const responseData = JSON.stringify(response.responseData); alert(responseText + " " + responseData); containerEl.innerHTML += `

Embedded Component Response:

${responseText}

${responseData}


`; }, functionCallBackReady: (data) => { var btn = document.getElementById(payabliButton); if (data[1] === true) { btn.classList.remove("hidden"); } else { if (!btn.classList.contains("hidden")) { btn.classList.add("hidden"); } } }, functionCallBackError: (errors) => { alert('Error!'); console.log(errors); } }, "pay", { paymentDetails: { totalAmount: 100, serviceFee: 0, categories: [ { label: "payment", amount: 100, qty: 1, }, ], }, }) return (
) } ```
```tsx TSX // PayabliCheckout.tsx import { usePayabli } from './usePayabli.ts'; export const PayabliCheckout = () => { const token = "o.z8j8aaztW9tUtUg4d.." const entryPoint = "bozeman-aikido" const [payabliConfig, setPayabliConfig, payabliExec, payabliReinit] = usePayabli({ type: "methodLightbox", rootContainer: "pay-component-1", buttonLabelInModal: 'Save Payment Method', defaultOpen: 'ach', hideComponent: true, token: token, entryPoint: entryPoint, card: { enabled: true, amex: true, discover: true, visa: true, mastercard: true, jcb: true, diners: true }, ach: { enabled: true, checking: true, savings: false }, customerData: { customerNumber: "00001", firstName: "John", lastName: "Doe", billingEmail: "johndoe@email.com" }, functionCallBackSuccess: (response: any) => { // This callback covers both 2XX and 4XX responses console.log(response); switch (response.responseText) { case "Success": // Tokenization was successful alert(`Success: ${response.responseData.resultText}`); break; case "Declined": // Tokenization failed due to processor decline or validation errors // Recommend reinitialization of the component so that the user can try again // with different card data alert(`Declined: ${response.responseData.resultText}`); payabliReinit() break; default: // Other response text. These are normally errors with Payabli internal validations // before processor engagement // We recommend reinitializing the component. // If the problem persists, contact Payabli to help debug alert(`Error: ${response.responseText}`); payabliReinit() break; } }, functionCallBackError: (errors: any) => { // This callback covers 5XX response or parsing errors // We recommend reinitializing the component. // If the problem persists, contact Payabli to help debug console.log(errors); payabliReinit() } }, "pay", { paymentDetails: { totalAmount: 100, serviceFee: 0, categories: [ { label: "payment", amount: 100, qty: 1, }, ], }, }) return (
) } ``` ```jsx JSX // PayabliCheckout.jsx import { usePayabli } from './usePayabli.js'; export const PayabliCheckout = () => { const token = "o.z8j8aaztW9tUtUg4d.." const entryPoint = "bozeman-aikido" const [payabliConfig, setPayabliConfig, payabliExec, payabliReinit] = usePayabli({ type: "methodLightbox", rootContainer: "pay-component-1", buttonLabelInModal: 'Save Payment Method', defaultOpen: 'ach', hideComponent: true, token: token, entryPoint: entryPoint, card: { enabled: true, amex: true, discover: true, visa: true, mastercard: true, jcb: true, diners: true }, ach: { enabled: true, checking: true, savings: false }, customerData: { customerNumber: "00001", firstName: "John", lastName: "Doe", billingEmail: "johndoe@email.com" }, functionCallBackSuccess: (response) => { // This callback covers both 2XX and 4XX responses console.log(response); switch (response.responseText) { case "Success": // Tokenization was successful alert(`Success: ${response.responseData.resultText}`); break; case "Declined": // Tokenization failed due to processor decline or validation errors // Recommend reinitialization of the component so that the user can try again // with different card data alert(`Declined: ${response.responseData.resultText}`); payabliReinit() break; default: // Other response text. These are normally errors with Payabli internal validations // before processor engagement // We recommend reinitializing the component. // If the problem persists, contact Payabli to help debug alert(`Error: ${response.responseText}`); payabliReinit() break; } }, functionCallBackError: (errors) => { // This callback covers 5XX response or parsing errors // We recommend reinitializing the component. // If the problem persists, contact Payabli to help debug console.log(errors); payabliReinit() } }, "pay", { paymentDetails: { totalAmount: 100, serviceFee: 0, categories: [ { label: "payment", amount: 100, qty: 1, }, ], }, }) return (
) } ```
### Types The hook receives the following arguments: The configuration object for the embedded component. See the [configuration reference](/guides/pay-in-components-embeddedmethod-ui#configuration-reference) for the component type you are using. The method to execute in `payabliExec`. See the [field](/guides/pay-in-components-overview#param-payabli-exec-action-parameters) for more information. An optional object that contains objects to pass to the `method`. See the [`paymentMethod`](/guides/pay-in-components-embeddedmethod-ui#param-payment-method), [`paymentDetails`](/guides/pay-in-components-embeddedmethod-ui#param-payment-details), or [`customerData`](/guides/pay-in-components-embeddedmethod-ui#param-customer-data) objects for more information. A boolean value that determines whether to use the production or sandbox environment. The hook returns an array with the following elements: The configuration object for the embedded component. See the [configuration reference](/guides/pay-in-components-embeddedmethod-ui#configuration-reference) for the component type you are using. A function to update the configuration object for the embedded component. This allows you to dynamically change the options after initialization. A function to execute the embedded component's method. This will call the method specified in the `method` argument passed to the hook. A function to reinitialize the embedded component. ## Vue Visit the [Vue integration example](https://github.com/payabli/examples/tree/main/vue-integration) to see Payabli's embedded components in a Vue application. ### Step 1: Create the composable Create a composable that allows you to use the embedded component and execute its methods. The composable needs to inject the Payabli library script and initialize the embedded component with the provided configuration. Make a new file for the `usePayabli` composable and add the following code: ```ts TypeScript // usePayabli.ts import { ref, reactive, onMounted, watchEffect } from 'vue'; const loadedScripts = new Set(); const useScript = (src: string) => { const isLoaded = ref(false); onMounted(() => { if (loadedScripts.has(src)) { isLoaded.value = true; return; } const existingScript = document.querySelector(`script[src="${src}"]`); const handleLoad = () => { loadedScripts.add(src); isLoaded.value = true; script.setAttribute("data-loaded", "true"); }; let script: HTMLScriptElement; if (!existingScript) { script = document.createElement("script"); script.src = src; script.async = true; script.addEventListener("load", handleLoad); document.body.appendChild(script); } else { if (existingScript.getAttribute("data-loaded") === "true") { isLoaded.value = true; } else { existingScript.addEventListener("load", handleLoad); } } }); return isLoaded; }; declare var PayabliComponent: any; export const usePayabli = ( options: any, method: string, parameters: any = null, production = false ) => { const payOptions = reactive({ ...options }); const isInitialized = ref(false); const payComponentRef = ref(null); const initCallbacks: (() => void)[] = []; const scriptSrc = production ? "https://embedded-component.payabli.com/component.js" : "https://embedded-component-sandbox.payabli.com/component.js"; const isScriptLoaded = useScript(scriptSrc); const initPayabli = () => { if (!isScriptLoaded.value || isInitialized.value) return; payComponentRef.value = new PayabliComponent(payOptions); isInitialized.value = true; initCallbacks.splice(0).forEach(cb => cb()); }; watchEffect(() => { if (isScriptLoaded.value) { initPayabli(); } }); watchEffect(() => { if (isInitialized.value && payComponentRef.value) { payComponentRef.value.updateConfig(payOptions); } }); const payabliReinit = () => { if (isInitialized.value && payComponentRef.value) { payComponentRef.value.payabliExec("reinit"); } }; const payabliExec = () => { const exec = () => { if (!payComponentRef.value) return; if (payOptions.type === "methodEmbedded") { if (parameters != null) { payComponentRef.value.payabliExec(method, parameters); } else { payComponentRef.value.payabliExec(method); } } else if ( payOptions.type === "methodLightbox" || payOptions.type === "vterminal" ) { payComponentRef.value.showModal(); } }; if (isInitialized.value) { exec(); } else { initCallbacks.push(exec); } }; return [payOptions, payabliExec, payabliReinit] as const; }; ``` ### Step 2: Create the component Create a new `PayabliCheckout` component that passes in the configuration object for the embedded component to the `usePayabli` composable. The `PayabliCheckout` component uses the `payabliExec` function to execute the embedded component's method. Create a new file in the same directory and add the following code: ```vue Vue ``` ### Types The composable receives the following arguments: The configuration object for the embedded component. See the [configuration reference](/guides/pay-in-components-embeddedmethod-ui#configuration-reference) for the component type you are using. The method to execute in `payabliExec`. See the [field](/guides/pay-in-components-overview#param-payabli-exec-action-parameters) for more information. An optional object that contains objects to pass to the `method`. See the [`paymentMethod`](/guides/pay-in-components-embeddedmethod-ui#param-payment-method), [`paymentDetails`](/guides/pay-in-components-embeddedmethod-ui#param-payment-details), or [`customerData`](/guides/pay-in-components-embeddedmethod-ui#param-customer-data) objects for more information. A boolean value that determines whether to use the production or sandbox environment. The composable returns an array with the following elements: The configuration object for the embedded component. See the [configuration reference](/guides/pay-in-components-embeddedmethod-ui#configuration-reference) for the component type you are using. A function to execute the embedded component's method. This will call the method specified in the `method` argument passed to the hook. A function to reinitialize the embedded component. ## Related resources See these related resources to help you get the most out of Payabli. * **[Embedded components overview](/guides/pay-in-components-overview)** - Learn how to use Payabli's embedded components to create customized checkout experiences without handling sensitive payment information yourself * **[EmbeddedMethod UI](/guides/pay-in-components-embeddedmethod-ui)** - Learn how to use the EmbeddedMethod UI embedded component to add the ability to securely store a payment profile or execute a sale *** title: Use the TypeScript SDK subtitle: Learn how to install and use the TypeScript SDK to develop apps description: >- Install and configure the Payabli TypeScript SDK to process payments, manage payouts, and handle boarding in your Node.js applications with type-safe methods 'og:description': >- Install and configure the Payabli TypeScript SDK to process payments, manage payouts, and handle boarding in your Node.js applications with type-safe methods keywords: >- embedded payments, TypeScript SDK, payment API, SDK integration, developer tools, payment processing, Node.js payments slug: developers/platform-sdk-typescript-guide icon: brands node-js area: * Pay In * Pay Out * Pay Ops * Developer Tools * SDKs audience: * developers *** Payabli offers a Software Development Kit (SDK) for the TypeScript programming language. The TypeScript SDK can be installed in your projects to support app development and provide type safety when calling Payabli's APIs. Most development environments can use the SDK to generate code suggestions and inline documentation. See the [`@payabli/sdk-node`](https://www.npmjs.com/package/@payabli/sdk-node) package for more information. ## Dependencies Before you begin, make sure you have the following installed on your machine: * [npm](https://nodejs.org/en/download/) * [tsx](https://www.npmjs.com/package/tsx) * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) ## Use the SDK This section shows you how to install and use the Payabli SDK in a new Node.js project. The example code shows how to use the SDK to make a transaction with the `moneyIn.getpaid` method. The `moneyIn.getpaid` method calls the [MoneyIn/getpaid](/developers/api-reference/moneyin/make-a-transaction) endpoint. See the [SDK reference](https://github.com/payabli/sdk-node/blob/main/reference.md) for a full list of methods. Method names in the SDK correspond to endpoint names in the API reference. For example: the `notification.addNotification` method calls the [POST Notification](/developers/api-reference/notification/add-notification) endpoint. Open your terminal and run the following commands to create a new Node.js project: ```bash mkdir my-payabli-app cd my-payabli-app npm init -y ``` Open the `package.json` file in your code editor and set the `"type"` field to `"module"`: ```json { "type": "module" } ``` Run the following command to install the Payabli SDK: ```bash npm install @payabli/sdk-node ``` Create a new file called `index.ts` in the root of your `my-payabli-app` directory: ```bash touch index.ts ``` Open the `index.ts` file in your code editor.
/// Import the client Import the Payabli SDK to make it available in your code. ```typescript // index.ts import { PayabliClient } from '@payabli/sdk-node'; ``` /// Initialize the client Create an authenticated client instance with your API key. This client has methods that call Payabli's API endpoints. ```typescript focus=4 // index.ts import { PayabliClient } from '@payabli/sdk-node'; const client = new PayabliClient({ apiKey: "REPLACE_WITH_YOUR_API_KEY" }); ``` /// Define the entrypoint Define your entrypoint. Get this value from your Payabli account. ```typescript focus=6 // index.ts import { PayabliClient } from '@payabli/sdk-node'; const client = new PayabliClient({ apiKey: "REPLACE_WITH_YOUR_API_KEY" }); const entryPoint = "REPLACE_WITH_YOUR_ENTRYPOINT"; ``` /// Build the payment request Construct a request object that contains all the necessary fields to process a transaction. Include payment details, a payment method, and customer data. ```typescript focus=8-29 // index.ts import { PayabliClient } from '@payabli/sdk-node'; const client = new PayabliClient({ apiKey: "REPLACE_WITH_YOUR_API_KEY" }); const entryPoint = "REPLACE_WITH_YOUR_ENTRYPOINT"; const request = { body: { customerData: { customerId: 4440, }, entryPoint, ipaddress: "255.255.255.255", paymentDetails: { serviceFee: 0, totalAmount: 100, }, paymentMethod: { cardcvv: "999", cardexp: "02/27", cardHolder: "Kassiane Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", }, }, }; ``` /// Execute the transaction Call `moneyIn.getpaid()` to process the transaction. The client calls Payabli's `POST /MoneyIn/getpaid` endpoint. ```typescript focus=31 // index.ts import { PayabliClient } from '@payabli/sdk-node'; const client = new PayabliClient({ apiKey: "REPLACE_WITH_YOUR_API_KEY" }); const entryPoint = "REPLACE_WITH_YOUR_ENTRYPOINT"; const request = { body: { customerData: { customerId: 4440, }, entryPoint, ipaddress: "255.255.255.255", paymentDetails: { serviceFee: 0, totalAmount: 100, }, paymentMethod: { cardcvv: "999", cardexp: "02/27", cardHolder: "Kassiane Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", }, }, }; const result = await client.moneyIn.getpaid(request); ``` /// Show the result Log the transaction response. Check the output to see if the transaction was successful. ```typescript focus=33 // index.ts import { PayabliClient } from '@payabli/sdk-node'; const client = new PayabliClient({ apiKey: "REPLACE_WITH_YOUR_API_KEY" }); const entryPoint = "REPLACE_WITH_YOUR_ENTRYPOINT"; const request = { body: { customerData: { customerId: 4440, }, entryPoint, ipaddress: "255.255.255.255", paymentDetails: { serviceFee: 0, totalAmount: 100, }, paymentMethod: { cardcvv: "999", cardexp: "02/27", cardHolder: "Kassiane Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card", }, }, }; const result = await client.moneyIn.getpaid(request); console.log(result); ```
Run the app with the following command: ```bash tsx index.ts ``` Check the console output for the result of the transaction. ```js { responseText: "Success", isSuccess: true, pageIdentifier: null, responseData: { authCode: "TAS003", referenceId: "255-67bc92c141e24f474f60c1968fcba0cd", resultCode: 1, resultText: "Approved", avsResponseText: "No Match, No address or ZIP match", cvvResponseText: "CVV2/CVC2 match", customerId: 4440, methodReferenceId: null, }, } ```
In production, we recommend that you pass a stored method ID to the `paymentMethod` object instead of card details. See more information in [Tokenization Overview](/guides/platform-tokenization-overview). ## SDK example app The SDK example app is a basic web app built with the Payabli TypeScript SDK. It demonstrates how to manage customers and use the temporary token flow with the SDK. The code is publicly available in the [example repository](https://github.com/payabli/examples/tree/main/sdk/ts-sdk). customer creation page of SDK example app ### Set up the app Follow these steps to set up the SDK example app on your local machine: Open your terminal and run the following command to clone the SDK example app repository: ```bash git clone https://github.com/payabli/examples ``` In your terminal, navigate to the directory containing the SDK example app: ```bash cd examples/sdk-example ``` Install the dependencies with the following command: ```bash npm install ``` Copy the`.env.template` file to a new file called `.env`: ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_KEY` to a private API token, `PAYABLI_ENTRY` to your Payabli entrypoint, `PUBLIC_PAYABLI_TOKEN` to a public API token, and `PUBLIC_PAYABLI_ENTRY` to your Payabli entrypoint. The entry values should be the same for both public and private, but the API keys are different: ```bash # your Payabli Private API token PAYABLI_KEY="o.Oim...Mekgjw=" # your Payabli Public API token PUBLIC_PAYABLI_TOKEN="o.Oim...Mekgjw=" # your Payabli entrypoint PAYABLI_ENTRY="41xxxxxa7e" # your Payabli entrypoint (same as above) PUBLIC_PAYABLI_ENTRY="41xxxxxa7e" ``` Run this command to start the development server, and open the app in your browser: ```bash npm run dev ``` ### Use the app The SDK example app has three pages: 1. **Create Customer** - Create a new customer in the Payabli entrypoint. 2. **List Customers** - View a list of all customers in the Payabli entrypoint. 3. **Make Transaction** - Make a transaction using the temporary token flow. #### Create customer The **Create Customer** page has a form that allows you to create a new customer. Fill in the form with the customer's information and click the "Create" button. If the customer is created successfully, a green success message appears below the button. #### List customers The **List Customers** page has a table of all customers in the entrypoint. You can view the customer's information, including their name, email address, and ZIP Code. Click the "X" button on the right side of a customer's row to delete the customer. If the customer is deleted successfully, the row is removed from the table. #### Make transaction The **Make Transaction** page contains an EmbeddedMethod UI component using the temporary token flow. Fill in the form with payment information and click the "Process" button when the payment information is valid. The app performs these steps: 1. The embedded component saves the payment method as a temporary token and sends it to the server. 2. The server converts the temporary token to a permanent token with the **POST TokenStorage/add** endpoint. 3. The server uses the permanent token to make a transaction with the **POST MoneyIn/getpaid** endpoint. If everything is successful, a green success message appears below the embedded component. See [Extend embedded components with the temporary token flow](/guides/platform-developer-tokenization-temp-flow) for more information. *** title: Use the C# SDK subtitle: Learn how to install and use the C# SDK to develop apps description: >- Install and configure the Payabli C# SDK to process payments, manage payouts, and automate boarding in your .NET applications with strongly typed client methods 'og:description': >- Install and configure the Payabli C# SDK to process payments, manage payouts, and automate boarding in your .NET applications with strongly typed client methods keywords: >- embedded payments, C# SDK, payment API, SDK integration, developer tools, payment processing, .NET payments slug: developers/platform-sdk-csharp-guide icon: brands microsoft area: * Pay In * Pay Out * Pay Ops * Developer Tools * SDKs audience: * developers *** Payabli offers a Software Development Kit (SDK) for the C# programming language. The C# SDK can be installed in your projects to support app development and provide type safety when calling Payabli's APIs. Most development environments can use the SDK to generate code suggestions and inline documentation. See the [`PayabliApi`](https://www.nuget.org/packages/PayabliApi) package for more information. ## Dependencies Before you begin, make sure you have the following installed on your machine: * [.NET 8.0 SDK](https://dotnet.microsoft.com/download/dotnet/8.0) or later * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) ## Use the SDK This section shows you how to install and use the Payabli SDK in a new .NET project. The example code shows how to use the SDK to make a transaction with the `MoneyIn.GetpaidAsync` method. The `MoneyIn.GetpaidAsync` method calls the [MoneyIn/getpaid](/developers/api-reference/moneyin/make-a-transaction) endpoint. See the [SDK reference](https://github.com/payabli/sdk-csharp) for a full list of methods. Method names in the SDK correspond to endpoint names in the API reference. For example: the `Notification.AddNotificationAsync` method calls the [POST Notification](/developers/api-reference/notification/add-notification) endpoint. Open your terminal and run the following commands to create a new .NET console project: ```bash mkdir MyPayabliApp cd MyPayabliApp dotnet new console ``` Run the following command to install the Payabli SDK: ```bash dotnet add package PayabliApi ``` Open the `Program.cs` file in your code editor and remove the existing code.
/// Import required namespaces Import the Payabli SDK to make it available in your code. ```csharp // Program.cs using PayabliApi; ``` /// Initialize the client Create an authenticated client instance with your API key. This client has methods that call Payabli's API endpoints. ```csharp focus=4 // Program.cs using PayabliApi; var client = new PayabliApiClient("REPLACE_WITH_YOUR_API_KEY"); ``` /// Define the entrypoint Define your entrypoint. Get this value from your Payabli account. ```csharp focus=6 // Program.cs using PayabliApi; var client = new PayabliApiClient("REPLACE_WITH_YOUR_API_KEY"); var entrypoint = "REPLACE_WITH_YOUR_ENTRYPOINT"; ``` /// Build the payment request Construct a request object that contains all the necessary fields to process a transaction. Include payment details, a payment method, and customer data. ```csharp focus=8-32 // Program.cs using PayabliApi; var client = new PayabliApiClient("REPLACE_WITH_YOUR_API_KEY"); var entrypoint = "REPLACE_WITH_YOUR_ENTRYPOINT"; var request = new RequestPayment { Body = new TransRequestBody { CustomerData = new PayorDataRequest { CustomerId = 4440, }, EntryPoint = entrypoint, Ipaddress = "255.255.255.255", PaymentDetails = new PaymentDetail { ServiceFee = 0, TotalAmount = 100, }, PaymentMethod = new PayMethodCredit { Cardcvv = "999", Cardexp = "02/27", CardHolder = "Kassiane Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card", }, }, }; ``` /// Execute the transaction Call `MoneyIn.GetpaidAsync()` to process the transaction. The client calls Payabli's `POST /MoneyIn/getpaid` endpoint. ```csharp focus=36-39 // Program.cs using PayabliApi; var client = new PayabliApiClient("REPLACE_WITH_YOUR_API_KEY"); var entrypoint = "REPLACE_WITH_YOUR_ENTRYPOINT"; var request = new RequestPayment { Body = new TransRequestBody { CustomerData = new PayorDataRequest { CustomerId = 4440, }, EntryPoint = entrypoint, Ipaddress = "255.255.255.255", PaymentDetails = new PaymentDetail { ServiceFee = 0, TotalAmount = 100, }, PaymentMethod = new PayMethodCredit { Cardcvv = "999", Cardexp = "02/27", CardHolder = "Kassiane Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card", }, }, }; var result = await client.MoneyIn.GetpaidAsync(new RequestPayment { Body = request.Body, }); ``` /// Show the result Log the transaction response. Check the output to see if the transaction was successful. ```csharp focus=41-47 // Program.cs using PayabliApi; var client = new PayabliApiClient("REPLACE_WITH_YOUR_API_KEY"); var entrypoint = "REPLACE_WITH_YOUR_ENTRYPOINT"; var request = new RequestPayment { Body = new TransRequestBody { CustomerData = new PayorDataRequest { CustomerId = 4440, }, EntryPoint = entrypoint, Ipaddress = "255.255.255.255", PaymentDetails = new PaymentDetail { ServiceFee = 0, TotalAmount = 100, }, PaymentMethod = new PayMethodCredit { Cardcvv = "999", Cardexp = "02/27", CardHolder = "Kassiane Cassian", Cardnumber = "4111111111111111", Cardzip = "12345", Initiator = "payor", Method = "card", }, }, }; var result = await client.MoneyIn.GetpaidAsync(new RequestPayment { Body = request.Body, }); Console.WriteLine($"Response: {result.ResponseText}"); Console.WriteLine($"Success: {result.IsSuccess}"); if (result.ResponseData != null) { Console.WriteLine($"Reference ID: {result.ResponseData.ReferenceId}"); Console.WriteLine($"Result: {result.ResponseData.ResultText}"); } ```
Run the app with the following command: ```bash dotnet run ``` Check the console output for the result of the transaction. A successful transaction returns output like this: ```txt Response: Success Success: True Reference ID: 255-67bc92c141e24f474f60c1968fcba0cd Result: Approved ```
In production, we recommend that you pass a stored method ID to the `PaymentMethod` object instead of card details. See more information in [Tokenization Overview](/guides/platform-tokenization-overview). ## SDK example app The SDK example app is a basic web app built with the Payabli C# SDK. It demonstrates how to manage customers and use the temporary token flow with the SDK. The code is publicly available in the [example repository](https://github.com/payabli/examples/tree/main/sdk/cs-sdk). customer creation page of SDK example app ### Set up the app Follow these steps to set up the SDK example app on your local machine: Open your terminal and run the following command to clone the SDK example app repository: ```bash git clone https://github.com/payabli/examples ``` In your terminal, navigate to the directory containing the SDK example app: ```bash cd examples/sdk/cs-sdk ``` Restore the dependencies with the following command: ```bash dotnet restore ``` Copy the`.env.template` file to a new file called `.env`: ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_KEY` to a private API token, `PAYABLI_ENTRY` to your Payabli entrypoint, and `PAYABLI_PUBLIC_TOKEN` to a public API token: ```bash # your Payabli Private API token PAYABLI_KEY="o.Oim...Mekgjw=" # your Payabli entrypoint PAYABLI_ENTRY="41xxxxxa7e" # your Payabli Public API token PAYABLI_PUBLIC_TOKEN="o.Oim...Mekgjw=" ``` Run this command to start the development server, and open the app in your browser: ```bash dotnet run ``` ### Use the app The SDK example app has three pages: 1. **Create Customer** - Create a new customer in the Payabli entrypoint. 2. **List Customers** - View a list of all customers in the Payabli entrypoint. 3. **Make Transaction** - Make a transaction using the temporary token flow. #### Create customer The **Create Customer** page has a form that allows you to create a new customer. Fill in the form with the customer's information and click the "Create" button. If the customer is created successfully, a green success message appears below the button. #### List customers The **List Customers** page has a table of all customers in the entrypoint. You can view the customer's information, including their name, email address, and ZIP Code. Click the "X" button on the right side of a customer's row to delete the customer. If the customer is deleted successfully, the row is removed from the table. #### Make transaction The **Make Transaction** page contains an EmbeddedMethod UI component using the temporary token flow. Fill in the form with payment information and click the "Process" button when the payment information is valid. The app performs these steps: 1. The embedded component saves the payment method as a temporary token and sends it to the server. 2. The server converts the temporary token to a permanent token with the **POST TokenStorage/add** endpoint. 3. The server uses the permanent token to make a transaction with the **POST MoneyIn/getpaid** endpoint. If everything is successful, a green success message appears below the embedded component. See [Extend embedded components with the temporary token flow](/guides/platform-developer-tokenization-temp-flow) for more information. *** title: Use the PHP SDK subtitle: Learn how to install and use the PHP SDK to develop apps description: >- Install and configure the Payabli PHP SDK to process payments, manage payouts, and automate boarding in your PHP applications with straightforward API methods 'og:description': >- Install and configure the Payabli PHP SDK to process payments, manage payouts, and automate boarding in your PHP applications with straightforward API methods keywords: >- embedded payments, PHP SDK, payment API, SDK integration, developer tools, payment processing, PHP payments slug: developers/platform-sdk-php-guide icon: brands php area: * Pay In * Pay Out * Pay Ops * Developer Tools * SDKs audience: * developers *** Payabli offers a Software Development Kit (SDK) for the PHP programming language. The PHP SDK can be installed in your projects to support app development and provide type safety when calling Payabli's APIs. Most development environments can use the SDK to generate code suggestions and inline documentation. See the [`payabli/payabli`](https://packagist.org/packages/payabli/payabli) package for more information. ## Dependencies Before you begin, make sure you have the following installed on your machine: * [PHP](https://www.php.net/downloads.php) (8.1 or higher) * [Composer](https://getcomposer.org/download/) * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) ## Use the SDK This section shows you how to install and use the Payabli SDK in a new PHP project. The example code shows how to use the SDK to make a transaction with the `moneyIn->getpaid` method. The `moneyIn->getpaid` method calls the [MoneyIn/getpaid](/developers/api-reference/moneyin/make-a-transaction) endpoint. Method names in the SDK correspond to endpoint names in the API reference. For example: the `notification->addNotification` method calls the [POST Notification](/developers/api-reference/notification/add-notification) endpoint. Open your terminal and run the following commands to create a new PHP project: ```bash mkdir my-payabli-app cd my-payabli-app ``` Run the following command to install the Payabli SDK: ```bash composer require payabli/payabli ``` Create a new file called `index.php` in the root of your `my-payabli-app` directory: ```bash touch index.php ``` Open the `index.php` file in your code editor.
/// Include autoloader and import client Import the Payabli SDK to make it available in your code. ```php new TransRequestBody([ 'customerData' => new PayorDataRequest([ 'customerId' => 4440, ]), 'entryPoint' => $entrypoint, 'ipaddress' => "255.255.255.255", 'paymentDetails' => new PaymentDetail([ 'serviceFee' => 0, 'totalAmount' => 100, ]), 'paymentMethod' => new PayMethodCredit([ 'cardcvv' => "999", 'cardexp' => "02/27", 'cardHolder' => "Kassiane Cassian", 'cardnumber' => "4111111111111111", 'cardzip' => "12345", 'initiator' => "payor", 'method' => "card", ]), ]), ]); ``` /// Execute the transaction Call `moneyIn->getpaid()` to process the transaction. The client calls Payabli's `POST /MoneyIn/getpaid` endpoint. ```php focus=40 new TransRequestBody([ 'customerData' => new PayorDataRequest([ 'customerId' => 4440, ]), 'entryPoint' => $entrypoint, 'ipaddress' => "255.255.255.255", 'paymentDetails' => new PaymentDetail([ 'serviceFee' => 0, 'totalAmount' => 100, ]), 'paymentMethod' => new PayMethodCredit([ 'cardcvv' => "999", 'cardexp' => "02/27", 'cardHolder' => "Kassiane Cassian", 'cardnumber' => "4111111111111111", 'cardzip' => "12345", 'initiator' => "payor", 'method' => "card", ]), ]), ]); $result = $client->moneyIn->getpaid($request); ``` /// Show the result Log the transaction response. Check the output to see if the transaction was successful. ```php focus=42 new TransRequestBody([ 'customerData' => new PayorDataRequest([ 'customerId' => 4440, ]), 'entryPoint' => $entrypoint, 'ipaddress' => "255.255.255.255", 'paymentDetails' => new PaymentDetail([ 'serviceFee' => 0, 'totalAmount' => 100, ]), 'paymentMethod' => new PayMethodCredit([ 'cardcvv' => "999", 'cardexp' => "02/27", 'cardHolder' => "Kassiane Cassian", 'cardnumber' => "4111111111111111", 'cardzip' => "12345", 'initiator' => "payor", 'method' => "card", ]), ]), ]); $result = $client->moneyIn->getpaid($request); var_dump($result); ```
Run the app with the following command: ```bash php index.php ``` Check the console output for the result of the transaction. A successful transaction returns output like this: ```txt array(4) { ["responseText"]=> string(7) "Success" ["isSuccess"]=> bool(true) ["pageIdentifier"]=> NULL ["responseData"]=> array(8) { ["authCode"]=> string(6) "TAS003" ["referenceId"]=> string(36) "255-67bc92c141e24f474f60c1968fcba0cd" ["resultCode"]=> int(1) ["resultText"]=> string(8) "Approved" ["avsResponseText"]=> string(35) "No Match, No address or ZIP match" ["cvvResponseText"]=> string(14) "CVV2/CVC2 match" ["customerId"]=> int(4440) ["methodReferenceId"]=> NULL } } ```
In production, we recommend that you pass a stored method ID to the `paymentMethod` object instead of card details. See more information in [Tokenization Overview](/guides/platform-tokenization-overview). ## SDK example app The SDK example app is a basic web app built with the Payabli PHP SDK. It demonstrates how to manage customers and use the temporary token flow with the SDK. The code is publicly available in the [example repository](https://github.com/payabli/examples/tree/main/sdk/php-sdk). customer creation page of SDK example app ### Set up the app Follow these steps to set up the SDK example app on your local machine: Open your terminal and run the following command to clone the SDK example app repository: ```bash git clone https://github.com/payabli/examples ``` In your terminal, navigate to the directory containing the SDK example app: ```bash cd examples/sdk/php-sdk ``` Install the dependencies with the following command: ```bash composer install ``` Copy the`.env.template` file to a new file called `.env`: ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_KEY` to a private API token, `PAYABLI_ENTRY` to your Payabli entrypoint, and `PAYABLI_PUBLIC_TOKEN` to a public API token: ```bash # your Payabli Private API token PAYABLI_KEY="o.Oim...Mekgjw=" # your Payabli entrypoint PAYABLI_ENTRY="41xxxxxa7e" # your Payabli Public API token PAYABLI_PUBLIC_TOKEN="o.Oim...Mekgjw=" ``` Run this command to start the development server, and open the app in your browser: ```bash composer run serve ``` ### Use the app The SDK example app has three pages: 1. **Create Customer** - Create a new customer in the Payabli entrypoint. 2. **List Customers** - View a list of all customers in the Payabli entrypoint. 3. **Make Transaction** - Make a transaction using the temporary token flow. #### Create customer The **Create Customer** page has a form that allows you to create a new customer. Fill in the form with the customer's information and click the "Create" button. If the customer is created successfully, a green success message appears below the button. #### List customers The **List Customers** page has a table of all customers in the entrypoint. You can view the customer's information, including their name, email address, and ZIP Code. Click the "X" button on the right side of a customer's row to delete the customer. If the customer is deleted successfully, the row is removed from the table. #### Make transaction The **Make Transaction** page contains an EmbeddedMethod UI component using the temporary token flow. Fill in the form with payment information and click the "Process" button when the payment information is valid. The app performs these steps: 1. The embedded component saves the payment method as a temporary token and sends it to the server. 2. The server converts the temporary token to a permanent token with the **POST TokenStorage/add** endpoint. 3. The server uses the permanent token to make a transaction with the **POST MoneyIn/getpaid** endpoint. If everything is successful, a green success message appears below the embedded component. See [Extend embedded components with the temporary token flow](/guides/platform-developer-tokenization-temp-flow) for more information. In the **List Customers** page, you can delete a customer by clicking the red "X" button on the right side of the customer's row. If the customer is deleted successfully, the row is removed from the table. *** title: Use the Python SDK subtitle: Learn how to install and use the Python SDK to develop apps description: >- Install and configure the Payabli Python SDK to process payments, manage payouts, and automate boarding in your Python applications with clean API wrappers 'og:description': >- Install and configure the Payabli Python SDK to process payments, manage payouts, and automate boarding in your Python applications with clean API wrappers keywords: >- embedded payments, Python SDK, payment API, SDK integration, developer tools, payment processing, Python payments slug: developers/platform-sdk-python-guide icon: brands python area: * Pay In * Pay Out * Pay Ops * Developer Tools * SDKs audience: * developers *** Payabli offers a Software Development Kit (SDK) for the Python programming language. The Python SDK can be installed in your projects to support app development and provide type safety when calling Payabli's APIs. Most development environments can use the SDK to generate code suggestions and inline documentation. See the [`payabli-sdk-python`](https://pypi.org/project/payabli/) package for more information. ## Dependencies Before you begin, make sure you have the following installed on your machine: * [Python](https://www.python.org/downloads/) 3.8+ * [pip](https://pip.pypa.io/en/stable/installation/) * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) ## Use the SDK This section shows you how to install and use the Payabli SDK in a new Python project. The example code shows how to use the SDK to make a transaction with the `money_in.getpaid` method. The `money_in.getpaid` method calls the [MoneyIn/getpaid](/developers/api-reference/moneyin/make-a-transaction) endpoint. See the [SDK reference](https://github.com/payabli/sdk-python/blob/main/reference.md) for a full list of methods. Method names in the SDK correspond to endpoint names in the API reference. For example: the `notification.add_notification` method calls the [POST Notification](/developers/api-reference/notification/add-notification) endpoint. Open your terminal and run the following commands to create a new Python project: ```bash mkdir my-payabli-app cd my-payabli-app ``` Create and activate a virtual environment: ```bash MacOS/Linux python -m venv venv source venv/bin/activate ``` ```bash Windows python -m venv venv venv\Scripts\activate ``` Run the following command to install the Payabli SDK: ```bash pip install payabli ``` Create a new file called `main.py` in the root of your `my-payabli-app` directory: ```bash touch main.py ``` Open the `main.py` file in your code editor.
/// Import the client and types Import the Payabli SDK to make it available in your code. ```python # main.py from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest ``` /// Initialize the client Create an authenticated client instance with your API key. This client has methods that call Payabli's API endpoints. ```python focus=4 # main.py from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli(api_key="REPLACE_WITH_YOUR_API_KEY") ``` /// Define the entrypoint Define your entrypoint. Get this value from your Payabli account. ```python focus=6 # main.py from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli(api_key="REPLACE_WITH_YOUR_API_KEY") entry_point = "REPLACE_WITH_YOUR_ENTRYPOINT" ``` /// Build the payment request Construct a request object that contains all the necessary fields to process a transaction. Include payment details, a payment method, and customer data. ```python focus=8-27 # main.py from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli(api_key="REPLACE_WITH_YOUR_API_KEY") entry_point = "REPLACE_WITH_YOUR_ENTRYPOINT" request_kwargs = dict( customer_data=PayorDataRequest( customer_id=4440, ), entry_point=entry_point, ipaddress="255.255.255.255", payment_details=PaymentDetail( service_fee=0.0, total_amount=100.0, ), payment_method=PayMethodCredit( cardcvv="999", cardexp="02/27", card_holder="Kassiane Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", ), ) ``` /// Execute the transaction Call `money_in.getpaid()` to process the transaction. The client calls Payabli's `POST /MoneyIn/getpaid` endpoint. ```python focus=29 # main.py from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli(api_key="REPLACE_WITH_YOUR_API_KEY") entry_point = "REPLACE_WITH_YOUR_ENTRYPOINT" request_kwargs = dict( customer_data=PayorDataRequest( customer_id=4440, ), entry_point=entry_point, ipaddress="255.255.255.255", payment_details=PaymentDetail( service_fee=0.0, total_amount=100.0, ), payment_method=PayMethodCredit( cardcvv="999", cardexp="02/27", card_holder="Kassiane Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", ), ) result = client.money_in.getpaid(**request_kwargs) ``` /// Show the result Log the transaction response. Check the output to see if the transaction was successful. ```python focus=31 # main.py from payabli import payabli, PaymentDetail, PayMethodCredit, PayorDataRequest client = payabli(api_key="REPLACE_WITH_YOUR_API_KEY") entry_point = "REPLACE_WITH_YOUR_ENTRYPOINT" request_kwargs = dict( customer_data=PayorDataRequest( customer_id=4440, ), entry_point=entry_point, ipaddress="255.255.255.255", payment_details=PaymentDetail( service_fee=0.0, total_amount=100.0, ), payment_method=PayMethodCredit( cardcvv="999", cardexp="02/27", card_holder="Kassiane Cassian", cardnumber="4111111111111111", cardzip="12345", initiator="payor", method="card", ), ) result = client.money_in.getpaid(**request_kwargs) print(result) ```
Run the app with the following command: ```bash python main.py ``` Check the console output for the result of the transaction. A successful transaction returns output like this: ```txt { 'response_text': 'Success', 'is_success': True, 'page_identifier': None, 'response_data': { 'auth_code': 'TAS003', 'reference_id': '255-67bc92c141e24f474f60c1968fcba0cd', 'result_code': 1, 'result_text': 'Approved', 'avs_response_text': 'No Match, No address or ZIP match', 'cvv_response_text': 'CVV2/CVC2 match', 'customer_id': 4440, 'method_reference_id': None } } ```
In production, we recommend that you pass a stored method ID to the `payment_method` object instead of card details. See more information in [Tokenization Overview](/guides/platform-tokenization-overview). ## SDK example app The SDK example app is a basic web app built with the Payabli Python SDK. It demonstrates how to manage customers and use the temporary token flow with the SDK. The code is publicly available in the [example repository](https://github.com/payabli/examples/tree/main/sdk/py-sdk). customer creation page of SDK example app ### Set up the app Follow these steps to set up the SDK example app on your local machine: Open your terminal and run the following command to clone the SDK example app repository: ```bash git clone https://github.com/payabli/examples ``` In your terminal, navigate to the directory containing the SDK example app: ```bash cd examples/sdk/py-sdk ``` Create and activate a virtual environment: ```bash python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate ``` Install the dependencies with the following command: ```bash pip install -r requirements.txt ``` Copy the`.env.template` file to a new file called `.env`: ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_KEY` to a private API token, `PAYABLI_ENTRY` to your Payabli entrypoint, and `PAYABLI_PUBLIC_TOKEN` to a public API token: ```bash # your Payabli Private API token PAYABLI_KEY="o.Oim...Mekgjw=" # your Payabli entrypoint PAYABLI_ENTRY="41xxxxxa7e" # your Payabli Public API token PAYABLI_PUBLIC_TOKEN="o.Oim...Mekgjw=" ``` Run this command to start the development server, and open the app in your browser: ```bash uvicorn main:app --reload ``` ### Use the app The SDK example app has three pages: 1. **Create Customer** - Create a new customer in the Payabli entrypoint. 2. **List Customers** - View a list of all customers in the Payabli entrypoint. 3. **Make Transaction** - Make a transaction using the temporary token flow. #### Create customer The **Create Customer** page has a form that allows you to create a new customer. Fill in the form with the customer's information and click the "Create" button. If the customer is created successfully, a green success message appears below the button. #### List customers The **List Customers** page has a table of all customers in the entrypoint. You can view the customer's information, including their name, email address, and ZIP Code. Click the "X" button on the right side of a customer's row to delete the customer. If the customer is deleted successfully, the row is removed from the table. #### Make transaction The **Make Transaction** page contains an EmbeddedMethod UI component using the temporary token flow. Fill in the form with payment information and click the "Process" button when the payment information is valid. The app performs these steps: 1. The embedded component saves the payment method as a temporary token and sends it to the server. 2. The server converts the temporary token to a permanent token with the **POST TokenStorage/add** endpoint. 3. The server uses the permanent token to make a transaction with the **POST MoneyIn/getpaid** endpoint. If everything is successful, a green success message appears below the embedded component. See [Extend embedded components with the temporary token flow](/guides/platform-developer-tokenization-temp-flow) for more information. *** title: Use the Java SDK subtitle: Learn how to install and use the Java SDK to develop apps description: >- Install and configure the Payabli Java SDK to process payments, manage payouts, and automate boarding in your Java applications with clean and type-safe methods 'og:description': >- Install and configure the Payabli Java SDK to process payments, manage payouts, and automate boarding in your Java applications with clean and type-safe methods keywords: >- embedded payments, Java SDK, payment API, SDK integration, developer tools, payment processing, Java payments slug: developers/platform-sdk-java-guide icon: brands java area: * Pay In * Pay Out * Pay Ops * Developer Tools * SDKs audience: * developers *** Payabli offers a Software Development Kit (SDK) for the Java programming language. The Java SDK can be installed in your projects to support app development and provide type safety when calling Payabli's APIs. Most development environments can use the SDK to generate code suggestions and inline documentation. See the [sdk-java](https://github.com/payabli/sdk-java) package for more information. ## Dependencies Before you begin, make sure you have the following installed on your machine: * [Java JDK](https://www.oracle.com/java/technologies/javase-downloads.html) 11+ * [Maven](https://maven.apache.org/install.html) 3.6+ * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) ## Use the SDK This section shows you how to install and use the Payabli SDK in a new Java project. The example code shows how to use the SDK to make a transaction with the `moneyIn().getpaid` method. The `moneyIn().getpaid` method calls the [MoneyIn/getpaid](/developers/api-reference/moneyin/make-a-transaction) endpoint. See the [SDK reference](https://github.com/payabli/sdk-java/blob/main/reference.md) for a full list of methods. Method names in the SDK correspond to endpoint names in the API reference. For example: the `notification().addNotification` method calls the [POST Notification](/developers/api-reference/notification/add-notification) endpoint. Open your terminal and run the following commands to create a new Maven project: ```bash mkdir my-payabli-app cd my-payabli-app ``` Create a basic `pom.xml` file with the Payabli SDK dependency: ```xml 4.0.0 com.example my-payabli-app 1.0.0 11 11 io.github.payabli sdk-java [0.0.310,) com.squareup.okhttp3 okhttp 4.12.0 org.codehaus.mojo exec-maven-plugin 3.1.0 example.PayabliExample runtime ``` Create the Maven directory structure: ```bash mkdir -p src/main/java/com/example ``` Create a new file called `PayabliExample.java` in `src/main/java/com/example/`: ```bash touch src/main/java/com/example/PayabliExample.java ``` Open the `PayabliExample.java` file in your code editor.
/// Import the SDK classes Import the Payabli SDK to make it available in your code. ```java // PayabliExample.java package example; import io.github.payabli.api.PayabliApiClient; import io.github.payabli.api.PayabliApiClientBuilder; import io.github.payabli.api.resources.moneyin.requests.RequestPayment; import io.github.payabli.api.resources.moneyin.types.PayabliApiResponseGetPaid; import io.github.payabli.api.resources.moneyin.types.TransRequestBody; import io.github.payabli.api.types.PaymentDetail; import io.github.payabli.api.types.PaymentMethod; import io.github.payabli.api.types.PayMethodCredit; import io.github.payabli.api.types.PayorDataRequest; ``` /// Initialize the client Create an authenticated client instance with your API key. This client has methods that call Payabli's API endpoints. ```java focus=16-18 // PayabliExample.java package example; import io.github.payabli.api.PayabliApiClient; import io.github.payabli.api.PayabliApiClientBuilder; import io.github.payabli.api.resources.moneyin.requests.RequestPayment; import io.github.payabli.api.resources.moneyin.types.PayabliApiResponseGetPaid; import io.github.payabli.api.resources.moneyin.types.TransRequestBody; import io.github.payabli.api.types.PaymentDetail; import io.github.payabli.api.types.PaymentMethod; import io.github.payabli.api.types.PayMethodCredit; import io.github.payabli.api.types.PayorDataRequest; public class PayabliExample { public static void main(String[] args) { PayabliApiClient client = new PayabliApiClientBuilder() .apiKey("REPLACE_WITH_YOUR_API_KEY") .build(); } } ``` /// Build the payment request Construct a request object that contains all the necessary fields to process a transaction. Include payment details, a payment method, and customer data. ```java focus=20-44 // PayabliExample.java package example; import io.github.payabli.api.PayabliApiClient; import io.github.payabli.api.PayabliApiClientBuilder; import io.github.payabli.api.resources.moneyin.requests.RequestPayment; import io.github.payabli.api.resources.moneyin.types.PayabliApiResponseGetPaid; import io.github.payabli.api.resources.moneyin.types.TransRequestBody; import io.github.payabli.api.types.PaymentDetail; import io.github.payabli.api.types.PaymentMethod; import io.github.payabli.api.types.PayMethodCredit; import io.github.payabli.api.types.PayorDataRequest; public class PayabliExample { public static void main(String[] args) { PayabliApiClient client = new PayabliApiClientBuilder() .apiKey("REPLACE_WITH_YOUR_API_KEY") .build(); PaymentDetail paymentDetails = PaymentDetail.builder() .totalAmount(100.0) .serviceFee(0.0) .build(); PayorDataRequest customerData = PayorDataRequest.builder() .customerId(4440L) .build(); PayMethodCredit paymentMethod = PayMethodCredit.builder() .cardexp("02/27") .cardnumber("4111111111111111") .cardcvv("999") .cardHolder("Kassiane Cassian") .cardzip("12345") .initiator("payor") .build(); TransRequestBody requestBody = TransRequestBody.builder() .paymentDetails(paymentDetails) .paymentMethod(PaymentMethod.of(paymentMethod)) .customerData(customerData) .entryPoint("REPLACE_WITH_YOUR_ENTRYPOINT") .ipaddress("255.255.255.255") .build(); } } ``` /// Execute the transaction Call `moneyIn().getpaid()` to process the transaction. The client calls Payabli's `POST /MoneyIn/getpaid` endpoint. ```java focus=50 // PayabliExample.java package example; import io.github.payabli.api.PayabliApiClient; import io.github.payabli.api.PayabliApiClientBuilder; import io.github.payabli.api.resources.moneyin.requests.RequestPayment; import io.github.payabli.api.resources.moneyin.types.PayabliApiResponseGetPaid; import io.github.payabli.api.resources.moneyin.types.TransRequestBody; import io.github.payabli.api.types.PaymentDetail; import io.github.payabli.api.types.PaymentMethod; import io.github.payabli.api.types.PayMethodCredit; import io.github.payabli.api.types.PayorDataRequest; public class PayabliExample { public static void main(String[] args) { PayabliApiClient client = new PayabliApiClientBuilder() .apiKey("REPLACE_WITH_YOUR_API_KEY") .build(); PaymentDetail paymentDetails = PaymentDetail.builder() .totalAmount(100.0) .serviceFee(0.0) .build(); PayorDataRequest customerData = PayorDataRequest.builder() .customerId(4440L) .build(); PayMethodCredit paymentMethod = PayMethodCredit.builder() .cardexp("02/27") .cardnumber("4111111111111111") .cardcvv("999") .cardHolder("Kassiane Cassian") .cardzip("12345") .initiator("payor") .build(); TransRequestBody requestBody = TransRequestBody.builder() .paymentDetails(paymentDetails) .paymentMethod(PaymentMethod.of(paymentMethod)) .customerData(customerData) .entryPoint("REPLACE_WITH_YOUR_ENTRYPOINT") .ipaddress("255.255.255.255") .build(); RequestPayment request = RequestPayment.builder() .body(requestBody) .build(); PayabliApiResponseGetPaid result = client.moneyIn().getpaid(request); } } ``` /// Show the result Log the transaction response. Check the output to see if the transaction was successful. ```java focus=52 // PayabliExample.java package example; import io.github.payabli.api.PayabliApiClient; import io.github.payabli.api.PayabliApiClientBuilder; import io.github.payabli.api.resources.moneyin.requests.RequestPayment; import io.github.payabli.api.resources.moneyin.types.PayabliApiResponseGetPaid; import io.github.payabli.api.resources.moneyin.types.TransRequestBody; import io.github.payabli.api.types.PaymentDetail; import io.github.payabli.api.types.PaymentMethod; import io.github.payabli.api.types.PayMethodCredit; import io.github.payabli.api.types.PayorDataRequest; public class PayabliExample { public static void main(String[] args) { PayabliApiClient client = new PayabliApiClientBuilder() .apiKey("REPLACE_WITH_YOUR_API_KEY") .build(); PaymentDetail paymentDetails = PaymentDetail.builder() .totalAmount(100.0) .serviceFee(0.0) .build(); PayorDataRequest customerData = PayorDataRequest.builder() .customerId(4440L) .build(); PayMethodCredit paymentMethod = PayMethodCredit.builder() .cardexp("02/27") .cardnumber("4111111111111111") .cardcvv("999") .cardHolder("Kassiane Cassian") .cardzip("12345") .initiator("payor") .build(); TransRequestBody requestBody = TransRequestBody.builder() .paymentDetails(paymentDetails) .paymentMethod(PaymentMethod.of(paymentMethod)) .customerData(customerData) .entryPoint("REPLACE_WITH_YOUR_ENTRYPOINT") .ipaddress("255.255.255.255") .build(); RequestPayment request = RequestPayment.builder() .body(requestBody) .build(); PayabliApiResponseGetPaid result = client.moneyIn().getpaid(request); System.out.println(result); } } ```
Compile and run the app with Maven: ```bash mvn clean compile exec:java ``` Check the console output for the result of the transaction. A successful transaction returns output like this: ```txt PayabliApiResponseGetPaid( responseText=Success, isSuccess=true, pageIdentifier=null, responseData=ResponseData( authCode=TAS003, referenceId=255-67bc92c141e24f474f60c1968fcba0cd, resultCode=1, resultText=Approved, avsResponseText=No Match, No address or ZIP match, cvvResponseText=CVV2/CVC2 match, customerId=4440, methodReferenceId=null ) ) ```
In production, we recommend that you pass a stored method ID to the `paymentMethod` object instead of card details. See more information in [Tokenization Overview](/guides/platform-tokenization-overview). ## SDK example app The SDK example app is a basic web app built with the Payabli Java SDK. It demonstrates how to manage customers and use the temporary token flow with the SDK. The code is publicly available in the [example repository](https://github.com/payabli/examples/tree/main/sdk/java-sdk). customer creation page of SDK example app ### Set up the app Follow these steps to set up the SDK example app on your local machine: Open your terminal and run the following command to clone the SDK example app repository: ```bash git clone https://github.com/payabli/examples ``` In your terminal, navigate to the directory containing the SDK example app: ```bash cd examples/sdk/java-sdk ``` Install the SDK and dependencies: ```bash mvn clean install ``` Copy the`.env.template` file to a new file called `.env`: ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_KEY` to a private API token, `PAYABLI_ENTRY` to your Payabli entrypoint, and `PAYABLI_PUBLIC_TOKEN` to a public API token: ```bash # your Payabli Private API token PAYABLI_KEY="o.Oim...Mekgjw=" # your Payabli entrypoint PAYABLI_ENTRY="41xxxxxa7e" # your Payabli Public API token PAYABLI_PUBLIC_TOKEN="o.Oim...Mekgjw=" ``` Run this command to start the development server, and open the app in your browser: ```bash mvn exec:java ``` ### Use the app The SDK example app has three pages: 1. **Create Customer** - Create a new customer in the Payabli entrypoint. 2. **List Customers** - View a list of all customers in the Payabli entrypoint. 3. **Make Transaction** - Make a transaction using the temporary token flow. #### Create customer The **Create Customer** page has a form that allows you to create a new customer. Fill in the form with the customer's information and click the "Create" button. If the customer is created successfully, a green success message appears below the button. #### List customers The **List Customers** page has a table of all customers in the entrypoint. You can view the customer's information, including their name, email address, and ZIP Code. Click the "X" button on the right side of a customer's row to delete the customer. If the customer is deleted successfully, the row is removed from the table. #### Make transaction The **Make Transaction** page contains an EmbeddedMethod UI component using the temporary token flow. Fill in the form with payment information and click the "Process" button when the payment information is valid. The app performs these steps: 1. The embedded component saves the payment method as a temporary token and sends it to the server. 2. The server converts the temporary token to a permanent token with the **POST TokenStorage/add** endpoint. 3. The server uses the permanent token to make a transaction with the **POST MoneyIn/getpaid** endpoint. If everything is successful, a green success message appears below the embedded component. See [Extend embedded components with the temporary token flow](/guides/platform-developer-tokenization-temp-flow) for more information. *** title: Use the Go SDK subtitle: Learn how to install and use the Go SDK to develop apps description: >- Install and configure the Payabli Go SDK to process payments, manage payouts, and automate boarding operations in your Go applications with idiomatic methods 'og:description': >- Install and configure the Payabli Go SDK to process payments, manage payouts, and automate boarding operations in your Go applications with idiomatic methods keywords: >- embedded payments, Go SDK, payment API, SDK integration, developer tools, payment processing, Golang payments slug: developers/platform-sdk-go-guide icon: brands golang area: * Pay In * Pay Out * Pay Ops * Developer Tools * SDKs audience: * developers *** Payabli offers a Software Development Kit (SDK) for the Go programming language. The Go SDK can be installed in your projects to support app development and provide type safety when calling Payabli's APIs. Most development environments can use the SDK to generate code suggestions and inline documentation. See the [Payabli Go SDK](https://github.com/payabli/sdk-go) for more information. ## Dependencies Before you begin, make sure you have the following installed on your machine: * [Go](https://golang.org/dl/) 1.18+ * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) ## Use the SDK This section shows you how to install and use the Payabli SDK in a new Go project. The example code shows how to use the SDK to make a transaction with the `MoneyIn.Getpaid` method. The `MoneyIn.Getpaid` method calls the [MoneyIn/getpaid](/developers/api-reference/moneyin/make-a-transaction) endpoint. See the [SDK reference](https://github.com/payabli/sdk-go/blob/main/reference.md) for a full list of methods. Method names in the SDK correspond to endpoint names in the API reference. For example: the `Notification.AddNotification` method calls the [POST Notification](/developers/api-reference/notification/add-notification) endpoint. Open your terminal and run the following commands to create a new Go project: ```bash mkdir my-payabli-app cd my-payabli-app go mod init my-payabli-app ``` Add the Payabli SDK to your project: ```bash go get github.com/payabli/sdk-go ``` Create a new file called `main.go` in the root of your `my-payabli-app` directory: ```bash touch main.go ``` Open the `main.go` file in your code editor.
/// Import required packages Import the Payabli SDK to make it available in your code. ```go // main.go package main import ( "context" "fmt" "log" sdk "github.com/payabli/sdk-go" "github.com/payabli/sdk-go/client" "github.com/payabli/sdk-go/option" ) ``` /// Initialize the client Create an authenticated client instance with your API key. This client has methods that call Payabli's API endpoints. ```go focus=13-16 // main.go package main import ( "context" "fmt" "log" sdk "github.com/payabli/sdk-go" "github.com/payabli/sdk-go/client" "github.com/payabli/sdk-go/option" ) func main() { client := client.NewClient(option.WithApiKey("REPLACE_WITH_YOUR_API_KEY")) } ``` /// Define the entrypoint Define your entrypoint. Get this value from your Payabli account. ```go focus=17 // main.go package main import ( "context" "fmt" "log" sdk "github.com/payabli/sdk-go" "github.com/payabli/sdk-go/client" "github.com/payabli/sdk-go/option" ) func main() { client := client.NewClient(option.WithApiKey("REPLACE_WITH_YOUR_API_KEY")) entrypoint := "REPLACE_WITH_YOUR_ENTRYPOINT" } ``` /// Build the payment request Construct a request object that contains all the necessary fields to process a transaction. Include payment details, a payment method, and customer data. ```go focus=19-35 // main.go package main import ( "context" "fmt" "log" sdk "github.com/payabli/sdk-go" "github.com/payabli/sdk-go/client" "github.com/payabli/sdk-go/option" ) func main() { client := client.NewClient(option.WithApiKey("REPLACE_WITH_YOUR_API_KEY")) entrypoint := "REPLACE_WITH_YOUR_ENTRYPOINT" request := &sdk.RequestPayment{ Body: &sdk.TransRequestBody{ EntryPoint: &entrypoint, PaymentDetails: &sdk.PaymentDetail{ TotalAmount: 100.0, }, PaymentMethod: &sdk.PaymentMethod{ PayMethodCredit: &sdk.PayMethodCredit{ Cardnumber: "4111111111111111", Cardexp: "02/27", }, }, CustomerData: &sdk.PayorDataRequest{ CustomerId: sdk.Int64(4440), }, }, } } ``` /// Execute the transaction Call `MoneyIn.Getpaid()` to process the transaction. The client calls Payabli's `POST /MoneyIn/getpaid` endpoint. ```go focus=37-40 // main.go package main import ( "context" "fmt" "log" sdk "github.com/payabli/sdk-go" "github.com/payabli/sdk-go/client" "github.com/payabli/sdk-go/option" ) func main() { client := client.NewClient(option.WithApiKey("REPLACE_WITH_YOUR_API_KEY")) entrypoint := "REPLACE_WITH_YOUR_ENTRYPOINT" request := &sdk.RequestPayment{ Body: &sdk.TransRequestBody{ EntryPoint: &entrypoint, PaymentDetails: &sdk.PaymentDetail{ TotalAmount: 100.0, }, PaymentMethod: &sdk.PaymentMethod{ PayMethodCredit: &sdk.PayMethodCredit{ Cardnumber: "4111111111111111", Cardexp: "02/27", }, }, CustomerData: &sdk.PayorDataRequest{ CustomerId: sdk.Int64(4440), }, }, } response, err := client.MoneyIn.Getpaid(context.Background(), request) if err != nil { log.Fatalf("Transaction failed: %v", err) } } ``` /// Show the result Log the transaction response. Check the output to see if the transaction was successful. ```go focus=42 // main.go package main import ( "context" "fmt" "log" sdk "github.com/payabli/sdk-go" "github.com/payabli/sdk-go/client" "github.com/payabli/sdk-go/option" ) func main() { client := client.NewClient(option.WithApiKey("REPLACE_WITH_YOUR_API_KEY")) entrypoint := "REPLACE_WITH_YOUR_ENTRYPOINT" request := &sdk.RequestPayment{ Body: &sdk.TransRequestBody{ EntryPoint: &entrypoint, PaymentDetails: &sdk.PaymentDetail{ TotalAmount: 100.0, }, PaymentMethod: &sdk.PaymentMethod{ PayMethodCredit: &sdk.PayMethodCredit{ Cardnumber: "4111111111111111", Cardexp: "02/27", }, }, CustomerData: &sdk.PayorDataRequest{ CustomerId: sdk.Int64(4440), }, }, } response, err := client.MoneyIn.Getpaid(context.Background(), request) if err != nil { log.Fatalf("Transaction failed: %v", err) } fmt.Printf("Transaction successful: %+v\n", response) } ```
Run the app with the following command: ```bash go run main.go ``` Check the console output for the result of the transaction. A successful transaction returns output like this: ```txt Transaction successful: { ResponseText: Success IsSuccess: true PageIdentifier: ResponseData: { AuthCode: TAS003 ReferenceId: 255-67bc92c141e24f474f60c1968fcba0cd ResultCode: 1 ResultText: Approved AvsResponseText: No Match, No address or ZIP match CvvResponseText: CVV2/CVC2 match CustomerId: 4440 MethodReferenceId: } } ```
In production, we recommend that you pass a stored method ID to the `PaymentMethod` object instead of card details. See more information in [Tokenization Overview](/guides/platform-tokenization-overview). ## SDK example app The SDK example app is a basic web app built with the Payabli Go SDK. It demonstrates how to manage customers and use the temporary token flow with the SDK. The code is publicly available in the [example repository](https://github.com/payabli/examples/tree/main/sdk/go-sdk). customer creation page of SDK example app ### Set up the app Follow these steps to set up the SDK example app on your local machine: Open your terminal and run the following command to clone the SDK example app repository: ```bash git clone https://github.com/payabli/examples ``` In your terminal, navigate to the directory containing the SDK example app: ```bash cd examples/sdk/go-sdk ``` Install the Go dependencies: ```bash go mod tidy ``` Copy the`.env.template` file to a new file called `.env`: ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_KEY` to a private API token, `PAYABLI_ENTRY` to your Payabli entrypoint, and `PAYABLI_PUBLIC_TOKEN` to a public API token: ```bash # your Payabli Private API token PAYABLI_KEY="o.Oim...Mekgjw=" # your Payabli entrypoint PAYABLI_ENTRY="41xxxxxa7e" # your Payabli Public API token PAYABLI_PUBLIC_TOKEN="o.Oim...Mekgjw=" ``` Run this command to start the development server: ```bash go run main.go ``` ### Use the app The SDK example app has three pages: 1. **Create Customer** - Create a new customer in the Payabli entrypoint. 2. **List Customers** - View a list of all customers in the Payabli entrypoint. 3. **Make Transaction** - Make a transaction using the temporary token flow. #### Create customer The **Create Customer** page has a form that allows you to create a new customer. Fill in the form with the customer's information and click the "Create" button. If the customer is created successfully, a green success message appears below the button. #### List customers The **List Customers** page has a table of all customers in the entrypoint. You can view the customer's information, including their name, email address, and ZIP Code. Click the "X" button on the right side of a customer's row to delete the customer. If the customer is deleted successfully, the row is removed from the table. #### Make transaction The **Make Transaction** page contains an EmbeddedMethod UI component using the temporary token flow. Fill in the form with payment information and click the "Process" button when the payment information is valid. The app performs these steps: 1. The embedded component saves the payment method as a temporary token and sends it to the server. 2. The server converts the temporary token to a permanent token with the **POST TokenStorage/add** endpoint. 3. The server uses the permanent token to make a transaction with the **POST MoneyIn/getpaid** endpoint. If everything is successful, a green success message appears below the embedded component. See [Extend embedded components with the temporary token flow](/guides/platform-developer-tokenization-temp-flow) for more information. *** title: Use the Ruby SDK subtitle: Learn how to install and use the Ruby SDK to develop apps description: >- Install and configure the Payabli Ruby SDK to process payments, manage payouts, and automate boarding in your Ruby applications with an idiomatic API interface 'og:description': >- Install and configure the Payabli Ruby SDK to process payments, manage payouts, and automate boarding in your Ruby applications with an idiomatic API interface keywords: >- embedded payments, Ruby SDK, payment API, SDK integration, developer tools, payment processing, Ruby payments slug: developers/platform-sdk-ruby-guide icon: gem area: * Pay In * Pay Out * Pay Ops * Developer Tools * SDKs audience: * developers *** Payabli offers a Software Development Kit (SDK) for the Ruby programming language. The Ruby SDK can be installed in your projects to support app development and provide type safety when calling Payabli's APIs. Most development environments can use the SDK to generate code suggestions and inline documentation. See the [`payabli`](https://rubygems.org/gems/payabli/) package for more information. ## Dependencies {/* vale Payabli.PayabliSpelling = NO */} Before you begin, make sure you have the following installed on your machine: * [bundler](https://bundler.io/) * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) {/* vale Payabli.PayabliSpelling = YES */} ## Use the SDK This section shows you how to install and use the Payabli SDK in a new Ruby project. The example code shows how to use the SDK to make a transaction with the `money_in.getpaid` method. The `money_in.getpaid` method calls the [MoneyIn/getpaid](/developers/api-reference/moneyin/make-a-transaction) endpoint. See the [SDK reference](https://github.com/payabli/sdk-ruby/blob/main/reference.md) for a full list of methods. Method names in the SDK correspond to endpoint names in the API reference. For example: the `notification.add_notification` method calls the [POST Notification](/developers/api-reference/notification/add-notification) endpoint. Open your terminal and run the following commands to create a new Ruby project: ```bash mkdir my-payabli-app cd my-payabli-app ``` Create a `Gemfile` to manage your dependencies: ```bash bundle init ``` Add the Payabli SDK to your `Gemfile`: ```bash bundle add payabli ``` Create a new file called `main.rb` in the root of your `my-payabli-app` directory: ```bash touch main.rb ``` Open the `main.rb` file in your code editor.
/// Import the SDK Import the Payabli SDK to make it available in your code. ```ruby # main.rb require 'payabli' ``` /// Initialize the client Create an authenticated client instance with your API key. This client has methods that call Payabli's API endpoints. ```ruby focus=4-7 # main.rb require 'payabli' client = Payabli::Client.new( api_key: "REPLACE_WITH_YOUR_API_KEY", base_url: Payabli::Environment::SANDBOX ) ``` /// Define the entrypoint Define your entrypoint. Get this value from your Payabli account. ```ruby focus=9 # main.rb require 'payabli' client = Payabli::Client.new( api_key: "REPLACE_WITH_YOUR_API_KEY", base_url: Payabli::Environment::SANDBOX ) entry_point = "REPLACE_WITH_YOUR_ENTRYPOINT" ``` /// Build the payment request Construct a request object that contains all the necessary fields to process a transaction. Include payment details, a payment method, and customer data. ```ruby focus=11-30 # main.rb require 'payabli' client = Payabli::Client.new( api_key: "REPLACE_WITH_YOUR_API_KEY", base_url: Payabli::Environment::SANDBOX ) entry_point = "REPLACE_WITH_YOUR_ENTRYPOINT" request_params = { customer_data: { customer_id: 4440 }, entry_point: entry_point, ipaddress: "255.255.255.255", payment_details: { service_fee: 0.0, total_amount: 100.0 }, payment_method: { cardcvv: "999", cardexp: "02/27", card_holder: "Kassiane Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card" } } ``` /// Execute the transaction Call `money_in.getpaid()` to process the transaction. The client calls Payabli's `POST /MoneyIn/getpaid` endpoint. ```ruby focus=32 # main.rb require 'payabli' client = Payabli::Client.new( api_key: "REPLACE_WITH_YOUR_API_KEY", base_url: Payabli::Environment::SANDBOX ) entry_point = "REPLACE_WITH_YOUR_ENTRYPOINT" request_params = { customer_data: { customer_id: 4440 }, entry_point: entry_point, ipaddress: "255.255.255.255", payment_details: { service_fee: 0.0, total_amount: 100.0 }, payment_method: { cardcvv: "999", cardexp: "02/27", card_holder: "Kassiane Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card" } } result = client.money_in.getpaid(**request_params) ``` /// Show the result Log the transaction response. Check the output to see if the transaction was successful. ```ruby focus=34 # main.rb require 'payabli' client = Payabli::Client.new( api_key: "REPLACE_WITH_YOUR_API_KEY", base_url: Payabli::Environment::SANDBOX ) entry_point = "REPLACE_WITH_YOUR_ENTRYPOINT" request_params = { customer_data: { customer_id: 4440 }, entry_point: entry_point, ipaddress: "255.255.255.255", payment_details: { service_fee: 0.0, total_amount: 100.0 }, payment_method: { cardcvv: "999", cardexp: "02/27", card_holder: "Kassiane Cassian", cardnumber: "4111111111111111", cardzip: "12345", initiator: "payor", method: "card" } } result = client.money_in.getpaid(**request_params) puts result.to_h ```
Run the app with the following command: ```bash ruby main.rb ``` Check the console output for the result of the transaction. A successful transaction returns output like this: ```txt { "responseText" => "Success", "isSuccess" => true, "responseData" => { "authCode" => "TAS003", "referenceId" => "255-67bc92c141e24f474f60c1968fcba0cd", "resultCode" => 1, "resultText" => "Approved", "avsResponseText" => "No Match, No address or ZIP match", "cvvResponseText" => "CVV2/CVC2 match", "customerId" => 4440, } } ```
In production, we recommend that you pass a stored method ID to the `payment_method` object instead of card details. See more information in [Tokenization Overview](/guides/platform-tokenization-overview). ## SDK example app The SDK example app is a basic web app built with the Payabli Ruby SDK. It demonstrates how to manage customers and use the temporary token flow with the SDK. The code is publicly available in the [example repository](https://github.com/payabli/examples/tree/main/sdk/ruby-sdk). customer creation page of SDK example app ### Set up the app Follow these steps to set up the SDK example app on your local machine: Open your terminal and run the following command to clone the SDK example app repository: ```bash git clone https://github.com/payabli/examples ``` In your terminal, navigate to the directory containing the SDK example app: ```bash cd examples/sdk/ruby-sdk ``` Install the project dependencies with Bundler: ```bash bundle install ``` Copy the `.env.template` file to a new file called `.env`: ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_KEY` to a private API token, `PAYABLI_ENTRY` to your Payabli entrypoint, and `PAYABLI_PUBLIC_TOKEN` to a public API token: ```bash # your Payabli Private API token PAYABLI_KEY="o.Oim...Mekgjw=" # your Payabli entrypoint PAYABLI_ENTRY="41xxxxxa7e" # your Payabli Public API token PAYABLI_PUBLIC_TOKEN="o.Oim...Mekgjw=" ``` Run this command to start the development server, and open the app in your browser: ```bash bundle exec ruby app.rb ``` ### Use the app The SDK example app has three pages: 1. **Create Customer** - Create a new customer in the Payabli entrypoint. 2. **List Customers** - View a list of all customers in the Payabli entrypoint. 3. **Make Transaction** - Make a transaction using the temporary token flow. #### Create customer The **Create Customer** page has a form that allows you to create a new customer. Fill in the form with the customer's information and click the "Create" button. If the customer is created successfully, a green success message appears below the button. #### List customers The **List Customers** page has a table of all customers in the entrypoint. You can view the customer's information, including their name, email address, and ZIP Code. Click the "X" button on the right side of a customer's row to delete the customer. If the customer is deleted successfully, the row is removed from the table. #### Make transaction The **Make Transaction** page contains an EmbeddedMethod UI component using the temporary token flow. Fill in the form with payment information and click the "Process" button when the payment information is valid. The app performs these steps: 1. The embedded component saves the payment method as a temporary token and sends it to the server. 2. The server converts the temporary token to a permanent token with the **POST TokenStorage/add** endpoint. 3. The server uses the permanent token to make a transaction with the **POST MoneyIn/getpaid** endpoint. If everything is successful, a green success message appears below the embedded component. See [Extend embedded components with the temporary token flow](/guides/platform-developer-tokenization-temp-flow) for more information. *** title: Use the Rust SDK subtitle: Learn how to install and use the Rust SDK to develop apps description: >- Install and configure the Payabli Rust SDK to process payments, manage payouts, and automate boarding in your Rust applications with a safe and ergonomic client 'og:description': >- Install and configure the Payabli Rust SDK to process payments, manage payouts, and automate boarding in your Rust applications with a safe and ergonomic client keywords: >- embedded payments, Rust SDK, payment API, SDK integration, developer tools, payment processing, Rust payments slug: developers/platform-sdk-rust-guide icon: brands rust area: * Pay In * Pay Out * Pay Ops * Developer Tools * SDKs audience: * developers *** Payabli offers a Software Development Kit (SDK) for the Rust programming language. The Rust SDK can be installed in your projects to support app development and provide type safety when calling Payabli's APIs. Most development environments can use the SDK to generate code suggestions and inline documentation. See the [`payabli_api`](https://crates.io/crates/payabli_api) crate for more information. ## Dependencies {/* vale Payabli.PayabliSpelling = NO */} Before you begin, make sure you have the following installed on your machine: * [cargo](https://doc.rust-lang.org/cargo/getting-started/installation.html) * [git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) {/* vale Payabli.PayabliSpelling = YES */} ## Use the SDK This section shows you how to install and use the Payabli SDK in a new Rust project. The example code shows how to use the SDK to make a transaction with the `money_in.getpaid` method. The `money_in.getpaid` method calls the [MoneyIn/getpaid](/developers/api-reference/moneyin/make-a-transaction) endpoint. See the [SDK reference](https://github.com/payabli/sdk-rust/blob/main/reference.md) for a full list of methods. Method names in the SDK correspond to endpoint names in the API reference. For example: the `notification.add_notification` method calls the [POST Notification](/developers/api-reference/notification/add-notification) endpoint. Open your terminal and run the following command to create a new Rust project: ```bash cargo new my-payabli-app cd my-payabli-app ``` Add the Payabli SDK to your project: ```bash cargo add payabli_api cargo add tokio --features full ``` Open the `src/main.rs` file that was created automatically in your code editor.
/// Import the SDK Import the Payabli SDK to make it available in your code. ```rust // src/main.rs use payabli_api::prelude::*; ``` /// Define constants Define your API key and entrypoint as constants. Get these values from your Payabli account. ```rust focus=3-5 // src/main.rs use payabli_api::prelude::*; const API_KEY: &str = "REPLACE_WITH_YOUR_API_KEY"; const ENTRY_POINT: &str = "REPLACE_WITH_YOUR_ENTRYPOINT"; ``` /// Set up the async runtime Create the main async function using the `tokio` runtime. ```rust focus=7-8 // src/main.rs use payabli_api::prelude::*; const API_KEY: &str = "REPLACE_WITH_YOUR_API_KEY"; const ENTRY_POINT: &str = "REPLACE_WITH_YOUR_ENTRYPOINT"; #[tokio::main] async fn main() {} ``` /// Initialize the client Create an authenticated client instance with your API key. This client has methods that call Payabli's API endpoints. ```rust focus=9-14 // src/main.rs use payabli_api::prelude::*; const API_KEY: &str = "REPLACE_WITH_YOUR_API_KEY"; const ENTRY_POINT: &str = "REPLACE_WITH_YOUR_ENTRYPOINT"; #[tokio::main] async fn main() { let config = ClientConfig { api_key: Some(API_KEY.to_string()), ..Default::default() }; let client = ApiClient::new(config).expect("Failed to build client"); } ``` /// Build the payment request Construct a request object that contains all the necessary fields to process a transaction. Include payment details, a payment method, and customer data. ```rust focus=16-79 // src/main.rs use payabli_api::prelude::*; const API_KEY: &str = "REPLACE_WITH_YOUR_API_KEY"; const ENTRY_POINT: &str = "REPLACE_WITH_YOUR_ENTRYPOINT"; #[tokio::main] async fn main() { let config = ClientConfig { api_key: Some(API_KEY.to_string()), ..Default::default() }; let client = ApiClient::new(config).expect("Failed to build client"); let result = client .money_in .getpaid( &GetpaidRequest { body: TransRequestBody { account_id: None, customer_data: Some(PayorDataRequest { additional_data: None, billing_address_1: None, billing_address_2: None, billing_city: None, billing_country: None, billing_email: None, billing_phone: None, billing_state: None, billing_zip: None, company: None, customer_id: Some(CustomerId(4440)), customer_number: None, first_name: None, identifier_fields: None, last_name: None, shipping_address_1: None, shipping_address_2: None, shipping_city: None, shipping_country: None, shipping_state: None, shipping_zip: None, }), entry_point: Some(Entrypointfield(ENTRY_POINT.to_string())), invoice_data: None, ipaddress: Some(IpAddress("255.255.255.255".to_string())), order_description: None, order_id: None, payment_details: PaymentDetail { categories: None, check_image: None, check_number: None, currency: None, service_fee: Some(0.0), split_funding: None, total_amount: 100.0, }, payment_method: PaymentMethod::PayMethodCredit(PayMethodCredit { cardcvv: Some(Cardcvv("999".to_string())), cardexp: Cardexp("02/27".to_string()), card_holder: Some(Cardholder("John Cassian".to_string())), cardnumber: Cardnumber("4111111111111111".to_string()), cardzip: Some(Cardzip("12345".to_string())), initiator: Some(Initiator("payor".to_string())), method: "card".to_string(), save_if_success: None, }), source: None, subdomain: None, subscription_id: None, }, ach_validation: None, force_customer_creation: None, include_details: None, }, None, ) .await; } ``` /// Show the result Log the transaction response. Check the output to see if the transaction was successful. ```rust focus=81 // src/main.rs use payabli_api::prelude::*; const API_KEY: &str = "REPLACE_WITH_YOUR_API_KEY"; const ENTRY_POINT: &str = "REPLACE_WITH_YOUR_ENTRYPOINT"; #[tokio::main] async fn main() { let config = ClientConfig { api_key: Some(API_KEY.to_string()), ..Default::default() }; let client = ApiClient::new(config).expect("Failed to build client"); let result = client .money_in .getpaid( &GetpaidRequest { body: TransRequestBody { account_id: None, customer_data: Some(PayorDataRequest { additional_data: None, billing_address_1: None, billing_address_2: None, billing_city: None, billing_country: None, billing_email: None, billing_phone: None, billing_state: None, billing_zip: None, company: None, customer_id: Some(CustomerId(4440)), customer_number: None, first_name: None, identifier_fields: None, last_name: None, shipping_address_1: None, shipping_address_2: None, shipping_city: None, shipping_country: None, shipping_state: None, shipping_zip: None, }), entry_point: Some(Entrypointfield(ENTRY_POINT.to_string())), invoice_data: None, ipaddress: Some(IpAddress("255.255.255.255".to_string())), order_description: None, order_id: None, payment_details: PaymentDetail { categories: None, check_image: None, check_number: None, currency: None, service_fee: Some(0.0), split_funding: None, total_amount: 100.0, }, payment_method: PaymentMethod::PayMethodCredit(PayMethodCredit { cardcvv: Some(Cardcvv("999".to_string())), cardexp: Cardexp("02/27".to_string()), card_holder: Some(Cardholder("John Cassian".to_string())), cardnumber: Cardnumber("4111111111111111".to_string()), cardzip: Some(Cardzip("12345".to_string())), initiator: Some(Initiator("payor".to_string())), method: "card".to_string(), save_if_success: None, }), source: None, subdomain: None, subscription_id: None, }, ach_validation: None, force_customer_creation: None, include_details: None, }, None, ) .await; println!("{:?}", result); } ```
Run the app with the following command: ```bash cargo run ``` Check the console output for the result of the transaction. A successful transaction returns output like this: ```rust Ok( PayabliApiResponseGetPaid { response_text: ResponseText("Success"), is_success: IsSuccess(true), page_identifier: None, response_data: GetPaidResponseData { auth_code: Some(Authcode("TAS660")), transaction_details: None, reference_id: Referenceidtrans("255-2ea956014a6d42e9a3353d35d1cc2dae"), result_code: ResultCode(1), result_text: Resulttext("Approved"), avs_response_text: AvsResponseText("No Match, No address or ZIP match"), cvv_response_text: CvvResponseText("CVV2/CVC2 match"), customer_id: Customeridtrans(4440), method_reference_id: None } } ) ```
In production, we recommend that you pass a stored method ID to the `payment_method` object instead of card details. See more information in [Tokenization Overview](/guides/platform-tokenization-overview). ## SDK example app The SDK example app is a basic web app built with the Payabli Rust SDK. It demonstrates how to manage customers and use the temporary token flow with the SDK. The code is publicly available in the [example repository](https://github.com/payabli/examples/tree/main/sdk/rust-sdk). customer creation page of SDK example app ### Set up the app Follow these steps to set up the SDK example app on your local machine: Open your terminal and run the following command to clone the SDK example app repository: ```bash git clone https://github.com/payabli/examples ``` In your terminal, navigate to the directory containing the SDK example app: ```bash cd examples/sdk/rust-sdk ``` Install the project dependencies with Cargo: ```bash cargo build ``` Copy the `.env.template` file to a new file called `.env`: ```bash cp .env.template .env ``` Open the `.env` file in your code editor. Set `PAYABLI_KEY` to a private API token, `PAYABLI_ENTRY` to your Payabli entrypoint, and `PAYABLI_PUBLIC_TOKEN` to a public API token: ```bash # your Payabli Private API token PAYABLI_KEY="o.Oim...Mekgjw=" # your Payabli entrypoint PAYABLI_ENTRY="41xxxxxa7e" # your Payabli Public API token PAYABLI_PUBLIC_TOKEN="o.Oim...Mekgjw=" ``` Run this command to start the development server, and open the app in your browser: ```bash cargo run ``` ### Use the app The SDK example app has three pages: 1. **Create Customer** - Create a new customer in the Payabli entrypoint. 2. **List Customers** - View a list of all customers in the Payabli entrypoint. 3. **Make Transaction** - Make a transaction using the temporary token flow. #### Create customer The **Create Customer** page has a form that allows you to create a new customer. Fill in the form with the customer's information and click the "Create" button. If the customer is created successfully, a green success message appears below the button. #### List customers The **List Customers** page has a table of all customers in the entrypoint. You can view the customer's information, including their name, email address, and ZIP Code. Click the "X" button on the right side of a customer's row to delete the customer. If the customer is deleted successfully, the row is removed from the table. #### Make transaction The **Make Transaction** page contains an EmbeddedMethod UI component using the temporary token flow. Fill in the form with payment information and click the "Process" button when the payment information is valid. The app performs these steps: 1. The embedded component saves the payment method as a temporary token and sends it to the server. 2. The server converts the temporary token to a permanent token with the **POST TokenStorage/add** endpoint. 3. The server uses the permanent token to make a transaction with the **POST MoneyIn/getpaid** endpoint. If everything is successful, a green success message appears below the embedded component. See [Extend embedded components with the temporary token flow](/guides/platform-developer-tokenization-temp-flow) for more information. *** title: Postman collection subtitle: Download a Payabli Postman collection to get testing fast description: >- Fork the official Payabli Postman collection to test API endpoints, explore request and response formats, and speed up your embedded payments API integration 'og:description': >- Fork the official Payabli Postman collection to test API endpoints, explore request and response formats, and speed up your embedded payments API integration keywords: >- embedded payments, Postman collection, API testing, payment API, developer tools, API exploration, REST API slug: developers/platform-postman-collection icon: rocket-launch area: * Developer Tools audience: * developers hide-nav-links: true *** {/* vale Payabli.We = NO */} View and fork our Postman Collections from the [Official Payabli API Workspace](https://www.postman.com/payabli-docs/payabli-api-workspace/overview) Collections are automatically regenerated when we update the API docs. Due to technical limitations, when updates occur, the entire collection is replaced rather than incrementally updated. This means: * When the API specification changes, we generate a new collection * Existing collections are fully replaced with the updated versions * You may need to re-import collections after updates We recommend that you save any important custom modifications separately, check for collection updates, and review the [Payabli API changelog](/changelog/api-changelog) when collections are updated. *** title: Use the Payabli MCP server subtitle: Learn how to use the Payabli MCP server to integrate with AI workflows description: >- Connect your AI agents and LLMs to Payabli documentation and SDK references with the MCP server. Streamline your development workflow with AI-powered assistance 'og:description': >- Connect your AI agents and LLMs to Payabli documentation and SDK references with the MCP server. Streamline your development workflow with AI-powered assistance keywords: >- embedded payments, MCP server, AI integration, developer tools, model context protocol, payment API, AI agents slug: developers/platform-developer-mcp icon: microchip-ai area: * Developer Tools audience: * developers *** The Payabli MCP (Model Context Protocol) server connects your AI agents to Payabli's documentation and SDK references. Set up the Payabli MCP server in your IDE or AI chat to get help with your Payabli integration. For more information about the Model Context Protocol, visit the [MCP docs](https://modelcontextprotocol.io/introduction). If your AI agent supports MCP, you can set up the Payabli MCP Server to give your AI agent knowledge about Payabli's APIs and SDK. The Payabli MCP server lets you: * Get instant answers to questions about Payabli APIs, features, and implementation * Search documentation without leaving your development environment * Find code examples and best practices for common use cases * Troubleshoot issues with guidance from our documentation and SDK references * Write code that integrates your application with Payabli ## Installation To configure the Payabli MCP server, select your IDE or AI chat provider and follow the instructions. 1. Open **Cursor** and open the `.cursor` directory in your project root. If it doesn't exist, create it. This directory contains Cursor's configuration files for your project. 2. Open the `mcp.json` file in the `.cursor` directory. If it doesn't exist, create it. This file contains all MCP server configurations for your project. 3. Add the following configuration to your `mcp.json` file: ```json mcp.json { "mcpServers": { "inkeepMcp": { "url": "https://mcp.inkeep.com/payabli/mcp" } } } ``` 4. Save the configuration file. 5. Restart Cursor. Windsurf uses `npm` to access the Payabli MCP server. You must have **Node.js** installed on your system. See [Node.js installation instructions](https://nodejs.org/en/download/) for more information. 1. Open **Windsurf**. 2. Navigate to the *Cascade assistant* sidebar. 3. Click the **hammer (MCP)** icon to access MCP settings. 4. Click **Configure > View raw config**. 5. Open the configuration file `~/.codeium/windsurf/mcp_config.json`. This file contains Windsurf's global configuration for MCP servers. 6. Add the following configuration to your `mcp_config.json` file: ```json mcp_config.json { "mcpServers": { "payabli": { "server_url": "https://mcp.inkeep.com/payabli/mcp", } } } ``` 7. Save the configuration file. 8. Click the **Refresh** button in the *Cascade sidebar* next to "available MCP servers". Claude Desktop uses `npm` to access the Payabli MCP server. You must have **Node.js** installed on your system. See [Node.js installation instructions](https://nodejs.org/en/download/) for more information. 1. Open **Claude Desktop**. 2. Navigate to **File > Settings** on Windows or **Settings** on MacOS. 3. Navigate to the **Developer** tab. 4. Click **Edit Config**. 5. Open the configuration file `claude_desktop_config.json`. This file manages all MCP servers for Claude Desktop. 6. Add the following configuration to your `claude_desktop_config.json` file: ```json claude_desktop_config.json { "mcpServers": { "payabli": { "command": "npx", "args": ["-y", "mcp-remote", "https://mcp.inkeep.com/payabli/mcp"] } } } ``` 7. Save the configuration file. 8. Restart Claude Desktop. Claude Desktop's remote MCP functionality is currently in beta. ### Enterprise and team plans 1. Open **Claude Desktop**. 2. Navigate to **Admin settings > Connectors**. 3. Navigate to the bottom of the section. 4. Click **Add custom connector**. 5. Fill in the fields as follows: * **Name**: Payabli MCP * **Remote MCP server URL**: `https://mcp.inkeep.com/payabli/mcp` 6. Click the **Add** button. ### Pro and max plans 1. Open **Claude Desktop**. 2. Navigate to **Settings > Connectors**. 3. Navigate to the bottom of the section. 4. Click **Add custom connector**. 5. Fill in the fields as follows: * **Name**: Payabli MCP * **Remote MCP server URL**: `https://mcp.inkeep.com/payabli/mcp` 6. Click the **Add** button. ## Usage The Payabli MCP provides the following tools: * **`search-payabli-docs`** - Searches Payabli's official documentation * **`ask-question-about-payabli`** - Searches Payabli's SDK GitHub repository and other resources outside of the documentation Your AI agent automatically selects the appropriate tool based on your question. *** title: Payabli example apps subtitle: Check out example apps to help you get started with Payabli description: >- Explore ready-to-run example apps that demonstrate Payabli payment integrations. Get started faster with working code for common embedded payment use cases 'og:description': >- Explore ready-to-run example apps that demonstrate Payabli payment integrations. Get started faster with working code for common embedded payment use cases keywords: >- embedded payments, example apps, sample code, payment integration, developer tools, quickstart, payment processing slug: developers/platform-example-apps icon: users area: * Pay In * Pay Out * Pay Ops audience: * developers *** This page contains example applications that show how to use Payabli's APIs and embedded components. All examples are open source and available on the `payabli/examples` GitHub repository. Visit the [GitHub repository](https://github.com/payabli/examples) to explore the code. * [Boarding](https://github.com/payabli/examples/tree/main/boarding) — An example app that uses Payabli's boarding APIs in a custom UI. The app is built with shadcn/ui and React. See [API boarding quickstart](/guides/pay-ops-developer-boarding-quickstart) for more information. * [Temp token flow](https://github.com/payabli/examples/tree/main/temp-token) — An example app that demonstrates how to use Payabli's temporary token flow with embedded components. The app has an interactive sidebar that explains the lifecycle of transactions. See [Temporary token example app](/guides/platform-tokenization-temp-token-app) for more information. * [Server SDKs](https://github.com/payabli/examples/tree/main/sdk) — An example app built with Payabli's official server SDKs. The application demonstrates how to use the SDK to interact with Payabli's APIs. See [SDKs](/developers/platform-developer-tools-overview#sdks) for more information. * [React](https://github.com/payabli/examples/tree/main/react-integration) — An example app using Payabli's embedded components in React. See [Framework integrations](/guides/pay-in-developer-components-frameworks#react) for more information. * [Vue](https://github.com/payabli/examples/tree/main/vue-integration) — An example app using Payabli's embedded components in Vue. See [Framework integrations](/guides/pay-in-developer-components-frameworks#vue) for more information.