> ## Documentation Index
> Fetch the complete documentation index at: https://docs.go.gbgplc.com/llms.txt
> Use this file to discover all available pages before exploring further.

> Fetch the current interaction in a GBG GO journey to determine which domain elements to collect from the end user.

# Fetch Interaction



## OpenAPI

````yaml docs/go-v2/openapi-v2.json POST /journey/interaction/fetch
openapi: 3.0.4
info:
  title: GBG GO API Reference V2
  description: >-
    The GBG GO V2 API enables authentication, customer journey execution, task
    management, and tracking verification progress.
  version: 2.0.0
  license:
    name: MIT
servers:
  - url: https://eu.platform.go.gbgplc.com/v2/captain/
  - url: https://us.platform.go.gbgplc.com/v2/captain/
  - url: https://au.platform.go.gbgplc.com/v2/captain/
  - url: https://api.auth.gbgplc.com/as/token.oauth2
security:
  - bearerAuth: []
paths:
  /journey/interaction/fetch:
    post:
      tags:
        - Interaction Service
      summary: Fetch Interaction
      description: >-
        Get the current interaction state for an active journey instance,
        including pages, cards, and domain element configuration.
      operationId: fetchInteraction
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                instanceId:
                  type: string
                  description: Journey instance identifier
              required:
                - instanceId
              additionalProperties: false
            example:
              instanceId: PiKR2O0IjyUR8KV3RviKt4we
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                anyOf:
                  - type: object
                    properties:
                      instanceId:
                        type: string
                        description: Journey instance identifier
                      interactionId:
                        type: string
                        description: Interaction identifier
                      journey:
                        type: object
                        properties:
                          status:
                            type: string
                            enum:
                              - InProgress
                              - Completed
                              - Failed
                        required:
                          - status
                        additionalProperties: false
                        description: Current journey state.
                      interaction:
                        type: object
                        properties:
                          resource:
                            type: object
                            properties:
                              id:
                                type: string
                                description: Unique identifier for the interaction resource
                              name:
                                type: string
                                pattern: ^.{1,128}$
                                description: Name of the interaction resource
                              hash:
                                type: string
                                pattern: ^[a-zA-Z0-9_/=+-]{1,128}$
                                description: Hash of the resource for version tracking
                              version:
                                type: string
                                pattern: ^[a-zA-Z0-9_./=+-]{1,64}$
                                description: Version of the interaction resource
                              type:
                                type: string
                                enum:
                                  - brand
                                  - delivery
                                  - flow
                                  - form
                                  - i18n
                                  - journey
                                  - license
                                  - model
                                  - organization
                                  - template
                                  - interaction
                                description: Type of the resource
                              data:
                                type: object
                                properties:
                                  pages:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        id:
                                          type: string
                                        label:
                                          type: string
                                        cards:
                                          type: array
                                          items:
                                            type: object
                                            properties:
                                              id:
                                                type: string
                                              version:
                                                type: string
                                              config: {}
                                            required:
                                              - id
                                            additionalProperties: false
                                      required:
                                        - id
                                        - cards
                                      additionalProperties: false
                                required:
                                  - pages
                                additionalProperties: false
                                description: >-
                                  Resource data containing page and card
                                  definitions
                            required:
                              - id
                              - name
                            additionalProperties: false
                            description: >-
                              The interaction resource definition, including its
                              pages and cards.
                          collects:
                            type: array
                            description: >-
                              Data elements the interaction collects from the
                              user
                            items:
                              type: object
                              properties:
                                ref:
                                  type: string
                                  description: Reference identifier for the data element
                                spec:
                                  type: string
                                  enum:
                                    - required
                                    - optional
                                    - conditional
                                  description: >-
                                    Whether this element is required, optional,
                                    or conditional
                                recommended:
                                  type: boolean
                                  description: Whether this element is recommended
                              required:
                                - ref
                                - spec
                              additionalProperties: false
                          consumes:
                            type: array
                            description: Data elements the interaction consumes (reads)
                            items:
                              type: object
                              properties:
                                ref:
                                  type: string
                                  description: Reference identifier for the data element
                                spec:
                                  type: string
                                  enum:
                                    - required
                                    - optional
                                    - conditional
                                  description: >-
                                    Whether this element is required, optional,
                                    or conditional
                                recommended:
                                  type: boolean
                                  description: Whether this element is recommended
                              required:
                                - ref
                                - spec
                              additionalProperties: false
                          grId:
                            type: string
                            description: Group identifier for the interaction
                        required:
                          - resource
                          - collects
                          - consumes
                          - grId
                        additionalProperties: false
                        description: >-
                          The current interaction definition, including the
                          resource (pages/cards) and data collection
                          requirements.
                      outstanding:
                        type: array
                        description: >-
                          List of data element references that are still
                          required but not yet collected.
                        items:
                          type: string
                    required:
                      - instanceId
                      - interactionId
                      - journey
                      - interaction
                      - outstanding
                    additionalProperties: false
                  - type: object
                    properties:
                      status:
                        type: string
                        enum:
                          - error
                      code:
                        type: number
                        description: Error code
                      message:
                        type: string
                        description: Error message
                    required:
                      - status
                      - code
                      - message
                    additionalProperties: false
              examples:
                success:
                  value:
                    instanceId: Pq_hhIX6-sHUy9FLSDzPLu
                    interactionId: grn:::gbg:design:interaction:segment1@latest
                    journey:
                      status: InProgress
                    interaction:
                      grId: grn:::gbg:design:interaction:segment1@latest
                      resource:
                        id: segment1
                        name: segment1
                        version: latest
                        type: interaction
                        data:
                          pages:
                            - id: personal_details
                              label: Personal details
                              cards:
                                - id: NameCard
                                - id: DateOfBirthCard
                                - id: IdentifierCardSSN
                                - id: ControlCard
                            - id: contact_details
                              label: Contact details
                              cards:
                                - id: EmailCardPersonalEmail
                                - id: PhoneCardMobilePhone
                                - id: ControlCard
                            - id: address_details
                              label: Address details
                              cards:
                                - id: AddressCard
                                  config:
                                    secrets:
                                      loqateApiKey:
                                        value: WJ28-WP43-WG34-YD87
                                - id: ControlCard
                            - id: previous_addresses
                              label: Previous Addresses
                              cards:
                                - id: PreviousAddressesCard
                                - id: ControlCard
                            - id: document_capture
                              label: Document Capture
                              cards:
                                - id: DocumentCard
                      collects:
                        - ref: FullName
                          spec: required
                        - ref: DateOfBirth
                          spec: required
                        - ref: CurrentAddress
                          spec: required
                        - ref: PreviousAddresses
                          spec: optional
                        - ref: MobilePhone
                          spec: optional
                        - ref: PersonalEmail
                          spec: optional
                        - ref: SSN
                          spec: optional
                        - ref: PrimaryDocument
                          spec: required
                      consumes: []
                    outstanding:
                      - FullName
                      - DateOfBirth
                      - CurrentAddress
                      - PrimaryDocument
                error:
                  value:
                    status: error
                    code: 500
                    message: Internal error
        '400':
          description: Bad Request
          content:
            application/json: {}
        '401':
          description: Unauthorized
          content:
            application/json: {}
        '403':
          description: Forbidden
          content:
            application/json: {}
        '404':
          description: Not Found
          content:
            application/json: {}
        '405':
          description: Method Not Allowed
          content:
            application/json: {}
        '500':
          description: Internal Server Error
          content:
            application/json: {}
        '503':
          description: Service Unavailable
          content:
            application/json: {}
      security:
        - InteractionAccess: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
    InteractionAccess:
      type: http
      scheme: bearer

````