openapi: 3.2.0 info: title: Campaign Build Purchase Categories API version: latest security: - oauth2-cognito: - read tags: - name: Purchase Categories paths: /v6/PurchaseCategories/{purchaseCategoryId}: get: tags: - Purchase Categories summary: Returns a Purchase Category by its Id parameters: - name: countryId in: query description: The ID of a country to search Purchase Category in. Defines localization for PurchaseCategory Name and Description. schema: type: integer format: int32 - name: purchaseCategoryId in: path description: The purchaseCategoryId to find. required: true schema: type: integer format: int32 responses: '200': description: The Purchase Category was found and returned in the response body. content: text/plain: schema: $ref: '#/components/schemas/GetPurchaseCategoryResourceModel' application/json: schema: $ref: '#/components/schemas/GetPurchaseCategoryResourceModel' text/json: schema: $ref: '#/components/schemas/GetPurchaseCategoryResourceModel' '308': description: CountryId was not provided. Redirecting to countryId=1 (US). '404': description: The Purchase Category was not found. content: text/plain: schema: $ref: '#/components/schemas/ProblemDetails' application/json: schema: $ref: '#/components/schemas/ProblemDetails' text/json: schema: $ref: '#/components/schemas/ProblemDetails' operationId: getV6PurchaseCategoriesByPurchaseCategoryId x-operation-id-source: derived /v6/PurchaseCategories: get: tags: - Purchase Categories summary: Returns all Purchase Categories from the repository parameters: - name: PerPage in: query schema: minimum: 1 type: integer format: int32 - name: Page in: query schema: minimum: 1 type: integer format: int32 - name: countryId in: query description: The ID of a country to search Purchase Category in. Defines localization for PurchaseCategory Name and Description. schema: type: integer format: int32 responses: '200': description: The list of Purchase Categories was found and returned in the response body. content: text/plain: schema: type: array items: $ref: '#/components/schemas/GetPurchaseCategoryResourceModel' application/json: schema: type: array items: $ref: '#/components/schemas/GetPurchaseCategoryResourceModel' text/json: schema: type: array items: $ref: '#/components/schemas/GetPurchaseCategoryResourceModel' '308': description: CountryId was not provided. Redirecting to countryId=1 (US). operationId: getV6PurchaseCategories x-operation-id-source: derived components: schemas: ProblemDetails: type: object properties: type: type: - string - 'null' title: type: - string - 'null' status: type: - integer - 'null' format: int32 detail: type: - string - 'null' instance: type: - string - 'null' additionalProperties: {} GetPurchaseCategoryResourceModel: type: object properties: countryIds: type: - array - 'null' items: type: integer format: int32 subCategories: type: - array - 'null' items: $ref: '#/components/schemas/GetPurchaseCategoryResourceModel' purchaseCategoryId: type: integer format: int32 name: type: - string - 'null' description: type: - string - 'null' level: type: integer format: int32 additionalProperties: false securitySchemes: oauth2-cognito: type: oauth2 flows: authorizationCode: authorizationUrl: https://advertiser-auth-preprod.auth.us-east-1.amazoncognito.com/oauth2/authorize tokenUrl: https://advertiser-auth-preprod.auth.us-east-1.amazoncognito.com/oauth2/token scopes: openid: openid x-tokenName: id_token