Manual Integration

If your platform is not supported, you can integrate with us manually by making HTTP requests to our API using any HTTP client.

Authentication

You can make a request to our API using any HTTP client by following the API documentation below

Initialize SDK Session

post
Query parameters
langstringOptionalExample: en
Header parameters
X-Api-KeystringRequiredExample: YOUR_API_KEY
X-Api-SecretstringRequiredExample: YOUR_API_SECRET
X-SDK-PlatformstringRequiredExample: Web
X-SDK-VersionstringRequiredExample: 3.0
Body
publisherUserIdstringRequired

Publisher User/Customer unique ID

Example: user_id_1
agenumber | nullableOptional

User age

Example: 20
gendernumber | nullableOptional

User gender, 1=male, 2=female

Example: 1
emailstring | nullableOptional

User email

Example: [email protected]
phoneNumberstring | nullableOptional

User phone

Example: 6281234567890
identifierTypestring · enum | nullableOptional

Device Identifier/Advertising ID Type

Possible values:
identifierstring | nullableOptional

Device Identifier/Advertising ID

Example: 28dde889-530f-4a8e-b427-953077c40772
sub1string | nullableOptional
sub2string | nullableOptional
sub3string | nullableOptional
sub4string | nullableOptional
sub5string | nullableOptional
userGroupstring | nullableOptional
mediaSourceNamestring | nullableOptional
mediaSourceIdstring | nullableOptional
mediaSubSourceIdstring | nullableOptional
incentivizedboolean | nullableOptional
mediaAdsetNamestring | nullableOptional
mediaAdsetIdstring | nullableOptional
mediaCreativeNamestring | nullableOptional
mediaCreativeIdstring | nullableOptional
mediaCampaignNamestring | nullableOptional
Responses
200

Successful operation

application/json
post
POST /v3.0/auth HTTP/1.1
Host: api.tyrads.com
X-Api-Key: text
X-Api-Secret: text
X-SDK-Platform: text
X-SDK-Version: text
Content-Type: application/json
Accept: */*
Content-Length: 490

{
  "publisherUserId": "user_id_1",
  "age": 20,
  "gender": 1,
  "email": "[email protected]",
  "phoneNumber": 6281234567890,
  "identifierType": "GAID",
  "identifier": "28dde889-530f-4a8e-b427-953077c40772",
  "sub1": "text",
  "sub2": "text",
  "sub3": "text",
  "sub4": "text",
  "sub5": "text",
  "userGroup": "text",
  "mediaSourceName": "text",
  "mediaSourceId": "text",
  "mediaSubSourceId": "text",
  "incentivized": true,
  "mediaAdsetName": "text",
  "mediaAdsetId": "text",
  "mediaCreativeName": "text",
  "mediaCreativeId": "text",
  "mediaCampaignName": "text"
}
{
  "data": {
    "token": "eyJ2YWwiOiI3M3NIeUpNQlp4QzA1TlRHVzhxRExhWWNTeUQ5TTJIT0h3NXBvL3djVVp1Z09MR20wOTJJOTRReDBuYUFLeXhmVGRCaGYra2gvVGcydWFlbUh6aWR6S00vTmV0SEtVZVlWNk5Pdkc5Wnd5bytkSkxmUnA0aWt2eE9yQ01YTXF6LzBnRmZ3RUpucHMxem95WnRkYkVlQXJQNER3cDRZVkttb1lBdEIrZlB6cFZ3R25SSEE5UjROa2U2cGJTeTJod2c2UmI3UnN0QzZiN2Y2cENBYTlqaEhvQXhtdjM5UERPU2tDdWpHMmJIQ2N1cVRldVQ4a3hDSEE9PSIsInZlYyI6InNWbzZrejZRa09iS0tDeDUiLCJ0YWciOiJ1eDNnbjEwNEdUWXpvV1J2TTZVck1BPT0ifQ=="
  },
  "message": "OK"
}

After obtaining the token successfully, you can pass the token to our iframe link and embed the iframe on your page.

https://sdk.tyrads.com?token=[TOKEN_HERE]

For example:

https://sdk.tyrads.com?token=eyJ2YWwiOiI3M3NIeUpNQlp4QzA1TlRHVzhxRExhWWNTeUQ5TTJIT0h3NXBvL3djVVp1Z09MR20wOTJJOTRReDBuYUFLeXhmVGRCaGYra2gvVGcydWFlbUh6aWR6S00vTmV0SEtVZVlWNk5Pdkc5Wnd5bytkSkxmUnA0aWt2eE9yQ01YTXF6LzBnRmZ3RUpucHMxem95WnRkYkVlQXJQNER3cDRZVkttb1lBdEIrZlB6cFZ3R25SSEE5UjROa2U2cGJTeTJod2c2UmI3UnN0QzZiN2Y2cENBYTlqaEhvQXhtdjM5UERPU2tDdWpHMmJIQ2N1cVRldVQ4a3hDSEE9PSIsInZlYyI6InNWbzZrejZRa09iS0tDeDUiLCJ0YWciOiJ1eDNnbjEwNEdUWXpvV1J2TTZVck1BPT0ifQ==

Embedding The Iframe

If your website is using html, you can add an iframe to your page to integrate TyrAds web:

<iframe id="tyrads_iframe" src="[IFRAME_LINK]" height="650" width="300"></iframe>

For example:

<iframe id="tyrads_iframe" src="https://sdk.tyrads.com?token=eyJ2YWwiOiI3M3NIeUpNQlp4QzA1TlRHVzhxRExhWWNTeUQ5TTJIT0h3NXBvL3djVVp1Z09MR20wOTJJOTRReDBuYUFLeXhmVGRCaGYra2gvVGcydWFlbUh6aWR6S00vTmV0SEtVZVlWNk5Pdkc5Wnd5bytkSkxmUnA0aWt2eE9yQ01YTXF6LzBnRmZ3RUpucHMxem95WnRkYkVlQXJQNER3cDRZVkttb1lBdEIrZlB6cFZ3R25SSEE5UjROa2U2cGJTeTJod2c2UmI3UnN0QzZiN2Y2cENBYTlqaEhvQXhtdjM5UERPU2tDdWpHMmJIQ2N1cVRldVQ4a3hDSEE9PSIsInZlYyI6InNWbzZrejZRa09iS0tDeDUiLCJ0YWciOiJ1eDNnbjEwNEdUWXpvV1J2TTZVck1BPT0ifQ==" height="650" width="300"></iframe>

Deeplinking Routes

The Tyrads SDK supports deeplinking to specific sections of the offerwall. When initializing or interacting with the SDK, you can specify a route to open a particular page. For campaign-specific routes, you'll need to provide the campaignID as well. Click here

Localization

Overview

In addition to using URL parameters, the web application itself can change the localization settings. This allows users to switch languages directly within the application. Click here

Last updated