Create an account or sign in:
Login
Forgot password?
LOGIN
API Reference

Coinetize provides REST endpoints to enable install plugins to be created for any CMS. Note the functionality of this is intended for the website linking in process - we do not provide a full payments API.

API URL https://api.coinetize.com

BASIC PARAMETERS

The following basic parameters should be passed with every call:

username The username of the Coinetize website owner
auth_token The Authentication token of the website owner (as found on the Coinetize profile page)
timestamp The unix timestamp (ie seconds past the epoch)
signature

The HMAC SHA256 hash (in uppercase hex format) of

<username><endpoint><timestamp>

(3 variables are concatenated with no spaces between. Endpoint should include the leading '/' but with no trailing slash or parameters)

Sign this using the auth_token.

Refer to endpoint information for additional endpoint specific parameters.

ENDPOINTS:

POST /link_website

Link a website to Coinetize

Parameters:

websiteThe (source) website to link. If link_method = 'dns' this is probably an IP address. For other methods this could be an IP or a domain name.
dns_websiteOnly specify this for link_method = 'dns'. This is the domain name (e.g. www.example.com)
subdomainUsually do not include this. If this is included, Coinetize will attempt to modify the existing information associated with this domain name to the new link information. e.g. you could change an existing subdomain to a new link method by including this. However, for new website links this should not be included.
protocolOptional. At the current time only 'http' links have been tested
pathUsually omit this. This is only relevant for websites that are located at a path other than /. e.g. if you have a website installed at www.example.com/some-path/ then you should specify the path as '/some-path'. Include the leading but not the trailing '/'.
portThe port. This only needs specifying for non-standard ports. For http, if the port is 80 this does not need to be included. For https, if the port is 443 this does not need to be included
link_methodthe link method to use. Choices are 'dns', 'proxy' or 'redirect'

Example Responses:

error:

{
    "status": "error", 
    "message": "<error message>"
}

success:

{
    "status": "success", 
    "link_verification_filename": "<filename>", 
    "verification_code": "<verification_code>",
    "subdomain": "<subdomain>"
}

It is important that your process remembers whatever is returned in as this is used to identify your site in all future calls. You will need the verification_code for the /verify_website step. If you are using file verification, you should put the code in the file '.txt' which you should place in your document root.

POST /verify_website

Verify you are the owner of a website you've linked to Coinetize. Only applicable for websites which have been linked but not verified.

Parameters:

subdomainThe subdomain to verify
v_fileOptional. The filename that will contain the verification code (not including the .txt extension). If this is not specified, Coinetize will look for the meta tag first, then for the default filename as returned by /link_website.

Example Responses:

error:

{
    "status": "error", 
    "message": "<error message>"
}

success:

{
    "status": "success",
    "message": "Subdomain <subdomain> successfully verified"
}

POST /unlink_website

Unlink a website that was linked previously. Both verified and unverified websites can be unlinked.

parameters:

subdomainThe subdomain to unlink

Example Responses:

error:

{
    "status": "error", 
    "message": "<error message>"
}

success:

{
    "status": "success",
    "message": "Subdomain <subdomain> unlinked"
}

POST /add_path

Add a path to a verified website. Only applicable to the 'proxy' and 'redirect' link methods

Parameters:

subdomainThe subdomain to add the new path
pathThe path to link. This should include a leading but not a trailing '/'

Example Responses:

error:

{
    "status": "error", 
    "message": "<error message>",
    "deleted_paths": [],
    "enabled_paths": ['/sample-path']
}

success:

{
    "status": "success",
    "deleted_paths": [],
    "enabled_paths"	: ['/sample-path']
}

POST /remove_path

Remove a path from a verified website. Only applicable to the 'proxy' and 'redirect' link methods

Parameters:

subdomainThe subdomain to add the new path
pathThe path to remove. This should include a leading but not a trailing '/'

Example Responses:

error:

{
    "status": "error", 
    "message": "<error message>",
    "deleted_paths": [],
    "enabled_paths": ['/sample-path']
}

success:

{
    "status": "success",
    "deleted_paths": [],
    "enabled_paths"	: ['/sample-path']
}

GET /list_paths

List linked paths for a verified website. Only applicable to the 'proxy' and 'redirect' link methods

Parameters:

subdomainList paths for this subdomain

Example Responses:

error:

{
    "status": "error", 
    "message": "<error message>"
}

Success:

{
    "status": "success",
    "deleted_paths": [],
    "enabled_paths": ["/sample-path"]
}

GET /review

Return the code needed to go in .htaccess ('dns','proxy','redirect' link_methods). Return the DNS A Record details (link_method DNS)

Parameters:

subdomainList review information for this subdomain

Example Responses:

error:

{
    "status": "error", 
    "message": "<error message>"
}

success:

{
    "status" : "success", 
    "a_record": { 
        "ip_address" : "<ip_address>" , 
        "website" : "<website>" 
    },
    "htaccess_code" : "Options +FollowSymLinks\nRewriteEngine..."
}