Skip to content

Getting Started

Benedikt Schulze Baek edited this page Mar 8, 2017 · 29 revisions

This is a Step-By-Step Getting Started, that will help you setting up your first running projects using chayns® and the chayns® Backend API.

Requirements

  • chayns® site (free)
  • chayns® partner account (tspn)
  • webserver (local-)
  • Microsoft Visual Studio

Step 1 - Clone the project

Clone or download the project from this repository.
Make sure that the index.html file located in the 'GetLocationInfo' folder can be reached through the WWW.

Step 2 - Create a developer tapp

Go to the tapp administration and register a new tapp. Call it whatever you want, but in the url field, point at the index.html mentioned in the last step.
Select the required permission PublicInfo (The required permissions are listed for each api endpoint in the reference).
Note the tapp secret and installation code.
The secret is required for authorization later on, the installation code is used to install this developer tapp on any chayns site.

Step 3 - Installing the tapp

On your chayns site, go to the configuration -> Tapps -> Add Tapp -> External

These permissions are fundamental to the chayns Backend API, since they are required in every request to the API (the required permissions for each request are listed in the specific reference. In the tapp administration just select all the permissions you need).
The current available permissions are

  • PublicInfo
  • UserInfo
  • SeeUAC
  • EditUAC
  • DeviceInfo
  • Push
  • Intercom
  • Mail

Structure

The requests in frontend and backend have the same structure. For the authorization you can use the Tapp Secret along with the TappID in the backend or a PageAccessToken in the frontend. (Take a look at Authorization )

The request structure looks like

https://api.chayns.net/{APIVersion}/{LocationID}/{Controller}/{ObjectID} 
  • the ApiVersion is a compound of the letter 'v' and the API version. I.e. it could look like 'v2.0'
  • the ObjectID parameter is optional (see references)

In addition it is possible to filter your GET requests with fields and filters. Take a look at this page for more information on parameters, fields and filters.

Clone this wiki locally