---
title: Amend Payment Schedule
slug: r10-integration/amend-payment-schedule
createdAt: 2026-10-29T06:44:31.903Z
---

{
  "id": "YTDkKhF1XImYpLfI7cmtR",
  "type": "api-oas-v2",
  "data": {
    "method": "PUT",
    "url": "https://api-beta.monoova.com/au/payto/pam-v1/PaymentSchedule/{scheduleId}",
    "servers": [
      {
        "url": "https://api-beta.monoova.com/au/payto/pam-v1/PaymentSchedule/{scheduleId}",
        "description": "Beta Sandbox URL"
      }
    ],
    "name": "Amend Payment Schedule",
    "description": "Amend an existing payment schedule.",
    "contentType": "application/json",
    "request": {
      "pathParameters": [
        {
          "kind": "required",
          "name": "scheduleId",
          "type": "string",
          "example": "MONSCH12345",
          "description": "<p>ID that uniquely identifies the payment schedule. This is the <code>scheduleId</code> supplied when the schedule was created.</p>",
          "default": "MONSCH12345",
          "pattern": "^[a-zA-Z0-9_-]{1,36}$"
        }
      ],
      "headerParameters": [
        {
          "name": "accept",
          "type": "string",
          "kind": "optional",
          "description": "Generated from available response content types",
          "enum": [
            "application/json"
          ],
          "default": "application/json"
        }
      ],
      "queryParameters": [],
      "bodyDataParameters": [
        {
          "kind": "required",
          "name": "body",
          "type": "object",
          "description": "Changes to a payment schedule. Include only the fields you want to change.",
          "customType": "MandateManager.Application.PaymentSchedules.Dto.AmendPaymentScheduleDtoIn",
          "schema": [
            {
              "name": "startDate",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "<p><strong>Optional</strong>. Start date of the schedule, in <code>YYYY-MM-DD</code> format. The schedule is valid from 00:00</p><div></div>.000 Sydney time on this date.<p></p>\n<p>Cannot be amended after the schedule has started; otherwise must be a future date. Cannot be earlier than the payment agreement <code>startDate</code> or later than the payment agreement <code>endDate</code>. If not provided, the existing schedule <code>startDate</code> is kept.</p>",
              "example": "2027-01-15",
              "default": "2027-01-15",
              "pattern": "^\\d{4}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])$"
            },
            {
              "name": "endDate",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "<p><strong>Optional</strong>. End date of the schedule, in <code>YYYY-MM-DD</code> format. If specified, the schedule is valid until 23:59</p><div></div>.999 Sydney time on this date.<p></p>\n<p>Cannot be earlier than <code>startDate</code> or later than the payment agreement <code>endDate</code>. If not provided, defaults to the payment agreement <code>endDate</code>, if any.</p>",
              "example": "2027-12-15",
              "default": "2027-12-15",
              "pattern": "^\\d{4}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])$"
            },
            {
              "name": "frequency",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "<p><strong>Optional</strong>. Frequency of the scheduled payments. If not provided, defaults to <code>ADHO</code>.</p>\n<p>If the agreement frequency is <code>MNTH</code> and <code>pointInTime</code> is specified, the schedule frequency cannot be <code>DAIL</code>, <code>WEEK</code> or <code>FRTN</code>.</p>\n<p>Accepted values: <code>ADHO</code> (ad hoc), <code>DAIL</code> (daily), <code>FRTN</code> (fortnightly), <code>INDA</code> (intraday), <code>MIAN</code> (semi-annual), <code>MNTH</code> (monthly), <code>QURT</code> (quarterly), <code>WEEK</code> (weekly), <code>YEAR</code> (annual).</p>",
              "example": "MNTH",
              "default": "MNTH",
              "pattern": "^(ADHO|DAIL|FRTN|INDA|MIAN|MNTH|QURT|WEEK|YEAR)$"
            },
            {
              "name": "scheduledAmount",
              "kind": "optional",
              "type": "number<double>",
              "nullable": true,
              "description": "<p><strong>Conditional</strong>. Amount to be paid per scheduled payment. Defaults to the amount in the payment agreement. Mandatory if the payment agreement does not specify an amount.</p>",
              "example": 50,
              "default": 50,
              "format": "double",
              "pattern": "^[0-9]{1,16}(\\.[0-9]{1,2})?$"
            },
            {
              "name": "totalInstances",
              "kind": "optional",
              "type": "integer<int32>",
              "nullable": true,
              "description": "<p><strong>Optional</strong>. Maximum number of scheduled payments that will be attempted.</p>",
              "example": 12,
              "default": 12,
              "format": "int32",
              "pattern": "^[1-9][0-9]*$"
            },
            {
              "name": "totalAmount",
              "kind": "optional",
              "type": "number<double>",
              "nullable": true,
              "description": "<p><strong>Optional</strong>. Maximum total amount of scheduled payments that can be attempted.</p>",
              "example": 600,
              "default": 600,
              "format": "double",
              "pattern": "^[0-9]{1,16}(\\.[0-9]{1,2})?$"
            },
            {
              "name": "paymentReference",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "<p><strong>Optional</strong>. Unique reference, assigned by the creditor, for the sequence of scheduled payments, from 1 to 280 characters.</p>",
              "example": "ABC Corp monthly subscription",
              "default": "ABC Corp monthly subscription",
              "minLength": 1,
              "maxLength": 280,
              "pattern": "^[ -~]{1,280}$"
            }
          ],
          "modelRef": "#/components/schemas/MandateManager.Application.PaymentSchedules.Dto.AmendPaymentScheduleDtoIn",
          "isExpanded": true
        }
      ],
      "formDataParameters": [],
      "oAuthParameters": [
        {
          "id": "BearerAuth",
          "name": "BearerAuth",
          "kind": "optional",
          "type": "http",
          "description": "<p>Bearer token (JWT) used to authenticate PayTo API requests. Generate it with the Monoova security token endpoint (<code>/au/security/oauth-v1/Token</code>) using your mAccount number and API key, then send it in the <code>Authorization: Bearer &#x3C;token></code> header. Tokens are valid for 24 hours.</p>",
          "scheme": "bearer"
        }
      ],
      "cookieParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "OK. The payment schedule was amended.",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "Result of a payment schedule amendment.",
            "customType": "MandateManager.Application.PaymentSchedules.Dto.AmendPaymentScheduleResponse",
            "schema": [
              {
                "name": "traceId",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Unique ID for logging and tracing this request.",
                "example": "1dabfaa9-abe8-4d2d-a69a-b723079d84ed",
                "default": "1dabfaa9-abe8-4d2d-a69a-b723079d84ed",
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
              },
              {
                "name": "scheduleId",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "ID that uniquely identifies the payment schedule.",
                "example": "MONSCH12345",
                "default": "MONSCH12345",
                "pattern": "^[a-zA-Z0-9_-]{1,36}$"
              }
            ],
            "modelRef": "#/components/schemas/MandateManager.Application.PaymentSchedules.Dto.AmendPaymentScheduleResponse",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "400",
        "description": "<p>Bad Request. The request failed validation. See <code>errors</code> for details.</p>",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"traceId\":\"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\"errors\":[{\"errorCode\":\"PAM_SCHED_START_TOO_EARLY\",\"errorMessage\":\"startDate cannot be earlier than the payment agreement startDate\"}]}",
            "description": "Error response returned when a request fails.",
            "customType": "MandateManager.Application.Common.Dtos.ErrorResponse",
            "schema": [
              {
                "name": "traceId",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Unique ID for logging and tracing this request.",
                "example": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "default": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "array",
                "nullable": true,
                "description": "List of errors that occurred while processing the request.",
                "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorDto",
                "customType": "MandateManager.Application.Common.Dtos.ErrorDto[]",
                "schema": [
                  {
                    "name": "errorCode",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>Monoova error code. See <a href=\"https://developer.monoova.com/payto-status-and-error-codes\" target=\"_blank\">PayTo Status and Error Codes</a> for the meaning of each code.</p>",
                    "example": "PAM_STARTDATE_EARLY",
                    "default": "PAM_STARTDATE_EARLY",
                    "pattern": "^[A-Z]{3}_[A-Z0-9_]+$"
                  },
                  {
                    "name": "errorMessage",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>More detailed description of the error, which may include information from the request.</p>",
                    "example": "paymentDetails.startDate must be future date",
                    "default": "paymentDetails.startDate must be future date",
                    "pattern": "^.+$"
                  }
                ]
              }
            ],
            "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorResponse",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "401",
        "description": "<p>Unauthorized. The bearer token is missing, invalid or expired. Bearer tokens are valid for 24 hours; generate a new token and retry.</p>",
        "jsonExample": "",
        "isExpanded": true
      },
      {
        "statusCode": "403",
        "description": "Forbidden. Your account is not permitted to perform this operation.",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"traceId\":\"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\"errors\":[{\"errorCode\":\"PAM_FORBIDDEN_ERROR\",\"errorMessage\":\"Not allowed to amend payment schedule for account 6279059778044302\"}]}",
            "description": "Error response returned when a request fails.",
            "customType": "MandateManager.Application.Common.Dtos.ErrorResponse",
            "schema": [
              {
                "name": "traceId",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Unique ID for logging and tracing this request.",
                "example": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "default": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "array",
                "nullable": true,
                "description": "List of errors that occurred while processing the request.",
                "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorDto",
                "customType": "MandateManager.Application.Common.Dtos.ErrorDto[]",
                "schema": [
                  {
                    "name": "errorCode",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>Monoova error code. See <a href=\"https://developer.monoova.com/payto-status-and-error-codes\" target=\"_blank\">PayTo Status and Error Codes</a> for the meaning of each code.</p>",
                    "example": "PAM_STARTDATE_EARLY",
                    "default": "PAM_STARTDATE_EARLY",
                    "pattern": "^[A-Z]{3}_[A-Z0-9_]+$"
                  },
                  {
                    "name": "errorMessage",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>More detailed description of the error, which may include information from the request.</p>",
                    "example": "paymentDetails.startDate must be future date",
                    "default": "paymentDetails.startDate must be future date",
                    "pattern": "^.+$"
                  }
                ]
              }
            ],
            "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorResponse",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "404",
        "description": "Not Found. The payment schedule could not be found.",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"traceId\":\"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\"errors\":[{\"errorCode\":\"PAM_SCHED_NOT_FOUND_ERROR\",\"errorMessage\":\"PaymentSchedule not found for ScheduleId MONSCH12345\"}]}",
            "description": "Error response returned when a request fails.",
            "customType": "MandateManager.Application.Common.Dtos.ErrorResponse",
            "schema": [
              {
                "name": "traceId",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Unique ID for logging and tracing this request.",
                "example": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "default": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "array",
                "nullable": true,
                "description": "List of errors that occurred while processing the request.",
                "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorDto",
                "customType": "MandateManager.Application.Common.Dtos.ErrorDto[]",
                "schema": [
                  {
                    "name": "errorCode",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>Monoova error code. See <a href=\"https://developer.monoova.com/payto-status-and-error-codes\" target=\"_blank\">PayTo Status and Error Codes</a> for the meaning of each code.</p>",
                    "example": "PAM_STARTDATE_EARLY",
                    "default": "PAM_STARTDATE_EARLY",
                    "pattern": "^[A-Z]{3}_[A-Z0-9_]+$"
                  },
                  {
                    "name": "errorMessage",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>More detailed description of the error, which may include information from the request.</p>",
                    "example": "paymentDetails.startDate must be future date",
                    "default": "paymentDetails.startDate must be future date",
                    "pattern": "^.+$"
                  }
                ]
              }
            ],
            "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorResponse",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "500",
        "description": "Internal Server Error. An unexpected error occurred. Contact Monoova support if the problem persists.",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"traceId\":\"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\"errors\":[{\"errorCode\":\"PAM_UNEXPECTED_ERROR\",\"errorMessage\":\"Internal server error. Please contact Monoova support.\"}]}",
            "description": "Error response returned when a request fails.",
            "customType": "MandateManager.Application.Common.Dtos.ErrorResponse",
            "schema": [
              {
                "name": "traceId",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Unique ID for logging and tracing this request.",
                "example": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "default": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "array",
                "nullable": true,
                "description": "List of errors that occurred while processing the request.",
                "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorDto",
                "customType": "MandateManager.Application.Common.Dtos.ErrorDto[]",
                "schema": [
                  {
                    "name": "errorCode",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>Monoova error code. See <a href=\"https://developer.monoova.com/payto-status-and-error-codes\" target=\"_blank\">PayTo Status and Error Codes</a> for the meaning of each code.</p>",
                    "example": "PAM_STARTDATE_EARLY",
                    "default": "PAM_STARTDATE_EARLY",
                    "pattern": "^[A-Z]{3}_[A-Z0-9_]+$"
                  },
                  {
                    "name": "errorMessage",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>More detailed description of the error, which may include information from the request.</p>",
                    "example": "paymentDetails.startDate must be future date",
                    "default": "paymentDetails.startDate must be future date",
                    "pattern": "^.+$"
                  }
                ]
              }
            ],
            "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorResponse",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "502",
        "description": "<p>Bad Gateway. An upstream service, such as the NPP gateway, returned an error. Retry the request later.</p>",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"traceId\":\"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\"errors\":[{\"errorCode\":\"PAM_SCHEDULER_ERROR\",\"errorMessage\":\"Error returned from scheduler service - service unavailable\"}]}",
            "description": "Error response returned when a request fails.",
            "customType": "MandateManager.Application.Common.Dtos.ErrorResponse",
            "schema": [
              {
                "name": "traceId",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Unique ID for logging and tracing this request.",
                "example": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "default": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "array",
                "nullable": true,
                "description": "List of errors that occurred while processing the request.",
                "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorDto",
                "customType": "MandateManager.Application.Common.Dtos.ErrorDto[]",
                "schema": [
                  {
                    "name": "errorCode",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>Monoova error code. See <a href=\"https://developer.monoova.com/payto-status-and-error-codes\" target=\"_blank\">PayTo Status and Error Codes</a> for the meaning of each code.</p>",
                    "example": "PAM_STARTDATE_EARLY",
                    "default": "PAM_STARTDATE_EARLY",
                    "pattern": "^[A-Z]{3}_[A-Z0-9_]+$"
                  },
                  {
                    "name": "errorMessage",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>More detailed description of the error, which may include information from the request.</p>",
                    "example": "paymentDetails.startDate must be future date",
                    "default": "paymentDetails.startDate must be future date",
                    "pattern": "^.+$"
                  }
                ]
              }
            ],
            "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorResponse",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "503",
        "description": "Service Unavailable. The service is temporarily unavailable. Retry the request later.",
        "jsonExample": "",
        "isExpanded": true
      },
      {
        "statusCode": "504",
        "description": "<p>Gateway Timeout. An upstream service, such as the NPP gateway, did not respond in time. Retry the request later.</p>",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"traceId\":\"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\"errors\":[{\"errorCode\":\"PAM_SCHEDULER_TIMEOUT\",\"errorMessage\":\"Timeout from scheduler service\"}]}",
            "description": "Error response returned when a request fails.",
            "customType": "MandateManager.Application.Common.Dtos.ErrorResponse",
            "schema": [
              {
                "name": "traceId",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Unique ID for logging and tracing this request.",
                "example": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "default": "4ea61012-2d9b-413d-a5b4-90ad69a68741",
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "array",
                "nullable": true,
                "description": "List of errors that occurred while processing the request.",
                "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorDto",
                "customType": "MandateManager.Application.Common.Dtos.ErrorDto[]",
                "schema": [
                  {
                    "name": "errorCode",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>Monoova error code. See <a href=\"https://developer.monoova.com/payto-status-and-error-codes\" target=\"_blank\">PayTo Status and Error Codes</a> for the meaning of each code.</p>",
                    "example": "PAM_STARTDATE_EARLY",
                    "default": "PAM_STARTDATE_EARLY",
                    "pattern": "^[A-Z]{3}_[A-Z0-9_]+$"
                  },
                  {
                    "name": "errorMessage",
                    "kind": "optional",
                    "type": "string",
                    "nullable": true,
                    "description": "<p>More detailed description of the error, which may include information from the request.</p>",
                    "example": "paymentDetails.startDate must be future date",
                    "default": "paymentDetails.startDate must be future date",
                    "pattern": "^.+$"
                  }
                ]
              }
            ],
            "modelRef": "#/components/schemas/MandateManager.Application.Common.Dtos.ErrorResponse",
            "isExpanded": true
          }
        ]
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "example-0-curl",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request PUT \\\n     --url https://api-beta.monoova.com/au/payto/pam-v1/PaymentSchedule/{scheduleId} \\\n     --header 'accept: application/json' \\\n     --header 'content-type: application/json' \\\n     --data '{\n     \"startDate\": \"2027-01-15\",\n     \"endDate\": \"2027-12-15\",\n     \"frequency\": \"MNTH\",\n     \"scheduledAmount\": 50,\n     \"totalInstances\": 12,\n     \"totalAmount\": 600,\n     \"paymentReference\": \"ABC Corp monthly subscription\"\n     }'"
        },
        {
          "id": "example-1-javascript",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\n\nvar raw = JSON.stringify({\n   \"startDate\": \"2027-01-15\",\n   \"endDate\": \"2027-12-15\",\n   \"frequency\": \"MNTH\",\n   \"scheduledAmount\": 50,\n   \"totalInstances\": 12,\n   \"totalAmount\": 600,\n   \"paymentReference\": \"ABC Corp monthly subscription\"\n});\n\nvar requestOptions = {\n   method: 'PUT',\n   headers: myHeaders,\n   body: raw,\n   redirect: 'follow'\n};\n\nfetch(\"https://api-beta.monoova.com/au/payto/pam-v1/PaymentSchedule/{scheduleId}\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "example-2-ruby",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"https://api-beta.monoova.com/au/payto/pam-v1/PaymentSchedule/{scheduleId}\")\n\nhttps = Net::HTTP.new(url.host, url.port)\nhttps.use_ssl = true\n\nrequest = Net::HTTP::Put.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\nrequest.body = JSON.dump({\n   \"startDate\": \"2027-01-15\",\n   \"endDate\": \"2027-12-15\",\n   \"frequency\": \"MNTH\",\n   \"scheduledAmount\": 50,\n   \"totalInstances\": 12,\n   \"totalAmount\": 600,\n   \"paymentReference\": \"ABC Corp monthly subscription\"\n})\n\nresponse = https.request(request)\nputs response.read_body\n"
        },
        {
          "id": "example-3-python",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"https://api-beta.monoova.com/au/payto/pam-v1/PaymentSchedule/{scheduleId}\"\n\npayload = json.dumps({\n   \"startDate\": \"2027-01-15\",\n   \"endDate\": \"2027-12-15\",\n   \"frequency\": \"MNTH\",\n   \"scheduledAmount\": 50,\n   \"totalInstances\": 12,\n   \"totalAmount\": 600,\n   \"paymentReference\": \"ABC Corp monthly subscription\"\n})\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"PUT\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "example-0-curl"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-200",
          "language": "200",
          "code": "// OK. The payment schedule was amended.\n{\n  \"traceId\": \"1dabfaa9-abe8-4d2d-a69a-b723079d84ed\",\n  \"scheduleId\": \"MONSCH12345\"\n}"
        },
        {
          "id": "response-1-400",
          "language": "400",
          "code": "// Bad Request. The request failed validation. See errors for details.\n{\n  \"traceId\": \"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\n  \"errors\": [\n    {\n      \"errorCode\": \"PAM_STARTDATE_EARLY\",\n      \"errorMessage\": \"paymentDetails.startDate must be future date\"\n    }\n  ]\n}"
        },
        {
          "id": "response-2-401",
          "language": "401",
          "code": "// Unauthorized. The bearer token is missing, invalid or expired. Bearer tokens are valid for 24 hours; generate a new token and retry.\n"
        },
        {
          "id": "response-3-403",
          "language": "403",
          "code": "// Forbidden. Your account is not permitted to perform this operation.\n{\n  \"traceId\": \"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\n  \"errors\": [\n    {\n      \"errorCode\": \"PAM_STARTDATE_EARLY\",\n      \"errorMessage\": \"paymentDetails.startDate must be future date\"\n    }\n  ]\n}"
        },
        {
          "id": "response-4-404",
          "language": "404",
          "code": "// Not Found. The payment schedule could not be found.\n{\n  \"traceId\": \"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\n  \"errors\": [\n    {\n      \"errorCode\": \"PAM_STARTDATE_EARLY\",\n      \"errorMessage\": \"paymentDetails.startDate must be future date\"\n    }\n  ]\n}"
        },
        {
          "id": "response-5-500",
          "language": "500",
          "code": "// Internal Server Error. An unexpected error occurred. Contact Monoova support if the problem persists.\n{\n  \"traceId\": \"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\n  \"errors\": [\n    {\n      \"errorCode\": \"PAM_STARTDATE_EARLY\",\n      \"errorMessage\": \"paymentDetails.startDate must be future date\"\n    }\n  ]\n}"
        },
        {
          "id": "response-6-502",
          "language": "502",
          "code": "// Bad Gateway. An upstream service, such as the NPP gateway, returned an error. Retry the request later.\n{\n  \"traceId\": \"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\n  \"errors\": [\n    {\n      \"errorCode\": \"PAM_STARTDATE_EARLY\",\n      \"errorMessage\": \"paymentDetails.startDate must be future date\"\n    }\n  ]\n}"
        },
        {
          "id": "response-7-503",
          "language": "503",
          "code": "// Service Unavailable. The service is temporarily unavailable. Retry the request later.\n"
        },
        {
          "id": "response-8-504",
          "language": "504",
          "code": "// Gateway Timeout. An upstream service, such as the NPP gateway, did not respond in time. Retry the request later.\n{\n  \"traceId\": \"4ea61012-2d9b-413d-a5b4-90ad69a68741\",\n  \"errors\": [\n    {\n      \"errorCode\": \"PAM_STARTDATE_EARLY\",\n      \"errorMessage\": \"paymentDetails.startDate must be future date\"\n    }\n  ]\n}"
        }
      ],
      "selectedLanguageId": "response-0-200"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}