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

# /PartnerData

> Use the /PartnerData endpoint if you are a client of Flinks and want to grant access for a partner to retrieve data that is processed by Flinks. This endpoint generates a unique Access Token that's associated with a specific user.

Use the `/PartnerData` endpoint if you are a client of Flinks and want to grant access for a partner to retrieve data that is processed by Flinks. This endpoint generates a unique Access Token that's associated with a specific user. It's created based on the user's `loginId` and the `accountId`. Your partner uses this Access Token to retrieve data for that specific user.

Access tokens are valid for 30 days from the time they are created. To extend an Access Token by 30 days, call this endpoint again and provide the same information that you provided in the previous call.

Depending on your processes, your partner may need to provide information in addition to an Access Token. For example, if you are using a payments processor, you will likely attach the Access Token when creating a user. Let your partner know if there is additional information that they require for a successful API call.

<Warning>
  <p class="h4">Deleting Cards If you call the</p>
  [/DeleteCard](../../connect/endpoints/account-linking/delete-card) endpoint
  to delete data for a specific user, Access Tokens that are associated with
  that user will immediately become invalid and no data will be available for
  the partner to retrieve.
</Warning>


## OpenAPI

````yaml GET /v3/{customerId}/partnerdata/{LoginId}/{AccountId}
openapi: 3.0.3
info:
  title: Flinks API
  description: >
    Flinks API provides financial data connectivity, enrichment, and payment
    solutions.


    ## Authentication

    Endpoints require authentication using `flinks-auth-key` header (Bearer
    token).


    For more information, visit: https://docs.flinks.com
  version: 3.0.0
  contact:
    name: Flinks Support
    url: https://www.flinks.com/contact/sales
  termsOfService: https://www.flinks.com
servers:
  - url: https://{instance}-api.private.fin.ag
    description: Flinks API Environment
    variables:
      instance:
        default: toolbox
        description: The environment instance (e.g., toolbox, sandbox, production)
security: []
tags:
  - name: Authorization
    description: Endpoints for generating authorization tokens and authenticating requests
  - name: Enrich - Consumer Attributes
    description: Consumer financial attribute analysis and credit risk assessment
paths:
  /v3/{customerId}/partnerdata/{LoginId}/{AccountId}:
    get:
      tags:
        - Authorization
      summary: Get Partner Data
      description: >-
        Use the /PartnerData endpoint if you are a client of Flinks and want to
        grant access for a partner to retrieve data that is processed by Flinks.
        This endpoint generates a unique Access Token that's associated with a
        specific user.
      operationId: getPartnerData
      parameters:
        - name: customerId
          in: path
          required: true
          description: >-
            Key that grants access to the environment specified in the instance
            field. By default, the value is set to the toolbox environment key.
          schema:
            type: string
            default: 43387ca6-0391-4c82-857d-70d95f087ecb
        - name: LoginId
          in: path
          required: true
          description: >-
            Unique identifier that represents a specific user. This value is
            available after successfully calling the /Authorize endpoint.
          schema:
            type: string
        - name: AccountId
          in: path
          required: true
          description: Unique identifier that represents a specific user account.
          schema:
            type: string
        - name: Authorization
          in: header
          required: false
          description: >-
            Contains the Bearer Token (the API secret key that Flinks provides
            you with).
          schema:
            type: string
            default: Bearer {API Secret}
      responses:
        '200':
          description: Response Body
          content:
            application/json:
              schema:
                type: object
                properties:
                  RequestId:
                    type: string
                    description: Unique identifier for this request.
                  AccessToken:
                    type: string
                    description: >-
                      The unique Access Token that your partner can use to
                      retrieve data for the specific user.
                  Date:
                    type: string
                    description: Timestamp when the Access Token was created.
                  ExpirationDate:
                    type: string
                    description: >-
                      Timestamp when the Access Token expires (30 days from
                      creation).
              example:
                RequestId: 565c7b7a-fc01-45a1-aa7d-baaaa703a51b
                AccessToken: 6087f84c-15ba-4113-82aa-a9d22ea6caac
                Date: '2023-04-11T15:04:43.3464411Z'
                ExpirationDate: '2023-05-12T19:09:02.9650245Z'
        '400':
          description: Response Body
          content:
            application/json:
              schema:
                type: object
                properties:
                  HttpStatusCode:
                    type: integer
                    description: HTTP status code of the response.
                  ValidationDetails:
                    type: object
                    description: Validation error details.
                    properties:
                      loginId:
                        type: array
                        items:
                          type: string
                        description: >-
                          Validation error messages for the loginId or
                          accountId.
                      accountId:
                        type: array
                        items:
                          type: string
                        description: Validation error messages for the accountId.
                  FlinksCode:
                    type: string
                    description: Flinks-specific error code (e.g., INVALID_REQUEST).
              examples:
                InvalidLoginId:
                  value:
                    HttpStatusCode: 400
                    ValidationDetails:
                      loginId:
                        - This loginId doesn't exist.
                    FlinksCode: INVALID_REQUEST
                InvalidAccountId:
                  value:
                    HttpStatusCode: 400
                    ValidationDetails:
                      accountId:
                        - This accountId doesn't exist within the Card.
                    FlinksCode: INVALID_REQUEST
      security: []

````