openapi: 3.0.1 info: title: Test Console API version: '1.0' servers: - url: https://hq1.appsflyer.com/api/test-console/v1.0/app description: Production server security: - Bearer-Authentication: [] paths: /{app-id}/devices/{device-id}: delete: summary: Delete device description: '> ⚠️ Important > > All API V2 tokens generated before March 10, 2026, 19:00 UTC have been revoked. If your token was generated before this date, please regenerate it. [Learn how](https://support.appsflyer.com/hc/en-us/articles/360004562377-Managing-AppsFlyer-tokens). ' tags: - Allowed devices operationId: test-console-api-delete parameters: - $ref: '#/components/parameters/AppId' - name: device-id in: path required: true description: The id of the device being removed. schema: type: string example: 09ad6f30-a45c-4c6c-8862-636eabd54709 pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$ responses: '400': description: Bad request $ref: '#/components/responses/BadRequest' '401': description: Unauthorized $ref: '#/components/responses/Unauthorized' '403': description: Forbidden $ref: '#/components/responses/Forbidden' '404': description: Not found $ref: '#/components/responses/NotFound' '409': description: Conflict $ref: '#/components/responses/Conflict' '500': description: Internal Server Error $ref: '#/components/responses/InternalError' /{app-id}/events: get: tags: - Events summary: Retrieve events description: '> ⚠️ Important > > All API V2 tokens generated before March 10, 2026, 19:00 UTC have been revoked. If your token was generated before this date, please regenerate it. [Learn how](https://support.appsflyer.com/hc/en-us/articles/360004562377-Managing-AppsFlyer-tokens). ' operationId: test-console-api-get parameters: - $ref: '#/components/parameters/AppId' - $ref: '#/components/parameters/DeviceId' - $ref: '#/components/parameters/StartTime' - $ref: '#/components/parameters/EndTime' responses: '200': description: Successful response content: application/json: schema: type: object properties: app_id: type: string device_id: type: string max_results: type: integer total: type: integer data: type: array items: type: object required: - sdk_timestamp - event_type - appsflyer_id properties: sdk_timestamp: type: string description: UTC timestamp in ISO 8601 format. Non-nullable. event_type: type: string description: Type of event - "Session" / "In-App". Non-nullable. appsflyer_id: type: string description: Unique installation ID. Created for every new app install. Non-nullable. sdk_version: type: string description: The SDK version used by the app. Nullable. nullable: true app_version: type: string description: App version. Nullable. nullable: true event_name: type: string description: In-App event name. Null if event type is "Session". nullable: true event_value: type: string description: In-App event value. Null if event type is "Session". nullable: true customer_user_id: type: string description: Customer User ID. Assigned by the app. Defaults to null if the app does not provide a value. nullable: true idfa: type: string description: The device IDFA. Set to null when not collected. Always null on Android devices. nullable: true idfv: type: string description: Device IDFV. Set to null when not collected. Always null on Android devices. nullable: true gaid: type: string description: Android Advertising ID. Always null on iOS. nullable: true android_id: type: string description: The device android_id. Set to null when not collected. Always null on iOS devices. nullable: true imei: type: string description: The device IMEI. Set to null when not collected. Always null on iOS devices. nullable: true oaid: type: string description: The device OAID. Set to null when not collected. Always null on iOS devices. nullable: true amazon_aid: type: string description: The device Amazon Advertising ID. Set to null when not collected. Always null on iOS devices. nullable: true response_time: type: string '400': description: Bad request $ref: '#/components/responses/BadRequest' '401': description: Unauthorized $ref: '#/components/responses/Unauthorized' '403': description: Forbidden $ref: '#/components/responses/Forbidden' '404': description: Not found $ref: '#/components/responses/NotFound' '409': description: Conflict $ref: '#/components/responses/Conflict' '500': description: Internal Server Error $ref: '#/components/responses/InternalError' /{app-id}/devices: post: summary: Add device description: '> ⚠️ Important > > All API V2 tokens generated before March 10, 2026, 19:00 UTC have been revoked. If your token was generated before this date, please regenerate it. [Learn how](https://support.appsflyer.com/hc/en-us/articles/360004562377-Managing-AppsFlyer-tokens). ' tags: - Allowed devices operationId: test-console-api-post parameters: - $ref: '#/components/parameters/AppId' requestBody: required: true content: application/json: schema: type: object required: - device_id - device_id_type - device_name properties: device_id: type: string description: The identifier of the device being registered for the test. example: 09ad6f30-a39c-4c6c-8862-636eabd54709 pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$ device_id_type: type: string description: The type of device ID being registered for the test. enum: - IDFA - IDFV - AID - OAID - IMEI - ANDROID ID - FIRE AID example: IDFA device_name: type: string description: The name to associate with the device. example: My Device responses: '400': description: Bad request $ref: '#/components/responses/BadRequest' '401': description: Unauthorized $ref: '#/components/responses/Unauthorized' '403': description: Forbidden $ref: '#/components/responses/Forbidden' '404': description: Not found $ref: '#/components/responses/NotFound' '409': description: Conflict $ref: '#/components/responses/Conflict' '500': description: Internal Server Error $ref: '#/components/responses/InternalError' components: securitySchemes: Bearer-Authentication: type: http scheme: bearer description: "**Important: API V2 Token Revocation**\n\nAll API V2 tokens generated before March 10, 2026, 19:00 UTC\ \ have been revoked. If your token was generated before this date, please regenerate it. [Learn how](https://support.appsflyer.com/hc/en-us/articles/360004562377-Managing-AppsFlyer-tokens).\n\ \nAuthorization HTTP header containing API V2 token (bearer token) is required.\n\n [An admin can retrieve the V2\ \ token from AppsFlyer](https://support.appsflyer.com/hc/en-us/articles/360004562377)" parameters: AppId: name: app-id in: path required: true schema: type: string description: The App ID of the app being tested. Use the 'Package Name' for Android apps and the 'App Store ID' for iOS apps. example: com.example.testapp DeviceId: name: device_id in: query required: true schema: type: string description: The ID of the device registered for testing pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$ example: 09ad6f30-a39c-4c6c-8862-636eabd54709 StartTime: name: start_time in: query required: true schema: type: string description: The Date and Time in UTC ISO 8601 format. The start time must be within the past 2 hours example: '2023-07-12T09:02:26Z' EndTime: name: end_time in: query required: false schema: type: string description: Date and Time in UTC ISO 8601 format example: '2023-07-12T09:02:26Z' responses: BadRequest: description: The request has invalid parameters content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' example: error: cannot parse body Unauthorized: description: Authentication credentials were missing or incorrect content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' example: error: authentication error Forbidden: description: Request acknowledged but denied. Access is not permitted. content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' example: error: forbidden NotFound: description: The specified App ID does not exist within the account. content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' example: error: app_id not found Conflict: description: You have added the maximum number of devices allowed by the Devices API. content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' example: error: device limit reached InternalError: description: A generic error message displayed when an unexpected condition occurs and no specific error message applies. content: application/json: schema: $ref: '#/components/schemas/ErrorResponse' schemas: ErrorResponse: type: object properties: error: type: string