Headers

("accept", "application/json"),
("content-type", "application/json"),

// This is a source specific Inspector API key
// Obtain the API key in Inspector tab in your Avo.app workspace
("api-key", "fwoermmf1asl3mmad3")
("env", "prod") // "prod" | "dev" | "staging"
("origin", string) // optional

Payload

Each event received is either of type "event" or of type "sessionStarted"

Event

{
		"appName": "TikTok", // The name of your source application
		"appVersion": "1.2.2", // The version of your source application
		"libVersion": "1.0.0", // The version of the Inspector SDK sending this request
		"libPlatform": "api" // Hardcoded value
    "apiKey": "fwoermmf1asl3mmad3" // Source specific Inspector API key
		"env": "prod", // "prod" | "dev" | "staging"
		"samplingRate": 1.0,
		"sessionId": "11332f62-ba2d-11eb-8529-0242ac130003", // UUID per session (generate new for each event if you're not aware of sessions)
		"messageId": "54cafd77-c6cd-46b0-8459-69b59d44f012", // UUID per event
		"createdAt": "2021-05-21T09:05:40.735Z", // Event creation timestamp (ISO 8601)
		"type": "event", // Hardcoded value
		"eventName": "Onboarding Started", // Name of the event being sent
		"eventProperties": [
      {
				"propertyName": "user",
	      "propertyType": "object", // Allowed values: "null”, “string”, “int”, “float”, “bool”, “object”, “list<string>”, “list<int>”, “list<float>”, “list<bool>”, “list<object>”
        //optional, for nested properties only
				"children": [{"propertyName": "id", "propertyType": "string"}]
      },
			{
				"propertyName": "friendNames",
		    "propertyType": "list<string>",
      },
		]
	}

Event Accepted Fields

Session Started

SessionStarted event is sent when a new user session is started, We define a new User sessions as:

This is logic that our SDK's do handle themselves, we can provide code snippets to help with this.

<aside> 💡 If you’re not aware of user sessions in the context of where you plan to use this API you can skip this. Currently it does not have any impact on your Inspector experience, but we do plan to use the session tracking for future issue types in the Inspector (e.g. for volume anomaly detection)

</aside>

{
		"appName": "TikTok", // The name of your source application
		"appVersion": "1.2.2", // The version of your source application
		"libVersion": "1.0.2", // The version of the Inspector SDK sending this request
		"libPlatform": "api" // Hardcoded value
		"apiKey": "fwoermmf1asl3mmad3" // Source specific Inspector API key
		"env": "prod", // "prod" | "dev" | "staging"
		"samplingRate": 1.0,
		"sessionId": "11332f62-ba2d-11eb-8529-0242ac130003", // UUID per session (generate new for each event if you're not aware of sessions)
		"messageId": "4cffbdca-ba2e-11eb-8529-0242ac130003", // UUID per event
		"createdAt": "2021-05-21T09:05:40.735Z", // Event creation timestamp (ISO 8601)
		"type": "sessionStarted", // Hardcoded value
}

Example API call

POST <https://api.avo.app/inspector/v1/track>
{
  [
		{
			"appName": "TikTok", 
			"appVersion": "1.2.2", 
			"libVersion": "1.0.2", 
			"libPlatform": "android"
		  "apiKey": "fwoermmf1asl3mmad3" 
		  "env": "prod", // "prod" | "dev" | "staging"
			"samplingRate": 1.0,
			"sessionId": "11332f62-ba2d-11eb-8529-0242ac130003", // UUID
			"messageId": "4cffbdca-ba2e-11eb-8529-0242ac130003", // UUID
			"createdAt": "2021-05-21T09:05:40.735Z",
			"type": "sessionStarted", 
		},
    {
		"appName": "TikTok", 
		"appVersion": "1.2.2", 
		"libVersion": "1.0.2", 
		"libPlatform": "ios"
		"apiKey": "fwoermmf1asl3mmad3" 
		"env": "prod", // "prod" | "dev" | "staging"
		"samplingRate": 1.0,
		"sessionId": "11332f62-ba2d-11eb-8529-0242ac130003", //UUID
		"messageId": "54cafd77-c6cd-46b0-8459-69b59d44f012", // UUID 
		"createdAt": "2021-05-21T09:05:40.735Z",
		"type": "event", 
		"eventName": "Onboarding Started",
		"eventProperties": [
      {
				"propertyName": "user",
	      "propertyType": "object",
        //optional nested properties
				"children": [{"propertyName": "id", "propertyType": "string"}]
      },
				{
					"propertyName": "friendNames",
			    "propertyType": "list<string>",
	      },
			]
		},
  ] 
}