Sessions

Create a Session

Create a session with users. Sessions are linked to a deployment.

post/v1/session

Request

  • Base URL: https://api.edgegap.com
  • URL: https://api.edgegap.com/v1/session
  • Auth: API key in header authorization

Request body

app_namestring required

The Name of the App you want to deploy, example:

supermario
version_namestring

The Name of the App Version you want to deploy, example:

v1.0
ip_liststring[]

The List of IP of your user, Array of String, example:

 ["162.254.103.13","198.12.116.39", "162.254.135.39", "162.254.129.34"]
deployment_request_idstring

The request id of your deployment. If specified, the session will link to the deployment

citystring

If you want your session in a specific city

countrystring

If you want your session in a specific country

continentstring

If you want your session in a specific continent

administrative_divisionstring

If you want your session in a specific administrative division

regionstring

If you want your session in a specific region

webhook_urlstring

When your Session is Linked, Unprocessable or in Error, we will POST the session's details on the webhook_url

skip_telemetryboolean

If system should skip the telemetry and use GeoBase decision only

Example request

{
  "app_name": "demo",
  "version_name": "v1.0",
  "ip_list": [
    "1.1.1.1"
  ],
  "geo_ip_list": [
    {
      "ip": "1.2.3.4"
    }
  ],
  "deployment_request_id": "c0653765de3b",
  "location": {
    "latitude": 45.5,
    "longitude": -73.56
  },
  "city": "Montreal",
  "country": "Canada",
  "continent": "North America",
  "administrative_division": "Quebec",
  "region": "North America",
  "selectors": [
    {
      "tag": "tag",
      "env": {
        "key": "KEY",
        "value": "VALUE"
      }
    }
  ],
  "webhook_url": "https://webhook.com",
  "filters": [
    {
      "field": "city",
      "values": [
        "Montreal"
      ],
      "filter_type": "any"
    }
  ]
}

Response

Success

session_idstring required

The Unique Identifier of the Session

custom_idstring

Custom ID if Available

appstring required

The Name of the App you requested

versionstring required

The name of the App Version you requested

deployment_request_idstring

Unique UUID

webhook_urlstring

When your Session is Linked, Unprocessable or in Error, we will POST the session's details on the webhook_url

Example response

{
  "session_id": "abc123-s",
  "custom_id": "custom-abc123",
  "app": "demo",
  "version": "v1.0",
  "selectors": [
    {
      "tag": "tag",
      "env": {
        "key": "KEY",
        "value": "VALUE"
      }
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.