Download OpenAPI specification:Download
InPlayer equips you to run a detailed subscription business model, to build and grow your consumer base, and drive significant revenues. Our paywall supports recurring payments and billing cycles, consumer acquisition, subscriber lifecycle management, and provides you with consumer retention CRM tools.
Once you create an InPlayer Merchant Account, you are entitled to using our InPlayer dashboard for publishing, managing, and selling your premium content. Moreover, you can always integrate with our APIs for a full custom integration.
The InPlayer API follows the REST architectural style and uses standard HTTP response codes to indicate success requests (2xx) or API errors (4xx, 5xx). Each of the InPlayer Core Resources (Accounts & Authentication, Asset & Access, Payments & Subscriptions, Vouchers & Promotions, Branding, Restrictions & Rules, Reporting, Analytics, and Features) has their own URL and each of the operations involved (POST
, PUT
, PATCH
, GET
, and DELETE
) carries a specific meaning like creating, updating, fetching, deleting data, and much more.
All API requests should contain Content-Type:application/x-www-form-urlencoded header. The responses are always returned in JSON object(s), both for the successful requests and the failed attempts (errors).
The following section defines the domain language used across our platform. Proceed reading to introduce yourself to the terms employed for each of our Core Resources before you start working on your custom integration.
Accounts and Account Types
Term | Explanation |
---|---|
merchant | The Merchants are those who have ownership of the premium content. |
consumer | The Consumers are those who can view or buy the premium content. |
customer | The Customers are those who have made at least one purchase. |
uuid | Stands for the Unique Identifier of the Merchant. You can find it on the InPlayer's dashboard at the Account Details section as Account ID. |
To make the API as explorable as possible, we have two different environments for production related and testing purposes. There is no switch for changing between modes, so just refer to the URL you need.
InPlayer uses conventional HTTP response codes to indicate the success or failure of an API request. In general, codes in the 2xx range indicate success, codes in the 4xx range indicate an error that failed given the information provided (e.g. a required parameter was omitted, a charge failed, etc.), and codes in the 5xx range indicate an error with InPlayer's servers.
Not all errors map cleanly onto HTTP response codes, however. For instance, when a request is valid but does not complete successfully (e.g. if asset access is not found), we return a 402 error code.
List of status codes
Status code | Explanation |
---|---|
200 | OK Everything worked as expected. |
201 | Created The resource has been created. |
202 | Accepted The request has been accepted for processing, but the processing has not been completed. |
204 | No Content The server has fulfilled the request but does not need to return an entity-body. |
400 | Bad Request The request was unacceptable, often due to omission of a required parameter. |
401 | Unauthorized No valid access token has been provided. |
402 | Request Failed The parameters were valid but the request failed. |
404 | Not Found The requested resource does not exist. |
409 | Conflict The request conflicts with another request. |
429 | Too Many Requests Too many requests have been sent to the API in a short amount of time. We recommend using exponential backoff for your requests. |
500, 502, 503, 504 | Server Errors Something went wrong on InPlayer's end. |
Returns all the relevant information about a given account.
curl https://services.inplayer.com/accounts \ -H "Authorization: Bearer <token>"
{- "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
Registers a new InPlayer account.
full_name required | string The first and last name of the merchant |
username required | string The email address of the merchant |
password required | string <password> Password containing minimum 8 characters |
password_confirmation required | string <password> The same password with minimum 8 characters |
type required | string Enum: "consumer" "merchant" Account types: "consumer", "merchant" |
grant_type | string Enum: "password" "client_credentials" "refresh_token" The type of grant required to gain access token |
client_id required | string <string> The merchant's OAuth application ID |
referrer | string The request’s source URL |
date_of_birth | string <date-time> Customer's birthdate Unix timestamp; conditionally required in case the merchant has enabled the 'age verification' feature. |
Array of objects |
curl https://services.inplayer.com/accounts \ -d full_name="John Doe" \ -d username=john@example.com \ -d password=foobar123 \ -d password_confirmation=foobar123 \ -d type=consumer \ -d grant_type=password \ -d client_id=507d866c-4e33-445d-b027-f163d0099f54 \ -d metadata[phone]=bar
{- "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c",
- "refresh_token": "def502006e2148f8751c7e7cfa58a91d7ecccdd6ac1648abe2fcf506e72729d4ca48a956ffe5a4afadd96e1e91c0d055262c66a3ce840e96e3542a33adbc657ed5b5810f87b130149308a9d73f5",
- "account": {
- "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
}
Deactivates a customer account.
customerID | integer Account's id |
curl -X DELETE https://services.inplayer.com/accounts \ -H "Authorization: Bearer <token>"
{- "code": 0,
- "message": "string",
- "errors": {
- "property1": "string",
- "property2": "string"
}
}
Updates an account.
id | integer The account ID of a customer, necessary for the merchant to pass it in when updating a customer’s account. ID parameter is required when updating admin account. |
full_name required | string The full name of the account |
referrer | string The request’s source URL |
date_of_birth | string <date-time> Customer's birthdate Unix timestamp conditionally required in case if the merchant has enabled the 'age verification' feature. |
Array of objects |
curl -X PUT https://services.inplayer.com/accounts \ -H "Authorization: Bearer <token>" \ -d full_name="Jane Doe" \ -d metadata[foo]=bar
{- "code": 404,
- "message": "Account not found"
}
Starts the account activation process by sending an email containing the activation token and link for the account activation.
email required | string The account’s email address |
merchant_uuid required | string <uuid> The universal unique identifier from the account |
curl https://services.inplayer.com/accounts/activate \ -d email=john@example.com \ -d merchant_uuid=528b1b80-5868-4abc-a9b6-4d3455d719c8
{- "message": "Please check your email for your account activation code.",
- "code": 201
}
Returns all the followers created by the logged in (master) account.
[- {
- "id": 21,
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "country": "MK",
- "active": true,
- "merchant_id": 123,
- "is_master": false,
- "scopes": [
- "string"
], - "created_at": 1531482438
}
]
Creates new oAuth app
name | string oAuth app name |
curl -X POST https://services.inplayer.com/accounts/apps \ -H "Authorization: Bearer <token>" \ -d name="Foo"
{- "account_id": 12345,
- "name": "Foo",
- "active": 1,
- "grantTypes": "password",
- "default": 1,
- "sso": 0
}
curl -X GET https://services.inplayer.com/accounts/apps \ -H "Authorization: Bearer <token>"
{- "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
Deletes oAuth app
id required | integer oAuth app id |
curl -X DELETE https://services.inplayer.com/accounts/apps/{id} \ -H "Authorization: Bearer <token>"
{- "code": 200,
- "message": "App was successfully deleted."
}
Updates oAuth app
id required | integer oAuth app id |
active | bool Set app status |
sso | bool Sso must be of bool type and must not be empty |
grant_types | Array of strings |
name | string Account's name, max 50 characters long |
redirect_uris | Array of strings |
curl -X PUT https://services.inplayer.com/accounts/apps/{id}\ -H "Authorization: Bearer <token>" \ -d active = "true" \ -d sso = "true" \ -d grant_types[0]="password" \ -d name = "Foo" \ -d redirect_uris[0] = "http://foobar.com"
{- "id": 12345,
- "account_id": 12345,
- "name": "Foo",
- "active": 1,
- "grantTypes": "password",
- "default": 1,
- "sso": 0
}
Updates oAuth app's secret
id required | integer oAuth app id |
curl -X PUT https://services.inplayer.com/accounts/apps/{id}/secret \ -H "Authorization: Bearer <token>"
{- "secret": "24426fe8d9ad21c70eccd7d9a92c860850975192dd7e40bf3239130a4348a0a0"
}
Authenticates an account by creating an access token that can be used for future requests.
username required | string The email address of the account, in case the grant type is password. |
password required | string <password> The account password, in case the grant type is password |
grant_type required | string Enum: "password" "client_credentials" "refresh_token" With the grant type you can switch between authentication types. |
client_id required | string The Merchant's OAuth application ID |
referrer | string The request’s source URL |
curl -X POST https://services.inplayer.com/accounts/authenticate \ -d client_id="528b1b80-5868-4abc-a9b6-4d3455d719c8" \ -d grant_type=client_credentials \ -d client_secret=foobar \ -d referrer='https://inplayer.com'
{- "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c",
- "refresh_token": "swKbldciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adWAdzCa",
- "account": {
- "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
}
Replaces the account's password with a new one.
password required | string <password> The account's new password. |
password_confirmation required | string <password> The account's new password, required for confirmation. |
old_password required | string <password> The account's old password. |
curl https://services.inplayer.com/accounts/change-password \ -H 'Authorization:Bearer <Access-Token>' \ -d old_password=foo \ -d password=secret \ -d password_confirmation=secret
{- "code": 401,
- "message": "Invalid auth token"
}
Erases an account (and all the all personal details contained) permanently.
customer_id required | integer The ID of the customer account (if the operation has been invoked by a merchant) |
password required | string Password confirmation |
curl -X DELETE https://services.inplayer.com/accounts/erase \ -H 'Authorization:Bearer <Access-Token>' \ -d password=foobar
{- "code": 400,
- "message": "The account does not exist"
}
Exports account data such as logins, payments, subscriptions, access to assets etc. After invoking the request, the account receives the data in a json format via e-mail.
password required | string Password of the current logged in user |
curl -X POST https://services.inplayer.com/accounts/export \ -H 'authorization: Bearer Access-Token' \ -H 'content-type: application/x-www-form-urlencoded' \ -d password=123456 \
{- "message": "Your data has been successfully exported. You will receive an email shortly.",
- "code": 200
}
The first step in change password functionality. After this call, you will receive a valid token for password reset, via email. Then you will need to complete the change password operation with the provided token.
merchant_uuid required | string The UUID of the parent merchant account |
email required | string The email address of the account. |
curl https://services.inplayer.com/accounts/forgot-password \ -d email=example@mail.com \ -d merchant_uuid="507d866c-4e33-445d-b027-f163d0099f54"
{- "code": 200,
- "message": "Please check your email"
}
Using the generated forgot password token, you can call this method to update your password.
token required | string The generated token sent to your email address |
password required | string <password> The new password of the account. |
password_confirmation required | string <password> The password confirmation. |
branding_id | integer optional branding ID in case branding themes feature is used |
curl -X PUT https://services.inplayer.com/accounts/forgot-password/{token} \ -d password=secret \ -d password_confirmation=secret
{- "code": 422,
- "message": "Invalid input",
- "errors": {
- "password": "The password must be atleast 8 characters long",
- "password_confirmation": "The password confirmation does not match"
}
}
Login as one of master's followers
sign_in_as required | integer Follower's account id |
uuid required | string Merchant's uuid of the follower |
client_id required | string |
email required | string Email address of the follower you want to log in |
grant_type required | string Value: "social" Grant type |
password required | string Password of the current logged user |
curl -X POST https://services.inplayer.com/accounts/impersonate \ -H 'authorization: Bearer Access-Token' \ -H 'content-type: application/x-www-form-urlencoded' \ -d sign_in_as=123 \ -d email="john@example.com" \ -d grant_type="social" \ -d client_id="528b1b80-5868-4abc-a9b6-4d3455d719c8" \ -d uuid="528b1b80-5868-4abc-a9b6-4d3455d719c8&password=inplayer123" \
{- "master_id": 21,
- "follower_id": 123,
- "scopes": [
- "string"
], - "created_at": 1531482438
}
Creates a follower merchant account that can inherit merchant settings such as scopes and payment methods.
follower_id | integer The account ID of the follower merchant (needed for an existing account) |
scopes | Array of strings Set of actions or settings that the master account provides for the follower |
Array of objects The payment methods that can either be active or inactive, as determined by the master merchant |
curl -X POST https://services.inplayer.com/accounts/merchants \ -H 'authorization: Bearer Access-Token' \ -H 'content-type: application/x-www-form-urlencoded' \ -d full_name="John Doe" \ -d email="john@example.com" \ -d password="foobar123" \ -d master_id=123 \ -d scopes[0]="inheritance" \ -d methods[12]=true \
{- "access_token": "eyJhbGciOiJIUzI1NiIsInUj6CI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c",
- "account": {
- "master_id": 312,
- "scopes": [
- "string"
], - "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
}
Updates followers’ settings (scopes and methods).
follower_id required | integer Follower's account id |
scopes required | Array of strings The set of settings and actions the master merchant is updating for their follower |
Array of objects |
curl -X PUT https://services.inplayer.com/accounts/merchants/relation \ -H 'authorization: Bearer Access-Token' \ -H 'content-type: application/x-www-form-urlencoded' \ -d follower_id=123 \ -d scopes[0]="inheritance" \ -d methods[7]=false \
{- "master_id": 21,
- "follower_id": 123,
- "scopes": [
- "string"
], - "created_at": 1531482438
}
Deletes master-follower relation
follower_id required | integer Follower's account id |
curl -X DELETE https://services.inplayer.com/accounts/merchants/relation \ -H 'authorization: Bearer Access-Token' \ -H 'content-type: application/x-www-form-urlencoded' \ -d follower_id=123 \
{- "code": 200,
- "message": "Deleting relation was successful."
}
Creates new register field
name | string register field name |
label | string register field label |
type | string register field type |
default_value | string register field default value |
placeholder | string register field placeholder |
required | integer register field required |
curl -X POST https://services.inplayer.com/accounts/register-field \ -H "Authorization: Bearer <token>" \ -d name="Foo" \ -d label="Bar" \ -d type="Foo Bar" \ -d default_value="Foobar" \ -d placeholder="Baz" \ -d required=1
{- "code": 201,
- "message": "Successfully Created.",
- "id": 2
}
Updates register field
id required | integer register field id |
name | string register field name |
label | string register field label |
type | string register field type |
default_value | string register field default value |
placeholder | string register field placeholder |
required | integer register field required |
curl -X PUT https://services.inplayer.com/accounts/register-field \ -H "Authorization: Bearer <token>" \ -d id=123 \ -d name="Foo" \ -d label="Bar" \ -d type="Foo Bar" \ -d default_value="Foobar" \ -d placeholder="Baz" \ -d required=1
{- "code": 200,
- "message": "Update Successful.",
- "id": 2
}
id required | integer Register field id |
curl -X DELETE https://services.inplayer.com/accounts/register-field/{id} \ -H "Authorization: Bearer <token>" \
{- "code": 200,
- "message": "Field was successfully deleted."
}
merchant_uuid required | string <uuid> Example: 528b1b80-5868-4abc-a9b6-4d3455d719c8 Merchant uuid |
curl -X GET https://services.inplayer.com/accounts/register-fields/{merchant_uuid}
{- "id": 44,
- "name": "gender",
- "label": "Gender",
- "type": "select",
- "required": true,
- "default_value": "male",
- "placeholder": "Gender",
- "options": [
- {
- "string": "String"
}
]
}
Returns a collection of registered users
search | Array of arrays Search by title, id, merchant_id or merchant_uuid. e.g. ?search[]=title:exampleTitle |
page | integer Page number |
size | integer Number of results |
active | string Only active or all users |
curl https://services.inplayer.com/accounts/registered-users \ -H "Authorization: Bearer <token>"
{- "total": 1599,
- "collection": [
- {
- "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
]
}
Returns list of social button URLs
state required | string Example: state=eyJjbJulbnR0dHA6Ly9sb2NskOvc3Q6ODA4MC8/aXB3PTEmYXNzZXRfaWS9sMDczNzQifQ== State token from the social service |
curl https://services.inplayer.com/accounts/social?state=eyJjbJulbnR0dHA6Ly9sb2NskOvc3Q6ODA4MC8/aXB3PTEmYXNzZXRfaWS9sMDczNzQifQ== \ -H 'Authorization: Bearer <token>'
{- "social_urls": [
- {
}
]
}
Returns all the relevant information about a given account.
curl https://services.inplayer.com/v2/accounts \ -H "Authorization: Bearer <token>"
{- "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
Registers a new InPlayer account.
full_name required | string The first and last name of the merchant |
username required | string The email address of the merchant |
password required | string <password> Password containing minimum 8 characters |
password_confirmation required | string <password> The same password with minimum 8 characters |
type required | string Account type. Example: consumer |
grant_type | string The type of grant required to gain access token. Example: password |
client_id required | string <string> The merchant's OAuth application ID |
referrer | string The request’s source URL |
date_of_birth | string <date-time> Customer's birthdate Unix timestamp; conditionally required in case the merchant has enabled the 'age verification' feature. |
Array of objects |
curl -X POST https://services.inplayer.com/v2/accounts \ -d full_name="John Doe" \ -d username=john@example.com \ -d password=foobar123 \ -d password_confirmation=foobar123 \ -d type=consumer \ -d grant_type=password \ -d client_id=507d866c-4e33-445d-b027-f163d0099f54 \ -d metadata[phone]=bar
{- "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c",
- "expires_at": 1615381572,
- "account": {
- "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
}
Authenticates an account by creating an access token that can be used for future requests.
username required | string The email address of the account. |
password required | string <password> The account password |
grant_type required | string Value: "password" Grant type |
client_id required | string The Merchant's OAuth application ID |
curl -X POST https://services.inplayer.com/v2/accounts/authenticate \ -d client_id="528b1b80-5868-4abc-a9b6-4d3455d719c8" \ -d grant_type=password \ -d client_secret=foobared
{- "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c",
- "account": {
- "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
}
This endpoint allows a merchant, using their token to create a customer account
email required | string The email address of the account |
full_name | string The first and last name of the account |
password | string <password> Password containing minimum 8 characters |
referrer | string The request’s source URL |
Array of objects |
curl https://services.inplayer.com/v2/accounts/customers \ -H 'authorization: Bearer Access-Token' \ -H 'content-type: application/x-www-form-urlencoded' \ -d email=john@example.com \
{- "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c",
- "expires": 1531482438,
- "account": {
- "id": 21,
- "email": "example-email@inplayer.com",
- "created_at": 1531482438,
- "updated_at": 1531482438
}
}
Creates livelike account
item_id required | int |
nickname | string Nickname (Optional) |
curl -X POST https://services.inplayer.com/v2/accounts/external/livelike \ -H 'authorization: Bearer Access-Token' \ -H 'content-type: application/x-www-form-urlencoded' \ -d item_id=123 \ -d nickname=john
{- "code": 200,
- "message": "Successfully created livelike account."
}
Updates livelike account
nickname required | string |
curl -X PATCH https://services.inplayer.com/v2/accounts/external/livelike \ -H 'authorization: Bearer Access-Token' \ -H 'content-type: application/x-www-form-urlencoded' \ -d nickname=john
{- "code": 200,
- "message": "Successfully updated livelike account."
}
Logs the master in as one of their followers.
customer_id required | int The ID of the customer's account (required when the operation is invoked by a merchant). |
curl https://services.inplayer.com/v2/accounts/impersonate \ -H 'authorization: Bearer Access-Token' \ -H 'content-type: application/x-www-form-urlencoded' \ -d customer_id=20456 \
{- "access_token": null,
- "expires": 1531482438,
- "account": {
- "id": 21,
- "uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "merchant_uuid": "528b1b80-5868-4abc-a9b6-4d3455d719c8",
- "email": "example-email@inplayer.com",
- "full_name": "John Doe",
- "metadata": { },
- "social_apps_metadata": [
- { }
], - "roles": [
- "merchant"
], - "completed": true,
- "date_of_birth": 1531482438,
- "created_at": 1531482438,
- "updated_at": 1531482438,
- "expired_at": 1531482438
}
}
Creates pin code and sends it to your email
branding_id | int Branding ID (optional, in case branding themes feature is used) |
curl https://services.inplayer.com/v2/accounts/pin-codes/send -H "Authorization: Bearer <token>" -d "branding_id=1"
{- "code": 200,
- "message": "Please check your email for your pin code."
}
Checks validity of pin code
pin_code required | string The code a customer needs to enter in order to be able to watch the content behind the paywall, as an additional authentication step. The pin code is automatically sent to the customer via email, as soon as they log into the paywall. |
curl https://services.inplayer.com/v2/accounts/pin-codes/validate -H "Authorization: Bearer <token>" -d 'pin_code=A5RS2'
{- "code": 200,
- "message": "The pin code is valid"
}