stoutfiles edited this page Feb 14, 2018 · 4 revisions

Ready to enable your app?

KnetikCloud is THE engine that provides a complete backend-as-a-service for your games and apps.

Start using our REST APIs immediately by quickly setting up your own application.

https://[YOUR_DOMAIN].sandbox.knetikcloud.com

You can also start setting up your data by visiting your control panel at

https://[YOUR_DOMAIN].sandbox.knetikcloud.com/admin

Coding KnetikCloud Clients

Log in to your control panel and create a client key. A client key will allow your application to authenticate with KnetikCloud.

  • Use a public client for apps which might expose the keys. Public clients don't require a secret to be provided.
  • Use the password grant type when your users authenticate directly with KnetikCloud, client credentials for server-to-server communications
  • If you chose the client credentials grant type, you need to assign a role to your client. You can use an existing one or create on with limited permissions

You can now connect using the chosen authentication method as described in the authentication section.

KnetikCloud uses a standard stateless REST interface over HTTPS. Detailed API specifications are provided by Swagger UI. You can also use the Swagger specifications in JSON format at the following URL to automatically import all the KnetikCloud endpoints into Postman or generate your own SDKs using the Swagger CodeGen project.

https://sandbox.knetikcloud.com/swagger-doc

Your First Request

The following example requests a list of countries by calling one of the public endpoint (hence the abscence of an authentication token)

Curl

curl -X GET --header 'Accept: application/json' 'http://sandbox.knetikcloud.com/location/countries'

Request URL

http://sandbox.knetikcloud.com/location/countries

Request Headers

{
  "Accept": "application/json"
} 

Response Body

[
  {
    "name": "Afghanistan",
    "iso2": "AF",
    "iso3": "AFG"
  },
  {
    "name": "Albania",
    "iso2": "AL",
    "iso3": "ALB"
  },
  ...
]

Response Code

200

Response Headers

{
  "pragma": "no-cache",
  "date": "Thu, 23 Feb 2017 04:02:44 GMT",
  "x-content-type-options": "nosniff",
  "content-type": "application/json;charset=UTF-8",
  "cache-control": "no-cache, no-store, max-age=0, must-revalidate",
  "content-length": "11608",
  "x-xss-protection": "1; mode=block",
  "x-application-context": "KnetikCloud:remote",
  "expires": "0"
}

API breakdown

Within Swagger UI, endpoints are organized in modules and resources. A resource is an object exchange between the client and the server, usually a concrete object like a User or a Challenge. We try to keep related resources close together in the documentation.

Each line can be expanded to reveal the module endpoints, typically a series of CRUD operations using (POST, GET, PUT, DELETE respectively), on the specific modules resource(s). Some additional endpoints might be available for non-standard operations.

Clone this wiki locally
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.