Getting started with Openprovider API

Who is Openprovider

Openprovider is a wholesaler of Internet services and products with a unique platform from which you can find and manage all the products you need: Domains, new gTLDs, SSL certificates, licenses for Plesk and Virtuozzo, spam filters, and more! 

Getting started

Quick Start Guide to our API

You can find our new Quick Start Guide to our API with just one click here!

 

Openprovider API gives access to the entire Openprovider infrastructure via a standardised interface based on OpenAPI Specification. With the help of Openprovider's API, you can do just about anything you can do in Reseller Control Panel.

The Openprovider API is a RESTful API based on HTTPS requests and JSON responses. If you have your Openprovider account, you can obtain your API authentication token via the following endpoint:

POST https://api.openprovider.eu/v1beta/auth/login

NB: API token TTL is 48 hours

Endpoints

Openprovider API is accessed by making HTTPS requests to a specific version endpoint URL, in which GET, POST, PUT, and DELETE methods dictate how your interact with the available data. Every endpoint is accessed only via the SSL-enabled HTTPS (port 443) protocol.

Be noted that in order to maintain compatibility in the future, all requests must specify an API version, which is appended to the URL. The latest version is v1beta and the base URL for this version's endpoint is:

https://api.openprovider.eu/v1beta/

Authentication

At its current state Openprovider API only supports Bearer Authentication which involves acquiring security tokens that are then passed in a request. This token must be sent in the Authorization header when making requests to protected resources:

Authorization: Bearer <token>

Bearer authentication

curl -X POST \
https://api.openprovider.eu/v1beta/auth/login \
-d '{"username": "user", "password": "******", "ip": "0.0.0.0"}'
{
"data": {
"token": "6f6d86377bc******feb75cea76d8e8b",
"reseller_id": 100001
}
}

Where,

username: API/account username (same as RCP username). 

password: API/account password (same as RCP password of the user). 

ip: Public IP address from which you will be sending API requests (optional field).

Note: If there are multiple contacts (admin/tech/billing) under the reseller account, decide which account/contact you want to use for API connection/integration and use its username and password.

Responses

All successful responses will be returned as a JSON object with at least one key: data.

The data element will contain either a single JSON object or a list of JSON objects, depending on the endpoint.

{
"data": {
"id": 11195838,
"status": "ACT",
"activation_date": "2019-06-27 04:22:39",
"renewal_date": "2020-06-25 04:22:39",
"expiration_date": "2020-06-27 04:22:39",
"auth_code": "*******"
},
}

Moving to Production

You can view here how to enable your API Access.

Was this article helpful?
Additional questions? Submit a request