# Postman (/en/docs/conta-digital/postman)

<QuickLinks>
  <QuickLink href="https://docs.payzu.com.br/payzu-conta-digital.postman_collection.json" title="Collection (JSON)" />

  <QuickLink href="/conta-digital-openapi.json" title="OpenAPI" />

  <QuickLink href="/api-scalar-conta-digital" title="Scalar" />

  <QuickLink href="/api-swagger-conta-digital" title="Swagger" />
</QuickLinks>

The **PayZu Conta Digital API** collection has one folder per path segment: `POST /transactions/payment/{paymentId}/refund` is in `transactions › payment › {paymentId} › refund`. Each request comes with a saved example response.

<Callout type="warn">
  The calls go to **production** and move real money in the credential's account.
</Callout>

<Steps>
  <Step>
    ### Import the collection [#import-the-collection]

    In Postman, **Import → Link**:

    ```
    https://docs.payzu.com.br/payzu-conta-digital.postman_collection.json
    ```
  </Step>

  <Step>
    ### Fill in the credential [#fill-in-the-credential]

    In the collection variables, fill in `clientId` and `clientSecret`:

    | Variable       | Value                                         |
    | -------------- | --------------------------------------------- |
    | `baseUrl`      | `https://api.hub.payzu.com.br/api/v1`         |
    | `clientId`     | The credential's `client_id`                  |
    | `clientSecret` | The credential's `client_secret`              |
    | `token`        | Filled in by the **Get access token** request |
  </Step>

  <Step>
    ### Get the token [#get-the-token]

    Run **Get access token** (`POST /oauth/token`). It uses Basic Auth with `clientId` and `clientSecret` and, on the `200` response, saves the `access_token` in `token`.

    The token is valid for 15 minutes. When requests start responding `401` with `TOKEN_INVALID`, run **Get access token** again.
  </Step>

  <Step>
    ### Call the routes [#call-the-routes]

    The other requests inherit the `Authorization: Bearer {{token}}` header from the collection. Just pick the request and send it.
  </Step>
</Steps>

## Repeat a withdrawal, Pix copy-and-paste payment or transfer [#repeat-a-withdrawal-pix-copy-and-paste-payment-or-transfer]

The withdrawal, Pix copy-and-paste payment and transfer requests already send `Idempotency-Key`. The collection creates the key before the first send and discards it only when a response below `500` arrives. After a `5xx` or a network failure, send again: the key is the same, and the operation is not duplicated.