Integrate cryptocurrency payments into applications and games with a powerful, yet secure API environment
Branch: master
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
C# Added expirationTime for example codes Jan 13, 2019
Go Added expirationTime for example codes Jan 13, 2019
Java Added expirationTime for example codes Jan 13, 2019
JavaScript Added expirationTime for example codes Jan 13, 2019
NodeJS Added expirationTime for example codes Jan 13, 2019
PHP Added expirationTime for example codes Jan 13, 2019
Python Added expirationTime for example codes Jan 13, 2019
Ruby Added expirationTime for example codes Jan 13, 2019
Shell
z_images Pump Dec 18, 2018
.gitattributes Create .gitattributes Dec 18, 2018
CONTRIBUTING.md Update CONTRIBUTING.md Dec 18, 2018
LICENSE Initial commit Nov 9, 2018
README.md

README.md

AtomicPay

AtomicPay REST API

AtomicPay provides a standard HTTP RESTful interface which enables application developers to programmatically interact with their account in a powerful, yet secure environment. Using the AtomicPay API, clients can create and manage invoices, retrieve transaction information, access features, retrieve real-time currency rates, manage bills, and much more.

This Git repository contains code examples on how to make requests to AtomicPay RESTful API for various programming languages, including C#, Go, Java, JavaScript, NodeJS, PHP, Python, Ruby and Shell scripting. Future updates include easy-to-use code library for each programming languages.

Develop with C#? AtomicPay has it's C# .NET SDK for .Net Core, .NET Framework, Xamarin developments. The library is developed and maintained by contributor MSiccDev, https://github.com/MSiccDev/AtomicPay.NET

If you are interested to develop open source library for any of the languages, please read our guidelines for contributing or contact us via Telegram or email to support@atomicpay.io

Follow us on our developments

We develop in lightning speed! If you would like to keep up with what we are building or our upcoming cool features, please follow us on AtomicPay Official Channels:

Meanwhile, here is a short deck to learn more about AtomicPay: https://www.slideshare.net/atomicpay/atomicpay-decentralized-noncustodial-payment-gateway-126944216

What Can You Built?

Endless imagination! With your choice of programming language, you can integrate AtomicPay cryptocurrency payment solution into Vending Machines, Smart TV apps, Point-of-Sale Systems, Games, Mobile Apps with in-store purchases, Paywalls for media sites and lots more. Do share with us, if you are building anything with AtomicPay API.

Here are some Open Source ecommerce plugins that we built with AtomicPay API: WooCommerce, PrestaShop, OpenCart

Documentation

Full & Comprehensive API Documentation is available on the AtomicPay website.

Getting Started

Developers do not need to install additional libraries or softwares. Developers may call the API directly over HTTPS via protocol methods GET, PUT, POST and DELETE to perform operations, using the language of their choice.

In order to use AtomicPay Restful interface, you will need to sign up for an API key. More information at https://atomicpay.io/api/en

Getting Access

Authorization in AtomicPay's API utilizes a set of revocable API Keys. Each API call must be accompanied by an Authorization header that include either a public or private API Key which grants access to perform specific operations.

You can retrieve the API keys by login to merchant control panel -> API Integration page. If your key becomes compromised, you may revoke the keys by regenerating new set of keys.

To access any resource URI, an API Key will need to be sent within the HTTP headers Authorization: BASIC {AccountID}:{APIKey} encoded in base64 over SSL along with the API body request.

Making Requests

Requests to the AtomicPay REST API follow the RESTful convention using standard HTTP protocols against AtomicPay resources URI to return JSON formatted responses. IMPORTANT: (AccountID:APIKey) must be encoded in base64

Except for Authorization endpoint, each request MUST include in the HTTP headers:

  • Authorization: BASIC {AccountID}:{APIKey}
  • Content-Type: application/json

To make an API request, simply send an HTTP request with a HTTP method to a resource URI and include in the body JSON parameters of any additional parameters required.

IPN / Webhooks

Instant Payment Notification (IPN) or webhook is a message service that automatically notifies merchants of events related to AtomicPay transactions. Merchants can use it to automate back-end and administrative functions, including automatically fulfilling orders and providing customers with order status. For more information about IPN / Webhooks, please visit our API IPN/Webhooks Documentation.

Here is an example of the JSON data in the IPN message: { "invoice_id":"DBVZzHMxjjfdRZYeignEZC", "order_id":"1235425", "fiat_price":"1.00", "fiat_currency":"USD", "payment_currency":"BTC", "payment_rate":"4,192.00", "payment_address":"bc1qmtyax97phenvvs3sdg5r45kdcphd", "payment_total":"0.00023855", "payment_paid":"0.00023855", "payment_due":"0.00000000", "payment_txid":"14edecbf114f2b2e73cf7470916122286506de5", "payment_confirmation":"At least 6", "status":"complete" "statusException":"null" }

Resources URI

Below is a list of resources URI endpoints. For more information about specific resource URIs, please visit our API Resource Documentation.

Authorization

Authorization endpoint URI allows client to validate the authentication of API Keys.

Method URI Endpoint
POST https://merchant.atomicpay.io/api/v1/authorization

For detailed schema, parameters, code snippet and returned responses, read Authorization Resource Documentation

Account

Account endpoint URI allows client to retrieve or update account details of merchant's AtomicPay account.

Method URI Endpoint
GET https://merchant.atomicpay.io/api/v1/account
PUT https://merchant.atomicpay.io/api/v1/account

For detailed schema, parameters, code snippet and returned responses, read Account Resource Documentation

Billing

Billing endpoint URI allows client to retrieve details of a specific bill or a list of bills for the merchant account filtered by query.

Method URI Endpoint
GET https://merchant.atomicpay.io/api/v1/billing
GET https://merchant.atomicpay.io/api/v1/billing/:bill_id

For detailed schema, parameters, code snippet and returned responses, read Billing Resource Documentation

Currencies

Currencies endpoint URI allows client to retrieve fiat currencies that are supported by AtomicPay

Method URI Endpoint
GET https://merchant.atomicpay.io/api/v1/currencies
GET https://merchant.atomicpay.io/api/v1/currencies/:currency

For detailed schema, parameters, code snippet and returned responses, read Currencies Resource Documentation

Invoices

Invoices are time-sensitive payment requests. An invoice has a fixed price, typically denominated in fiat currency. AtomicPay will automatically convert this fiat amount into cryptocurrency of equivalent value, based on real-time average cryptocurrency market rate, along with a preset time period for payment expiration.

Method URI Endpoint
GET https://merchant.atomicpay.io/api/v1/invoices
GET https://merchant.atomicpay.io/api/v1/invoices/:invoice_id
POST https://merchant.atomicpay.io/api/v1/invoices

For detailed schema, parameters, code snippet and returned responses, read Invoices Resource Documentation

PayURL

PayURL endpoint URI allows client to retrieve, create, update and delete PayURLs of merchant account.

Method URI Endpoint
GET https://merchant.atomicpay.io/api/v1/payurl
GET https://merchant.atomicpay.io/api/v1/payurl/:url_id
POST https://merchant.atomicpay.io/api/v1/payurl
PUT https://merchant.atomicpay.io/api/v1/payurl/:url_id
DELETE https://merchant.atomicpay.io/api/v1/payurl/:url_id

For detailed schema, parameters, code snippet and returned responses, read PayURL Resource Documentation

Rates

Rates endpoint URI allows client to retrieve real-time exchange rates between a base fiat currency and merchant's supported cryptocurrencies.

Method URI Endpoint
GET https://merchant.atomicpay.io/api/v1/rates/:base_currency

For detailed schema, parameters, code snippet and returned responses, read Rates Resource Documentation

Transactions

Transactions endpoint URI allows client to retrieve a list of transactions for the merchant account filtered by query.

Method URI Endpoint
GET https://merchant.atomicpay.io/api/v1/transactions

For detailed schema, parameters, code snippet and returned responses, read Transactions Resource Documentation

Contributions & Developments

Anyone and everyone is welcome to contribute or develop libraries for the programming languages. Please take a moment to review the guidelines for contributing to AtomicPay API Client.

License

AtomicPay is released under the MIT License. Please refer to the License file that accompanies this project for more information including complete terms and conditions.