openapi: 3.0.3
info:
  title: Routing ruleset API
  description: |
    Define routing rules for your business
  version: 1.0.0
  contact:
    name: Team Routing
    url: https://newstore.net/support
servers:
  - url: https://dodici.s.newstore.net/v0
tags:
  - name: routing-ruleset
    description: Routing ruleset API
components:
  securitySchemes:
    newStoreAccessToken:
      type: http
      scheme: bearer
      bearerFormat: JWT
security:
  - newStoreAccessToken: []
paths:
  /routing/ruleset:
    get:
      operationId: showRoutingRuleset
      summary: Get routing rules
      tags:
        - routing-ruleset
      description: >
        Retrieves the current 'Routing Rule V2'. If customer using V1, this
        endpoint

        maps the V1 configuration to V2 and returns a 200 OK.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                title: Routing ruleset
                type: object
                properties:
                  routes:
                    description: Routing rules specification
                    type: array
                    items:
                      type: object
                      properties:
                        fulfilled_by:
                          description: >-
                            This configuration mentions the service levels
                            identifications and which location group will serve
                            this region
                          type: object
                          additionalProperties:
                            type: array
                            items:
                              description: >-
                                Location groups that will be part of this
                                routing. The location groups and respective
                                locations are described in `location_groups`.
                              type: string
                        destination_region:
                          type: object
                          properties:
                            country:
                              description: >-
                                Country in 2 chars (ISO 3166-1 alpha-2)
                                definition
                              type: string
                              minLength: 2
                              maxLength: 2
                              pattern: ([A-Z]){2}
                            zip_code_region:
                              description: >-
                                Region identification that will cover that
                                routing. Zip code region groups is defined in
                                `zip_code_regions`.
                              type: string
                  sl_levels_priority:
                    description: >-
                      Service levels priority. This is ordered according to
                      which service level will be taken first
                    type: array
                    minItems: 1
                    items:
                      type: string
                      minLength: 1
                  location_groups:
                    description: Location groups identifiers
                    type: object
                    additionalProperties:
                      description: >-
                        The group identification will be used on
                        routes[].fulfilled_by
                      type: array
                      items:
                        type: string
                        minLength: 1
                  zip_code_regions:
                    description: >-
                      Zip code groups, in order to facilitate the identification
                      routes per regions
                    type: object
                    additionalProperties:
                      description: >-
                        Identification of zip code. It will contain the zip
                        codes for that specific region
                      type: array
                      items:
                        type: string
                        minLength: 4
              example:
                routes:
                  - fulfilled_by:
                      2_DAY:
                        - 2_DAY::WEST
                      GROUND:
                        - GROUND::WEST
                    destination_region:
                      country: US
                      zip_code_region: WEST
                sl_levels_priority:
                  - GROUND
                  - 2_DAY
                location_groups:
                  2_DAY::WEST:
                    - DC01
                    - US15
                    - US16
                  GROUND::WEST:
                    - US01
                    - US02
                    - US03
                zip_code_regions:
                  WEST:
                    - '*'
        '404':
          description: There is no fulfillment configuration set yet.
          content:
            application/json:
              schema:
                title: Problem.json
                description: Schema for problem.json REST API return type
                type: object
                properties:
                  title:
                    type: string
                  type:
                    type: string
                  detail:
                    type: string
                required:
                  - title
                  - type
              example:
                title: Missing tenant in request header
                status: >-
                  https://newstore.gitlab.io/engineering/routing/services/fulfillment_config/#missing_tenant
                detail: Could not find a tenant key in the request headers
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                title: Problem.json
                description: Schema for problem.json REST API return type
                type: object
                properties:
                  title:
                    type: string
                  type:
                    type: string
                  detail:
                    type: string
                required:
                  - title
                  - type
              example:
                title: Missing tenant in request header
                status: >-
                  https://newstore.gitlab.io/engineering/routing/services/fulfillment_config/#missing_tenant
                detail: Could not find a tenant key in the request headers
        default:
          description: Default
    put:
      summary: Updates the routing rules
      description: >
        This endpoint is used to initially seed the routing rules or to replace
        it completely


        **Note:** 

        - You have the option of defining route entries with a single `country`
        or multiple `countries` by 

        providing the optional `Content-Type` header with your desired payload
        version.

        - If you'd like to define multiple countries set the Content-Type header
        to application/json; version=1. 

        Select the appropriate Content-Type in the the request schema drop-down
        to see the schema for supporting 

        multiple countries.
      operationId: replaceRoutingRuleset
      tags:
        - routing-ruleset
      requestBody:
        required: true
        content:
          application/json:
            schema:
              title: Routing ruleset
              type: object
              properties:
                routes:
                  description: Routing rules specification
                  type: array
                  items:
                    type: object
                    properties:
                      fulfilled_by:
                        description: >-
                          This configuration mentions the service levels
                          identifications and which location group will serve
                          this region
                        type: object
                        additionalProperties:
                          type: array
                          items:
                            description: >-
                              Location groups that will be part of this routing.
                              The location groups and respective locations are
                              described in `location_groups`.
                            type: string
                      destination_region:
                        type: object
                        properties:
                          country:
                            description: Country in 2 chars (ISO 3166-1 alpha-2) definition
                            type: string
                            minLength: 2
                            maxLength: 2
                            pattern: ([A-Z]){2}
                          zip_code_region:
                            description: >-
                              Region identification that will cover that
                              routing. Zip code region groups is defined in
                              `zip_code_regions`.
                            type: string
                sl_levels_priority:
                  description: >-
                    Service levels priority. This is ordered according to which
                    service level will be taken first
                  type: array
                  minItems: 1
                  items:
                    type: string
                    minLength: 1
                location_groups:
                  description: Location groups identifiers
                  type: object
                  additionalProperties:
                    description: >-
                      The group identification will be used on
                      routes[].fulfilled_by
                    type: array
                    items:
                      type: string
                      minLength: 1
                zip_code_regions:
                  description: >-
                    Zip code groups, in order to facilitate the identification
                    routes per regions
                  type: object
                  additionalProperties:
                    description: >-
                      Identification of zip code. It will contain the zip codes
                      for that specific region
                    type: array
                    items:
                      type: string
                      minLength: 4
            example:
              routes:
                - fulfilled_by:
                    2_DAY:
                      - 2_DAY::WEST
                    GROUND:
                      - GROUND::WEST
                  destination_region:
                    country: US
                    zip_code_region: WEST
              sl_levels_priority:
                - GROUND
                - 2_DAY
              location_groups:
                2_DAY::WEST:
                  - DC01
                  - US15
                  - US16
                GROUND::WEST:
                  - US01
                  - US02
                  - US03
              zip_code_regions:
                WEST:
                  - '*'
          application/json; version=1:
            schema:
              title: Routing ruleset
              type: object
              properties:
                routes:
                  description: Routing rules specification
                  type: array
                  items:
                    type: object
                    properties:
                      fulfilled_by:
                        description: >-
                          This configuration mentions the service levels
                          identifications and which location group will serve
                          this region
                        type: object
                        additionalProperties:
                          type: array
                          items:
                            description: >-
                              Location groups that will be part of this routing.
                              The location groups and respective locations are
                              described in `location_groups`.
                            type: string
                      destination_region:
                        type: object
                        properties:
                          countries:
                            description: Country in 2 chars (ISO 3166-1 alpha-2) definition
                            type: array
                            items:
                              type: string
                              minLength: 2
                              maxLength: 2
                              pattern: ([A-Z]){2}
                          zip_code_region:
                            description: >-
                              Region identification that will cover that
                              routing. Zip code region groups is defined in
                              `zip_code_regions`.
                            type: string
                sl_levels_priority:
                  description: >-
                    Service levels priority. This is ordered according to which
                    service level will be taken first
                  type: array
                  minItems: 1
                  items:
                    type: string
                    minLength: 1
                location_groups:
                  description: Location groups identifiers
                  type: object
                  additionalProperties:
                    description: >-
                      The group identification will be used on
                      routes[].fulfilled_by
                    type: array
                    items:
                      type: string
                      minLength: 1
                zip_code_regions:
                  description: >-
                    Zip code groups, in order to facilitate the identification
                    routes per regions
                  type: object
                  additionalProperties:
                    description: >-
                      Identification of zip code. It will contain the zip codes
                      for that specific region
                    type: array
                    items:
                      type: string
                      minLength: 4
            example:
              routes:
                - fulfilled_by:
                    2_DAY:
                      - 2_DAY::WEST
                    GROUND:
                      - GROUND::WEST
                  destination_region:
                    countries:
                      - US
                    zip_code_region: WEST
              sl_levels_priority:
                - GROUND
                - 2_DAY
              location_groups:
                2_DAY::WEST:
                  - DC01
                  - US15
                  - US16
                GROUND::WEST:
                  - US01
                  - US02
                  - US03
              zip_code_regions:
                WEST:
                  - '*'
      responses:
        '201':
          description: Routing rules updated successfully
          content:
            application/json:
              schema:
                title: Put routing ruleset response
                type: object
                properties:
                  routing_ruleset:
                    title: Routing ruleset
                    type: object
                    properties:
                      routes:
                        description: Routing rules specification
                        type: array
                        items:
                          type: object
                          properties:
                            fulfilled_by:
                              description: >-
                                This configuration mentions the service levels
                                identifications and which location group will
                                serve this region
                              type: object
                              additionalProperties:
                                type: array
                                items:
                                  description: >-
                                    Location groups that will be part of this
                                    routing. The location groups and respective
                                    locations are described in
                                    `location_groups`.
                                  type: string
                            destination_region:
                              type: object
                              properties:
                                country:
                                  description: >-
                                    Country in 2 chars (ISO 3166-1 alpha-2)
                                    definition
                                  type: string
                                  minLength: 2
                                  maxLength: 2
                                  pattern: ([A-Z]){2}
                                zip_code_region:
                                  description: >-
                                    Region identification that will cover that
                                    routing. Zip code region groups is defined
                                    in `zip_code_regions`.
                                  type: string
                      sl_levels_priority:
                        description: >-
                          Service levels priority. This is ordered according to
                          which service level will be taken first
                        type: array
                        minItems: 1
                        items:
                          type: string
                          minLength: 1
                      location_groups:
                        description: Location groups identifiers
                        type: object
                        additionalProperties:
                          description: >-
                            The group identification will be used on
                            routes[].fulfilled_by
                          type: array
                          items:
                            type: string
                            minLength: 1
                      zip_code_regions:
                        description: >-
                          Zip code groups, in order to facilitate the
                          identification routes per regions
                        type: object
                        additionalProperties:
                          description: >-
                            Identification of zip code. It will contain the zip
                            codes for that specific region
                          type: array
                          items:
                            type: string
                            minLength: 4
                  fulfillment_config_uri:
                    type: string
                    description: Fulfillment Configuration Revision URI
              example:
                routing_ruleset:
                  routes:
                    - fulfilled_by:
                        2_DAY_PR:
                          - NJ
                      destination_region:
                        country: PR
                        zip_code_region: All
                  sl_levels_priority:
                    - 2_DAY_PR
                  location_groups:
                    NJ:
                      - US_NJ
                  zip_code_regions:
                    All:
                      - '*'
                fulfillment_config_uri: v0/fulfillment_configuration/revision/13
            application/json; version=1:
              schema:
                title: Put routing ruleset response
                type: object
                properties:
                  routing_ruleset:
                    title: Routing ruleset
                    type: object
                    properties:
                      routes:
                        description: Routing rules specification
                        type: array
                        items:
                          type: object
                          properties:
                            fulfilled_by:
                              description: >-
                                This configuration mentions the service levels
                                identifications and which location group will
                                serve this region
                              type: object
                              additionalProperties:
                                type: array
                                items:
                                  description: >-
                                    Location groups that will be part of this
                                    routing. The location groups and respective
                                    locations are described in
                                    `location_groups`.
                                  type: string
                            destination_region:
                              type: object
                              properties:
                                countries:
                                  description: >-
                                    Country in 2 chars (ISO 3166-1 alpha-2)
                                    definition
                                  type: array
                                  items:
                                    type: string
                                    minLength: 2
                                    maxLength: 2
                                    pattern: ([A-Z]){2}
                                zip_code_region:
                                  description: >-
                                    Region identification that will cover that
                                    routing. Zip code region groups is defined
                                    in `zip_code_regions`.
                                  type: string
                      sl_levels_priority:
                        description: >-
                          Service levels priority. This is ordered according to
                          which service level will be taken first
                        type: array
                        minItems: 1
                        items:
                          type: string
                          minLength: 1
                      location_groups:
                        description: Location groups identifiers
                        type: object
                        additionalProperties:
                          description: >-
                            The group identification will be used on
                            routes[].fulfilled_by
                          type: array
                          items:
                            type: string
                            minLength: 1
                  fulfillment_config_uri:
                    type: string
                    description: Fulfillment Configuration Revision URI
              example:
                routing_ruleset:
                  routes:
                    - fulfilled_by:
                        2_DAY_PR:
                          - NJ
                      destination_region:
                        countries:
                          - PR
                        zip_code_region: All
                  sl_levels_priority:
                    - 2_DAY_PR
                  location_groups:
                    NJ:
                      - US_NJ
                  zip_code_regions:
                    All:
                      - '*'
                fulfillment_config_uri: v0/fulfillment_configuration/revision/13
        '400':
          description: Bad request
          content:
            application/problem+json:
              schema:
                title: Problem.json
                description: Schema for problem.json REST API return type
                type: object
                properties:
                  title:
                    type: string
                  type:
                    type: string
                  detail:
                    type: string
                required:
                  - title
                  - type
              example:
                title: Missing tenant in request header
                status: >-
                  https://newstore.gitlab.io/engineering/routing/services/fulfillment_config/#missing_tenant
                detail: Could not find a tenant key in the request headers
        '500':
          description: Internal server error
          content:
            application/problem+json:
              schema:
                title: Problem.json
                description: Schema for problem.json REST API return type
                type: object
                properties:
                  title:
                    type: string
                  type:
                    type: string
                  detail:
                    type: string
                required:
                  - title
                  - type
              example:
                title: Missing tenant in request header
                status: >-
                  https://newstore.gitlab.io/engineering/routing/services/fulfillment_config/#missing_tenant
                detail: Could not find a tenant key in the request headers
        default:
          description: Default
    patch:
      description: >
        A convenience endpoint is where you use JSON patch to change parts of
        routing rules.


        **Note:**

        - You have the option of defining route entries with a single `country`
        or multiple `countries` by 

        providing the optional `Content-Type` header with your desired payload
        version.

        - If you'd like to define multiple countries set the Content-Type header
        to application/json; version=1. 

        Select the appropriate Content-Type in the the request schema drop-down
        to see the schema for supporting 

        multiple countries.

        - To use payload version 1 via the PATCH operation you need to update
        the route entries from `country` 

        to `countries` via PUT endpoint for compatibility.
      summary: Patch the routing rules
      operationId: updateRoutingRuleset
      tags:
        - routing-ruleset
      requestBody:
        content:
          application/json:
            schema:
              title: JSON schema for JSONPatch files
              type: array
              items:
                oneOf:
                  - additionalProperties: false
                    required:
                      - value
                      - op
                      - path
                    properties:
                      path:
                        description: A JSON Pointer path.
                        type: string
                      op:
                        description: The operation to perform.
                        type: string
                        enum:
                          - add
                          - replace
                          - test
                      value:
                        description: The value to add, replace or test.
                  - additionalProperties: false
                    required:
                      - op
                      - path
                    properties:
                      path:
                        description: A JSON Pointer path.
                        type: string
                      op:
                        description: The operation to perform.
                        type: string
                        enum:
                          - remove
                  - additionalProperties: false
                    required:
                      - from
                      - op
                      - path
                    properties:
                      path:
                        description: A JSON Pointer path.
                        type: string
                      op:
                        description: The operation to perform.
                        type: string
                        enum:
                          - move
                          - copy
                      from:
                        description: >-
                          A JSON Pointer path pointing to the location to
                          move/copy from.
                        type: string
            example:
              - op: add
                path: /location_groups/2_DAY::WEST/-
                value: US10
          application/json; version=1:
            schema:
              title: JSON schema for JSONPatch files
              type: array
              items:
                oneOf:
                  - additionalProperties: false
                    required:
                      - value
                      - op
                      - path
                    properties:
                      path:
                        description: A JSON Pointer path.
                        type: string
                      op:
                        description: The operation to perform.
                        type: string
                        enum:
                          - add
                          - replace
                          - test
                      value:
                        description: The value to add, replace or test.
                  - additionalProperties: false
                    required:
                      - op
                      - path
                    properties:
                      path:
                        description: A JSON Pointer path.
                        type: string
                      op:
                        description: The operation to perform.
                        type: string
                        enum:
                          - remove
                  - additionalProperties: false
                    required:
                      - from
                      - op
                      - path
                    properties:
                      path:
                        description: A JSON Pointer path.
                        type: string
                      op:
                        description: The operation to perform.
                        type: string
                        enum:
                          - move
                          - copy
                      from:
                        description: >-
                          A JSON Pointer path pointing to the location to
                          move/copy from.
                        type: string
            example:
              - op: add
                path: /location_groups/2_DAY::WEST/-
                value: US10
      responses:
        '200':
          description: Routing rules updated successfully
          content:
            application/json:
              schema:
                title: Put routing ruleset response
                type: object
                properties:
                  routing_ruleset:
                    title: Routing ruleset
                    type: object
                    properties:
                      routes:
                        description: Routing rules specification
                        type: array
                        items:
                          type: object
                          properties:
                            fulfilled_by:
                              description: >-
                                This configuration mentions the service levels
                                identifications and which location group will
                                serve this region
                              type: object
                              additionalProperties:
                                type: array
                                items:
                                  description: >-
                                    Location groups that will be part of this
                                    routing. The location groups and respective
                                    locations are described in
                                    `location_groups`.
                                  type: string
                            destination_region:
                              type: object
                              properties:
                                country:
                                  description: >-
                                    Country in 2 chars (ISO 3166-1 alpha-2)
                                    definition
                                  type: string
                                  minLength: 2
                                  maxLength: 2
                                  pattern: ([A-Z]){2}
                                zip_code_region:
                                  description: >-
                                    Region identification that will cover that
                                    routing. Zip code region groups is defined
                                    in `zip_code_regions`.
                                  type: string
                      sl_levels_priority:
                        description: >-
                          Service levels priority. This is ordered according to
                          which service level will be taken first
                        type: array
                        minItems: 1
                        items:
                          type: string
                          minLength: 1
                      location_groups:
                        description: Location groups identifiers
                        type: object
                        additionalProperties:
                          description: >-
                            The group identification will be used on
                            routes[].fulfilled_by
                          type: array
                          items:
                            type: string
                            minLength: 1
                      zip_code_regions:
                        description: >-
                          Zip code groups, in order to facilitate the
                          identification routes per regions
                        type: object
                        additionalProperties:
                          description: >-
                            Identification of zip code. It will contain the zip
                            codes for that specific region
                          type: array
                          items:
                            type: string
                            minLength: 4
                  fulfillment_config_uri:
                    type: string
                    description: Fulfillment Configuration Revision URI
              example:
                routing_ruleset:
                  routes:
                    - fulfilled_by:
                        2_DAY_PR:
                          - NJ
                      destination_region:
                        country: PR
                        zip_code_region: All
                  sl_levels_priority:
                    - 2_DAY_PR
                  location_groups:
                    NJ:
                      - US_NJ
                  zip_code_regions:
                    All:
                      - '*'
                fulfillment_config_uri: v0/fulfillment_configuration/revision/13
            application/json; version=1:
              schema:
                title: Put routing ruleset response
                type: object
                properties:
                  routing_ruleset:
                    title: Routing ruleset
                    type: object
                    properties:
                      routes:
                        description: Routing rules specification
                        type: array
                        items:
                          type: object
                          properties:
                            fulfilled_by:
                              description: >-
                                This configuration mentions the service levels
                                identifications and which location group will
                                serve this region
                              type: object
                              additionalProperties:
                                type: array
                                items:
                                  description: >-
                                    Location groups that will be part of this
                                    routing. The location groups and respective
                                    locations are described in
                                    `location_groups`.
                                  type: string
                            destination_region:
                              type: object
                              properties:
                                countries:
                                  description: >-
                                    Country in 2 chars (ISO 3166-1 alpha-2)
                                    definition
                                  type: array
                                  items:
                                    type: string
                                    minLength: 2
                                    maxLength: 2
                                    pattern: ([A-Z]){2}
                                zip_code_region:
                                  description: >-
                                    Region identification that will cover that
                                    routing. Zip code region groups is defined
                                    in `zip_code_regions`.
                                  type: string
                      sl_levels_priority:
                        description: >-
                          Service levels priority. This is ordered according to
                          which service level will be taken first
                        type: array
                        minItems: 1
                        items:
                          type: string
                          minLength: 1
                      location_groups:
                        description: Location groups identifiers
                        type: object
                        additionalProperties:
                          description: >-
                            The group identification will be used on
                            routes[].fulfilled_by
                          type: array
                          items:
                            type: string
                            minLength: 1
                  fulfillment_config_uri:
                    type: string
                    description: Fulfillment Configuration Revision URI
              example:
                routing_ruleset:
                  routes:
                    - fulfilled_by:
                        2_DAY_PR:
                          - NJ
                      destination_region:
                        countries:
                          - PR
                        zip_code_region: All
                  sl_levels_priority:
                    - 2_DAY_PR
                  location_groups:
                    NJ:
                      - US_NJ
                  zip_code_regions:
                    All:
                      - '*'
                fulfillment_config_uri: v0/fulfillment_configuration/revision/13
        '400':
          description: Bad request.
          content:
            application/json:
              schema:
                title: Problem.json
                description: Schema for problem.json REST API return type
                type: object
                properties:
                  title:
                    type: string
                  type:
                    type: string
                  detail:
                    type: string
                required:
                  - title
                  - type
              example:
                title: Missing tenant in request header
                status: >-
                  https://newstore.gitlab.io/engineering/routing/services/fulfillment_config/#missing_tenant
                detail: Could not find a tenant key in the request headers
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                title: Problem.json
                description: Schema for problem.json REST API return type
                type: object
                properties:
                  title:
                    type: string
                  type:
                    type: string
                  detail:
                    type: string
                required:
                  - title
                  - type
              example:
                title: Missing tenant in request header
                status: >-
                  https://newstore.gitlab.io/engineering/routing/services/fulfillment_config/#missing_tenant
                detail: Could not find a tenant key in the request headers
        default:
          description: Default
  /routing/ruleset/{section}:
    get:
      operationId: showRoutingRulesetSection
      summary: Get routing rules section
      description: >
        Retrieves a section of the current 'Routing Rule V2'. If customer using
        V1, this endpoint

        is of no use, and will return the error.
      tags:
        - routing-ruleset
      parameters:
        - name: section
          in: path
          description: name of the section to retrieve
          required: true
          schema:
            type: string
            enum:
              - routes
              - sl_levels_priority
              - location_groups
              - zip_code_regions
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                description: Signifies one section of the currently active routing rule
                type: object
                oneOf:
                  - properties:
                      routes:
                        description: Routing rules specification
                        type: array
                        items:
                          type: object
                          properties:
                            fulfilled_by:
                              description: >-
                                This configuration mentions the service levels
                                identifications and which location group will
                                serve this region
                              type: object
                              additionalProperties:
                                type: array
                                items:
                                  description: >-
                                    Location groups that will be part of this
                                    routing. The location groups and respective
                                    locations are described in
                                    `location_groups`.
                                  type: string
                            destination_region:
                              type: object
                              properties:
                                country:
                                  description: >-
                                    Country in 2 chars (ISO 3166-1 alpha-2)
                                    definition
                                  type: string
                                  minLength: 2
                                  maxLength: 2
                                  pattern: ([A-Z]){2}
                                zip_code_region:
                                  description: >-
                                    Region identification that will cover that
                                    routing. Zip code region groups is defined
                                    in `zip_code_regions`.
                                  type: string
                    required:
                      - routes
                    additionalProperties: false
                  - properties:
                      sl_levels_priority:
                        description: >-
                          Service levels priority. This is ordered according to
                          which service level will be taken first
                        type: array
                        minItems: 1
                        items:
                          type: string
                          minLength: 1
                    required:
                      - sl_levels_priority
                    additionalProperties: false
                  - properties:
                      location_groups:
                        description: Location groups identifiers
                        type: object
                        additionalProperties:
                          description: >-
                            The group identification will be used on
                            routes[].fulfilled_by
                          type: array
                          items:
                            type: string
                            minLength: 1
                    required:
                      - location_groups
                    additionalProperties: false
                  - properties:
                      zip_code_regions:
                        description: >-
                          Zip code groups, in order to facilitate the
                          identification routes per regions
                        type: object
                        additionalProperties:
                          description: >-
                            Identification of zip code. It will contain the zip
                            codes for that specific region
                          type: array
                          items:
                            type: string
                            minLength: 4
                    required:
                      - zip_code_regions
                    additionalProperties: false
              example:
                zip_code_regions:
                  West:
                    - '90210'
                    - '90211'
                    - '90212'
                    - '90213'
                  East:
                    - '10001'
                    - '10002'
                    - '10003'
                    - '10004'
                    - '10005'
                  South:
                    - '33101'
                    - '33102'
                    - '33103'
                    - '33104'
                    - '33105'
                    - '33106'
        '400':
          description: Bad request.
          content:
            application/json:
              schema:
                title: Problem.json
                description: Schema for problem.json REST API return type
                type: object
                properties:
                  title:
                    type: string
                  type:
                    type: string
                  detail:
                    type: string
                required:
                  - title
                  - type
              example:
                title: Missing tenant in request header
                status: >-
                  https://newstore.gitlab.io/engineering/routing/services/fulfillment_config/#missing_tenant
                detail: Could not find a tenant key in the request headers
        '409':
          description: >-
            Incorrect fulfillment configuration version. The config is stored as
            V1 but V2 is required.
          content:
            application/json:
              schema:
                title: Problem.json
                description: Schema for problem.json REST API return type
                type: object
                properties:
                  title:
                    type: string
                  type:
                    type: string
                  detail:
                    type: string
                required:
                  - title
                  - type
              example:
                title: Missing tenant in request header
                status: >-
                  https://newstore.gitlab.io/engineering/routing/services/fulfillment_config/#missing_tenant
                detail: Could not find a tenant key in the request headers
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                title: Problem.json
                description: Schema for problem.json REST API return type
                type: object
                properties:
                  title:
                    type: string
                  type:
                    type: string
                  detail:
                    type: string
                required:
                  - title
                  - type
              example:
                title: Missing tenant in request header
                status: >-
                  https://newstore.gitlab.io/engineering/routing/services/fulfillment_config/#missing_tenant
                detail: Could not find a tenant key in the request headers
        x-lint-ignore:
          - use-standard-http-codes-get
        default:
          description: Default
