Skip to content

fix(sim-swap): remove SIM swap age band endpoint and tests - #292

Merged
bigludo7 merged 2 commits into
camaraproject:mainfrom
albertoramosmonagas:revert/sim-swap-age-band
Sep 28, 2026
Merged

bigludo7 merged 2 commits into
camaraproject:mainfrom
albertoramosmonagas:revert/sim-swap-age-band

Conversation

@albertoramosmonagas

Copy link
Copy Markdown
Contributor

What type of PR is this?

Add one of the following kinds:

  • cleanup

What this PR does / why we need it:

Removes the SIM swap age band from the repository, returning sim-swap to its state before the age band was introduced.

Removed:

  • the optional /retrieve-age-band operation, with its tag, scope and operationId
  • the SimSwapAgeBand, SimSwapAgeBandInfo and CreateSimSwapAgeBand schemas and the
    AGEBAND_* examples
  • the age band sections of info.description (band table, definition of d, error-handling rules)
  • code/Test_definitions/sim-swap-retrieveSimSwapAgeBand.feature
  • the local components.responses block, including Generic501, which existed only so that a
    provider not implementing the operation could signal it

Which issue(s) this PR fixes:

Fixes: 2026-09-17 TSC Minutes. Follows the release process table in the Release Management section. Related to #284 (r4.1 release review findings), of which #291 and #277 can be closed.

Changelog input

 release-note
Removed the optional `/retrieve-age-band` operation and its test definitions from the sim-swap API. 

@hdamker hdamker left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The age band is fully removed. Compared with main before the age band was added, sim-swap.yaml only differs by fixes merged since then.

One change requested: please keep the local Generic403 and Generic422. They are not part of the age band. #278 added them so the error responses of /retrieve-date and /check stay unchanged from r3.3. The CAMARA_common.yaml generics add 403 INVALID_TOKEN_CONTEXT and 422 UNSUPPORTED_IDENTIFIER.

Suggested: reference #/components/responses/Generic403 and #/components/responses/Generic422 from both operations and restore the definitions below. The age band text is removed from the SERVICE_NOT_APPLICABLE example. Generic404 and Generic429 can stay on the common refs.

The alignment with Commonalities r4.4 will replace these error responses with correct references.

components.responses
  responses:
    Generic403:
      description: Forbidden
      headers:
        x-correlator:
          $ref: "../common/CAMARA_common.yaml#/components/headers/x-correlator"
      content:
        application/json:
          schema:
            allOf:
              - $ref: "../common/CAMARA_common.yaml#/components/schemas/ErrorInfo"
              - type: object
                properties:
                  status:
                    enum:
                      - 403
                  code:
                    enum:
                      - PERMISSION_DENIED
          examples:
            GENERIC_403_PERMISSION_DENIED:
              description: Permission denied. OAuth2 token access does not have the required scope or when the user fails operational security
              value:
                status: 403
                code: PERMISSION_DENIED
                message: Client does not have sufficient permissions to perform this action.
    Generic422:
      description: Unprocessable Content
      headers:
        x-correlator:
          $ref: "../common/CAMARA_common.yaml#/components/headers/x-correlator"
      content:
        application/json:
          schema:
            allOf:
              - $ref: "../common/CAMARA_common.yaml#/components/schemas/ErrorInfo"
              - type: object
                properties:
                  status:
                    enum:
                      - 422
                  code:
                    enum:
                      - SERVICE_NOT_APPLICABLE
                      - MISSING_IDENTIFIER
                      - UNNECESSARY_IDENTIFIER
          examples:
            GENERIC_422_SERVICE_NOT_APPLICABLE:
              description: Service not applicable for the provided identifier
              value:
                status: 422
                code: SERVICE_NOT_APPLICABLE
                message: The service is not available for the provided identifier.
            GENERIC_422_MISSING_IDENTIFIER:
              description: phone number is not included in the request (in case of 2-legged) or the phone number identification cannot be derived from access token (in 3-legged)
              value:
                status: 422
                code: MISSING_IDENTIFIER
                message: The device cannot be identified.
            GENERIC_422_UNNECESSARY_IDENTIFIER:
              description: An explicit identifier is provided when a device or phone number has already been identified from the access token
              value:
                status: 422
                code: UNNECESSARY_IDENTIFIER
                message: The device is already identified by the access token.

@hdamker hdamker left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Requesting changes as described in my review above.

@bigludo7 bigludo7 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@bigludo7

Copy link
Copy Markdown
Collaborator

Approved but need now @hdamker approval to be able to merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants