PagoPA b2b - pagoPA side API

Api's to notify transaction outcome

GitHub OpenAPI

Operations 1

POST /redirections/{idTransaction}/outcomes Callback API for communicate authorization outcome #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/pagopa:pagopa-b2b-pagopa-side-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

pagopa-b2b-pagopa-side-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: ecommerce pagoPA - Redirect outcome b2b - pagoPA side API
  description: API to handle redirect transaction's outcome requests
  termsOfService: https://www.pagopa.gov.it/
  version: 0.0.1
servers:
- url: https://api.platform.pagopa.it/ecommerce/redirect/v1
security:
- apiKeyHeader: []
- apiKeyQuery: []
tags:
- name: b2b - pagoPA side
  description: Api's to notify transaction outcome
paths:
  /redirections/{idTransaction}/outcomes:
    post:
      tags:
      - b2b - pagoPA side
      summary: Callback API for communicate authorization outcome
      description: Communicate the outcome for the authorization process
      operationId: CallbackOutcome
      parameters:
      - name: idTransaction
        in: path
        description: PagoPA unique identifier of the transaction to be refund (the same given in the redirections/url request)
        required: true
        schema:
          $ref: '#/components/schemas/PagopaIdTransaction'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TransactionResultRequest'
            examples:
              authorization outcome OK:
                value:
                  idPsp: idPsp
                  idPSPTransaction: idPSPTransaction
                  outcome: OK
                  details:
                    timestampOperation: '2024-01-12T11:59:40.0000000+00:00'
                    authorizationCode: authorizationCode
              authorization outcome KO:
                value:
                  idPsp: idPsp
                  idPSPTransaction: idPSPTransaction
                  outcome: OK
                  details:
                    errorCode: errorCode
      responses:
        '200':
          description: Outcome response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TransactionResultResponse'
              example:
                idTransaction: 3fa85f6457174562b3fc2c963f66afa6
                outcome: OK
        '400':
          description: Formally invalid input
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemJson'
              example:
                status: 400
                detail: Bad request
                idTransaction: 3fa85f6457174562b3fc2c963f66afa6
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemJson'
              example:
                status: 401
                detail: Unauthorized
                idTransaction: 3fa85f6457174562b3fc2c963f66afa6
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemJson'
              example:
                status: 404
                detail: Transaction not found
                idTransaction: 3fa85f6457174562b3fc2c963f66afa6
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemJson'
              example:
                status: 500
                detail: There was an error processing the request
                idTransaction: 3fa85f6457174562b3fc2c963f66afa6
components:
  schemas:
    TransactionResultDetails:
      required:
      - outcome
      type: object
      oneOf:
      - $ref: '#/components/schemas/TransactionAuthorizedOutcomeDetails'
      - $ref: '#/components/schemas/TransactionDeniedOutcomeDetails'
      discriminator:
        propertyName: outcome
        mapping:
          OK: '#/components/schemas/TransactionAuthorizedOutcomeDetails'
          KO: '#/components/schemas/TransactionDeniedOutcomeDetails'
          CANCELED: '#/components/schemas/TransactionDeniedOutcomeDetails'
          EXPIRED: '#/components/schemas/TransactionDeniedOutcomeDetails'
          ERROR: '#/components/schemas/TransactionDeniedOutcomeDetails'
    AuthorizationResponseOutcome:
      enum:
      - OK
      - KO
      type: string
      description: 'Transaction authorization callback process outcome.

        The outcome can assume the following values:

        * OK -> callback request have been processed successfully

        * KO -> there was an error processing the callback request

        '
    PagopaIdTransaction:
      maxLength: 32
      minLength: 32
      type: string
      description: Uniquely identify a transaction
      example: 3fa85f6457174562b3fc2c963f66afa6
    HttpStatusCode:
      minimum: 400.0
      type: integer
      description: 'The HTTP status code generated by the origin server for this occurrence

        of the problem.'
      format: int32
      example: 400
      exclusiveMaximum: 600.0
    TransactionAuthorizedOutcomeDetails:
      required:
      - timestampOperation
      - authorizationCode
      type: object
      properties:
        timestampOperation:
          type: string
          description: Payment date and time
          format: date-time
        authorizationCode:
          type: string
          description: Unique PSP authorization code
    TransactionResultRequest:
      required:
      - idPsp
      - idPSPTransaction
      - outcome
      - details
      type: object
      properties:
        idPsp:
          type: string
          description: PSP identifier as received in redirections url request
        idPSPTransaction:
          type: string
          description: Unique PSP transaction identifier
        outcome:
          $ref: '#/components/schemas/AuthorizationOutcome'
        details:
          $ref: '#/components/schemas/TransactionResultDetails'
      description: Callback api transaction outcome request body
    TransactionResultResponse:
      required:
      - idTransaction
      - outcome
      type: object
      properties:
        idTransaction:
          $ref: '#/components/schemas/PagopaIdTransaction'
        outcome:
          $ref: '#/components/schemas/AuthorizationResponseOutcome'
      description: Callback api transaction outcome response body
    ProblemJson:
      type: object
      properties:
        type:
          type: string
          description: 'An absolute URI that identifies the problem type. When dereferenced,

            it SHOULD provide human-readable documentation for the problem type

            (e.g., using HTML).'
          format: uri
          default: about:blank
          example: https://example.com/problem/constraint-violation
        title:
          type: string
          description: 'A short, summary of the problem type. Written in english and readable

            for engineers (usually not suited for non technical stakeholders and

            not localized); example: Service Unavailable'
        status:
          $ref: '#/components/schemas/HttpStatusCode'
        detail:
          type: string
          description: 'A human readable explanation specific to this occurrence of the

            problem.'
          example: There was an error processing the request
        instance:
          type: string
          description: 'An absolute URI that identifies the specific occurrence of the problem.

            It may or may not yield further information if dereferenced.'
          format: uri
        idTransaction:
          $ref: '#/components/schemas/PagopaIdTransaction'
    AuthorizationOutcome:
      enum:
      - OK
      - KO
      - CANCELED
      - EXPIRED
      - ERROR
      type: string
      description: 'Transaction outcome enumeration.

        The outcome can assume the following values:

        * OK -> `Authorization completed successfully`

        * KO -> `Authorization KO (for example missing funds for transaction)`

        * CANCELED -> `User canceled the authorization process`

        * EXPIRED -> `Authorization process has not been completed before timeout set for the operation`

        * ERROR -> `An unexpected error occurred during authorization process`

        '
    TransactionDeniedOutcomeDetails:
      required:
      - errorCode
      type: object
      properties:
        errorCode:
          type: string
          description: Authorization error code
  securitySchemes:
    apiKeyHeader:
      type: apiKey
      name: Ocp-Apim-Subscription-Key
      in: header
    apiKeyQuery:
      type: apiKey
      name: subscription-key
      in: query