# Update Pay Out payment link PATCH https://api-sandbox.payabli.com/api/PaymentLink/out/{paylinkId} Content-Type: application/json Partially updates a Pay Out payment link's content, expiration date, and/or status. Use this to modify the payment page configuration, extend or change the expiration, or cancel a link. Updating the expiration date of an expired link reactivates it to Active status. Reference: https://docs.payabli.com/developers/api-reference/paymentlink/update-payout-payment-link ## OpenAPI Specification ```yaml openapi: 3.1.0 info: title: payabliApi version: 1.0.0 paths: /PaymentLink/out/{paylinkId}: patch: operationId: patch-out-payment-link summary: Update Pay Out payment link description: >- Partially updates a Pay Out payment link's content, expiration date, and/or status. Use this to modify the payment page configuration, extend or change the expiration, or cancel a link. Updating the expiration date of an expired link reactivates it to Active status. tags: - subpackage_paymentLink parameters: - name: paylinkId in: path description: ID for the payment link. required: true schema: type: string - name: requestToken in: header required: true schema: type: string responses: '200': description: Success content: application/json: schema: $ref: >- #/components/schemas/type_paymentLink:PayabliApiResponsePaymentLinks '400': description: Bad request/ invalid data content: application/json: schema: description: Any type '401': description: Unauthorized request. content: application/json: schema: description: Any type '500': description: Internal API Error content: application/json: schema: description: Any type '503': description: Database connection error content: application/json: schema: $ref: '#/components/schemas/type_:PayabliApiResponse' requestBody: content: application/json: schema: $ref: '#/components/schemas/type_paymentLink:PatchOutPaymentLinkRequest' servers: - url: https://api-sandbox.payabli.com/api - url: https://api.payabli.com/api components: schemas: type_:Enabled: type: boolean description: Toggles whether the section or element is enabled. title: Enabled type_:Order: type: integer description: Order of element or section in container. title: Order type_:ContactElement: type: object properties: emailLabel: type: string description: Custom content for email enabled: $ref: '#/components/schemas/type_:Enabled' header: type: string description: Header text for section order: $ref: '#/components/schemas/type_:Order' paymentIcons: type: boolean description: Flag indicating if icons for accepted card brands will be shown phoneLabel: type: string description: Custom content for phone number title: ContactElement type_:Element: type: object properties: enabled: $ref: '#/components/schemas/type_:Enabled' order: $ref: '#/components/schemas/type_:Order' title: Element type_:LabelElement: type: object properties: enabled: $ref: '#/components/schemas/type_:Enabled' label: type: string description: Label to display for section or element order: $ref: '#/components/schemas/type_:Order' title: LabelElement type_:NoteElement: type: object properties: enabled: $ref: '#/components/schemas/type_:Enabled' header: type: string description: Header text for section order: $ref: '#/components/schemas/type_:Order' placeholder: type: string description: Placeholder text for input field value: type: string description: Pre-populated value for input field title: NoteElement type_:PageElement: type: object properties: description: type: string description: Page description in header enabled: $ref: '#/components/schemas/type_:Enabled' header: type: string description: Page header order: $ref: '#/components/schemas/type_:Order' title: PageElement type___moneyOutTypes__:MethodsListOut: type: object properties: ach: type: boolean description: When `true`, ACH bank transfer is offered as a payout method. check: type: boolean description: When `true`, physical check is offered as a payout method. vcard: type: boolean description: When `true`, virtual card (vCard) is offered as a payout method. description: >- Payment methods available for Pay Out payment links. Controls which payout options are offered to the vendor. title: MethodsListOut type___moneyOutTypes__:MethodElementOut: type: object properties: allMethodsChecked: type: boolean description: Flag indicating if all allowed payment methods will be pre-selected. allowMultipleMethods: type: boolean description: >- When `true`, the vendor can select from multiple payment methods. When `false`, only the default method is shown. defaultMethod: type: string description: >- The default payment method to highlight on the payment link page. For example, `"vcard"`, `"ach"`, or `"check"`. enabled: type: boolean description: >- When `true`, the payment methods section is displayed on the payment link page. header: type: string description: Header text for the payment methods section. methods: $ref: '#/components/schemas/type___moneyOutTypes__:MethodsListOut' order: type: integer description: Display order of the payment methods section on the page. showPreviewVirtualCard: type: boolean description: >- When `true`, a preview of the virtual card is shown on the payment link page. description: Configuration for payment method selection on Pay Out payment links. title: MethodElementOut type_:HeaderElement: type: object properties: enabled: $ref: '#/components/schemas/type_:Enabled' header: type: string description: Header text for section order: $ref: '#/components/schemas/type_:Order' title: HeaderElement type_:FileContentFtype: type: string enum: - pdf - doc - docx - jpg - jpeg - png - gif - txt description: The MIME type of the file (if content is provided) title: FileContentFtype type_:FileContent: type: object properties: fContent: type: string description: >- Content of file, Base64-encoded. Ignored if furl is specified. Max upload size is 30 MB. filename: type: string description: The name of the attached file. ftype: $ref: '#/components/schemas/type_:FileContentFtype' description: The MIME type of the file (if content is provided) furl: type: string description: Optional URL provided to show or download the file remotely description: Contains details about a file. Max upload size is 30 MB. title: FileContent type_:PagelinkSetting: type: object properties: color: type: string description: 'An HTML color code in format #RRGGBB' customCssUrl: type: string description: Complete URL to a custom CSS file to be loaded with the page language: type: string description: Two-letter code following ISO 639-1 pageLogo: $ref: '#/components/schemas/type_:FileContent' description: Object containing logo file to upload/ use in page redirectAfterApprove: type: boolean description: >- Flag indicating if the capability for redirection in the page will be activated redirectAfterApproveUrl: type: string description: Complete URL where the page will be redirected after completion title: PagelinkSetting type_paymentLink:PaymentPageRequestBodyOut: type: object properties: contactUs: $ref: '#/components/schemas/type_:ContactElement' description: ContactUs section of payment link page. logo: $ref: '#/components/schemas/type_:Element' description: Logo section of payment link page. messageBeforePaying: $ref: '#/components/schemas/type_:LabelElement' description: Message section of payment link page. notes: $ref: '#/components/schemas/type_:NoteElement' description: Notes section of payment link page. page: $ref: '#/components/schemas/type_:PageElement' description: Page header section of payment link page. paymentButton: $ref: '#/components/schemas/type_:LabelElement' description: Payment button section of payment link page. paymentMethods: $ref: '#/components/schemas/type___moneyOutTypes__:MethodElementOut' description: >- Payment methods section of payment link page. Use this to configure which payout methods (ACH, vCard, check) are offered to the vendor. review: $ref: '#/components/schemas/type_:HeaderElement' description: Review section of payment link page. bills: $ref: '#/components/schemas/type_:Element' description: Bills section of payment link page. settings: $ref: '#/components/schemas/type_:PagelinkSetting' description: Settings section of payment link page. description: >- Configuration for the Pay Out payment link page. Controls branding, messaging, vendor fields, and which payout methods are offered to the vendor. title: PaymentPageRequestBodyOut type___moneyOutTypes__:PaymentLinkStatus: type: string enum: - Active - Expired - Canceled - Deleted description: The status of a payment link. title: PaymentLinkStatus type_paymentLink:PatchOutPaymentLinkRequest: type: object properties: billPageData: $ref: '#/components/schemas/type_paymentLink:PaymentPageRequestBodyOut' description: Updated payment link page configuration. expirationDate: type: string description: >- New expiration date for the payment link. Must be a future date. If null and the link is expired, uses the default expiration from settings. Updating the expiration date reactivates an expired payment link to Active status. status: $ref: '#/components/schemas/type___moneyOutTypes__:PaymentLinkStatus' description: Updated status for the payment link. description: Request body for partially updating a Pay Out payment link. title: PatchOutPaymentLinkRequest type_:IsSuccess: type: boolean description: >- Boolean indicating whether the operation was successful. A `true` value indicates success. A `false` value indicates failure. title: IsSuccess type_:ResponseText: type: string description: 'Response text for operation: ''Success'' or ''Declined''.' title: ResponseText type_paymentLink:PayabliApiResponsePaymentLinks: type: object properties: isSuccess: $ref: '#/components/schemas/type_:IsSuccess' responseData: type: string description: >- If `isSuccess` = true, this contains the payment link identifier. If `isSuccess` = false, this contains the reason of the error. responseText: $ref: '#/components/schemas/type_:ResponseText' required: - isSuccess - responseText title: PayabliApiResponsePaymentLinks type_:Responsedata: type: object additionalProperties: description: Any type description: The object containing the response data. title: Responsedata type_:PayabliApiResponse: type: object properties: isSuccess: $ref: '#/components/schemas/type_:IsSuccess' responseData: $ref: '#/components/schemas/type_:Responsedata' responseText: $ref: '#/components/schemas/type_:ResponseText' required: - responseText title: PayabliApiResponse securitySchemes: ApiKeyAuth: type: apiKey in: header name: requestToken ``` ## SDK Code Examples ```python ReactivateExpiredLink import requests url = "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload = { "expirationDate": "2026-06-01T00:00:00Z", "status": "Active" } headers = { "requestToken": "", "Content-Type": "application/json" } response = requests.patch(url, json=payload, headers=headers) print(response.json()) ``` ```javascript ReactivateExpiredLink const url = 'https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234'; const options = { method: 'PATCH', headers: {requestToken: '', 'Content-Type': 'application/json'}, body: '{"expirationDate":"2026-06-01T00:00:00Z","status":"Active"}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go ReactivateExpiredLink package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload := strings.NewReader("{\n \"expirationDate\": \"2026-06-01T00:00:00Z\",\n \"status\": \"Active\"\n}") req, _ := http.NewRequest("PATCH", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby ReactivateExpiredLink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"expirationDate\": \"2026-06-01T00:00:00Z\",\n \"status\": \"Active\"\n}" response = http.request(request) puts response.read_body ``` ```java ReactivateExpiredLink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"expirationDate\": \"2026-06-01T00:00:00Z\",\n \"status\": \"Active\"\n}") .asString(); ``` ```php ReactivateExpiredLink request('PATCH', 'https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234', [ 'body' => '{ "expirationDate": "2026-06-01T00:00:00Z", "status": "Active" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```csharp ReactivateExpiredLink using RestSharp; var client = new RestClient("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234"); var request = new RestRequest(Method.PATCH); request.AddHeader("requestToken", ""); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "{\n \"expirationDate\": \"2026-06-01T00:00:00Z\",\n \"status\": \"Active\"\n}", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift ReactivateExpiredLink import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = [ "expirationDate": "2026-06-01T00:00:00Z", "status": "Active" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```python CancelPaymentLink import requests url = "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload = { "status": "Canceled" } headers = { "requestToken": "", "Content-Type": "application/json" } response = requests.patch(url, json=payload, headers=headers) print(response.json()) ``` ```javascript CancelPaymentLink const url = 'https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234'; const options = { method: 'PATCH', headers: {requestToken: '', 'Content-Type': 'application/json'}, body: '{"status":"Canceled"}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go CancelPaymentLink package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload := strings.NewReader("{\n \"status\": \"Canceled\"\n}") req, _ := http.NewRequest("PATCH", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CancelPaymentLink require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"status\": \"Canceled\"\n}" response = http.request(request) puts response.read_body ``` ```java CancelPaymentLink import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"status\": \"Canceled\"\n}") .asString(); ``` ```php CancelPaymentLink request('PATCH', 'https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234', [ 'body' => '{ "status": "Canceled" }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```csharp CancelPaymentLink using RestSharp; var client = new RestClient("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234"); var request = new RestRequest(Method.PATCH); request.AddHeader("requestToken", ""); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "{\n \"status\": \"Canceled\"\n}", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift CancelPaymentLink import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["status": "Canceled"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ```python UpdatePageContent import requests url = "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload = { "billPageData": { "page": { "description": "You have a payment waiting", "enabled": True, "header": "Vendor Payment", "order": 0 }, "paymentButton": { "enabled": True, "label": "Select Payment Method", "order": 0 }, "paymentMethods": { "allMethodsChecked": True, "allowMultipleMethods": True, "defaultMethod": "ach", "enabled": True, "header": "Payment Methods", "methods": { "ach": True, "check": True, "vcard": True }, "order": 0, "showPreviewVirtualCard": False } } } headers = { "requestToken": "", "Content-Type": "application/json" } response = requests.patch(url, json=payload, headers=headers) print(response.json()) ``` ```javascript UpdatePageContent const url = 'https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234'; const options = { method: 'PATCH', headers: {requestToken: '', 'Content-Type': 'application/json'}, body: '{"billPageData":{"page":{"description":"You have a payment waiting","enabled":true,"header":"Vendor Payment","order":0},"paymentButton":{"enabled":true,"label":"Select Payment Method","order":0},"paymentMethods":{"allMethodsChecked":true,"allowMultipleMethods":true,"defaultMethod":"ach","enabled":true,"header":"Payment Methods","methods":{"ach":true,"check":true,"vcard":true},"order":0,"showPreviewVirtualCard":false}}}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go UpdatePageContent package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234" payload := strings.NewReader("{\n \"billPageData\": {\n \"page\": {\n \"description\": \"You have a payment waiting\",\n \"enabled\": true,\n \"header\": \"Vendor Payment\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Select Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"ach\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": false\n }\n }\n}") req, _ := http.NewRequest("PATCH", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby UpdatePageContent require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Patch.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"billPageData\": {\n \"page\": {\n \"description\": \"You have a payment waiting\",\n \"enabled\": true,\n \"header\": \"Vendor Payment\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Select Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"ach\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": false\n }\n }\n}" response = http.request(request) puts response.read_body ``` ```java UpdatePageContent import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.patch("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234") .header("requestToken", "") .header("Content-Type", "application/json") .body("{\n \"billPageData\": {\n \"page\": {\n \"description\": \"You have a payment waiting\",\n \"enabled\": true,\n \"header\": \"Vendor Payment\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Select Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"ach\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": false\n }\n }\n}") .asString(); ``` ```php UpdatePageContent request('PATCH', 'https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234', [ 'body' => '{ "billPageData": { "page": { "description": "You have a payment waiting", "enabled": true, "header": "Vendor Payment", "order": 0 }, "paymentButton": { "enabled": true, "label": "Select Payment Method", "order": 0 }, "paymentMethods": { "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "ach", "enabled": true, "header": "Payment Methods", "methods": { "ach": true, "check": true, "vcard": true }, "order": 0, "showPreviewVirtualCard": false } } }', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```csharp UpdatePageContent using RestSharp; var client = new RestClient("https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234"); var request = new RestRequest(Method.PATCH); request.AddHeader("requestToken", ""); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "{\n \"billPageData\": {\n \"page\": {\n \"description\": \"You have a payment waiting\",\n \"enabled\": true,\n \"header\": \"Vendor Payment\",\n \"order\": 0\n },\n \"paymentButton\": {\n \"enabled\": true,\n \"label\": \"Select Payment Method\",\n \"order\": 0\n },\n \"paymentMethods\": {\n \"allMethodsChecked\": true,\n \"allowMultipleMethods\": true,\n \"defaultMethod\": \"ach\",\n \"enabled\": true,\n \"header\": \"Payment Methods\",\n \"methods\": {\n \"ach\": true,\n \"check\": true,\n \"vcard\": true\n },\n \"order\": 0,\n \"showPreviewVirtualCard\": false\n }\n }\n}", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift UpdatePageContent import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["billPageData": [ "page": [ "description": "You have a payment waiting", "enabled": true, "header": "Vendor Payment", "order": 0 ], "paymentButton": [ "enabled": true, "label": "Select Payment Method", "order": 0 ], "paymentMethods": [ "allMethodsChecked": true, "allowMultipleMethods": true, "defaultMethod": "ach", "enabled": true, "header": "Payment Methods", "methods": [ "ach": true, "check": true, "vcard": true ], "order": 0, "showPreviewVirtualCard": false ] ]] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/PaymentLink/out/2325-XXXXXXX-90b1-4598-b6c7-44cdcbf495d7-1234")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PATCH" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```