---
agentTools:
  projectIndex: https://developers.commerce.busha.co/llms.txt
---

# Update Payment Link

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Commerce",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://api.commerce.busha.co"
    }
  ],
  "security": [
    {}
  ],
  "paths": {
    "/payment_links/{id}": {
      "put": {
        "summary": "Update Payment Link",
        "description": "",
        "operationId": "update-checkout",
        "parameters": [
          {
            "name": "X-BC-API-KEY",
            "in": "header",
            "description": "Your business secret key",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "id",
            "in": "path",
            "description": "id(uuid) of the payment link",
            "schema": {
              "type": "string"
            },
            "required": true
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "name",
                  "description",
                  "payment_link_type"
                ],
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "name of payment link"
                  },
                  "description": {
                    "type": "string",
                    "description": "description of payment link"
                  },
                  "payment_link_type": {
                    "type": "string",
                    "description": "donation or fixed_price"
                  },
                  "local_amount": {
                    "type": "string",
                    "description": "amount in local currency if the `payment_link_type` is not donation"
                  },
                  "requested_info": {
                    "type": "array",
                    "description": "The requested information you need from the customer. Can also be an empty array. <br/> <b> N.B </b> You can add additional meta keys apart from name and email used below.",
                    "default": [
                      "name",
                      "email"
                    ],
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"status\": \"success\",\n    \"message\": \"payment link updated successfully\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "status": {
                      "type": "string",
                      "example": "success"
                    },
                    "message": {
                      "type": "string",
                      "example": "payment link updated successfully"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"error\": {\n        \"name\": \"bad_request\",\n        \"message\": \"the local_amount value must be greater than 0 since the type is fixed_price\"\n    }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string",
                          "example": "bad_request"
                        },
                        "message": {
                          "type": "string",
                          "example": "the local_amount value must be greater than 0 since the type is fixed_price"
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true,
  "_id": "63f94c2f2017a0005783edff:63fde8cf8b6b16003e7fb3b5"
}
```