---
title: Await for payment status
slug: payment/await-for-payment-status
description: Learn how to use a Curl command to efficiently fetch the status of a payment with this comprehensive document. Discover the essential request method, headers, and path parameters required. Expect detailed information such as initiation ID, timestamps, con
docTags: 
createdAt: 2023-05-18T20:28:57.000Z
---

:::ApiMethodV2
```json
{
  "name": "status",
  "method": "GET",
  "url": "https://api-sandbox.klavi.ai/payment/customer/v1/instant/payments/{id}/status",
  "description": "Get status of the payment initiation",
  "tab": "examples",
  "examples": {
    "languages": [
      {
        "id": "FvwEq0nqdHAlyfFE0D0lg",
        "language": "curl",
        "code": "curl --location --globoff 'https://api-sandbox.klavi.ai/payment/customer/v1/instant/payments/{id}/status' \\\n--header 'Accept: application/json' \\\n--header 'Content-Type: application/json'",
        "customLabel": ""
      },
      {
        "id": "38MdWYdTAvYpkTMmyYuij",
        "language": "nodejs",
        "code": "var request = require('request');\nvar options = {\n   'method': 'GET',\n   'url': 'https://api-sandbox.klavi.ai/payment/customer/v1/instant/payments/{id}/status',\n   'headers': {\n      'Accept': 'application/json',\n      'Content-Type': 'application/json'\n   }\n};\nrequest(options, function (error, response) {\n   if (error) throw new Error(error);\n   console.log(response.body);\n});\n",
        "customLabel": ""
      },
      {
        "id": "GqMRq8B-BaIol-Lhm8r-M",
        "language": "javascript",
        "code": "var request = require('request');\nvar options = {\n   'method': 'GET',\n   'url': 'https://api-sandbox.klavi.ai/payment/customer/v1/instant/payments/{id}/status',\n   'headers': {\n      'Accept': 'application/json',\n      'Content-Type': 'application/json'\n   }\n};\nrequest(options, function (error, response) {\n   if (error) throw new Error(error);\n   console.log(response.body);\n});\n",
        "customLabel": ""
      },
      {
        "id": "QhraFI5SKZH7MTWa1slP8",
        "language": "python",
        "code": "import requests\nimport json\n\nurl = \"https://api-sandbox.klavi.ai/payment/customer/v1/instant/payments/{id}/status\"\n\npayload = {}\nheaders = {\n   'Accept': 'application/json',\n   'Content-Type': 'application/json'\n}\n\nresponse = requests.request(\"GET\", url, headers=headers, data=payload)\n\nprint(response.text)\n",
        "customLabel": ""
      },
      {
        "id": "W3_GCWGthoXS0BiB3Io0w",
        "language": "ruby",
        "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"https://api-sandbox.klavi.ai/payment/customer/v1/instant/payments/{id}/status\")\n\nhttps = Net::HTTP.new(url.host, url.port)\nhttps.use_ssl = true\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"Accept\"] = \"application/json\"\nrequest[\"Content-Type\"] = \"application/json\"\n\nresponse = https.request(request)\nputs response.read_body\n",
        "customLabel": ""
      }
    ],
    "selectedLanguageId": "W3_GCWGthoXS0BiB3Io0w"
  },
  "results": {
    "languages": [
      {
        "id": "Pw8jS_Gdbzl6HbfnZuNcU",
        "language": "200",
        "customLabel": "",
        "code": "{\n    \"id\": \"cfa45795-fe16-48e2-a372-130e30a72606\",\n    \"clientRequestId\": \"1a3s2aebe29s2\", \n    \"amount\": \"1333.04\", \n    \"currency\": \"BRL\", \n    \"status\": \"CONSENT_AUTHORIED\", \n    \"statusReason\": {\n        \"code\": \"NAO_INFORMADO\", \n        \"message\": \"Erro não informado na iniciadora ou detentora de conta.\" \n    }, \n    \"statusUpdateAt\": \"2022-09-23T03:39:43.737Z\" \n}"
      }
    ],
    "selectedLanguageId": "Pw8jS_Gdbzl6HbfnZuNcU"
  },
  "request": {
    "pathParameters": [
      {
        "name": "id",
        "kind": "required",
        "type": "string",
        "description": "Payment initiation order id, it will be returned when POST /payments is called.",
        "": "Payment initiation order id, it will be returned when POST /payments is called."
      }
    ],
    "queryParameters": [],
    "headerParameters": [
      {
        "name": "Authorization",
        "kind": "required",
        "type": "string",
        "description": "JWT bearer token",
        "children": []
      }
    ],
    "bodyDataParameters": [],
    "formDataParameters": []
  },
  "currentNewParameter": {
    "label": "Path Parameter",
    "value": "pathParameters"
  },
  "response": [
    {
      "name": "id",
      "kind": "optional",
      "type": "string",
      "description": "ID of the payment order"
    },
    {
      "name": "clientRequestId",
      "kind": "optional",
      "type": "string",
      "description": "merchant's internal orderId. Only can be used for once. ",
      "children": []
    },
    {
      "name": "amount",
      "kind": "optional",
      "type": "string",
      "description": "Amount that will be paid by the user",
      "children": []
    },
    {
      "name": "currency",
      "kind": "optional",
      "type": "string",
      "description": "Currency",
      "children": []
    },
    {
      "name": "status",
      "kind": "optional",
      "type": "string",
      "description": "Status",
      "children": []
    },
    {
      "name": "statusReason",
      "kind": "optional",
      "type": "object",
      "description": "Status update reason",
      "children": [
        {
          "name": "code",
          "kind": "optional",
          "type": "string",
          "description": ""
        },
        {
          "name": "message",
          "kind": "optional",
          "type": "string",
          "description": ""
        }
      ]
    },
    {
      "name": "statusUpdateAt",
      "kind": "optional",
      "type": "string",
      "description": "Status update time",
      "children": []
    }
  ],
  "hasTryItOut": false,
  "autoGeneratedAnchorSlug": "status",
  "legacyHash": "O1khwdXmeACLHIqit_KN6"
}
```
:::

:::hint{type="info"}
If the `status` of user consent is `CONSENT_AUTHORIZED` means that the authentication has been passed, and `redirectConsentURL` will not be returned.

`redirectConsentURL`: **This url can only be accessed once, and it has 60 seconds to be accessed.&#x20;**
:::

