The HitPay connector lets your AI agent act in each user's HitPay account. Each user signs in to HitPay once, and Scalekit stores and refreshes their tokens, so your agent never handles credentials. It comes with 39 tools.
- Tools
- 39
- What they doRead · write · destructive
- 18 · 14 · 718 read14 write7 destructive
- Users sign in with
- OAuth
- OAuth app
- Your own HitPay app
Setup
Install the SDK
Terminal window npm install @scalekit-sdk/node dotenvTerminal window pip install scalekit-sdk-python python-dotenvSet your credentials
Add your Scalekit credentials to your
.envfile. Find values in app.scalekit.com > Developers > API Credentials..env SCALEKIT_ENVIRONMENT_URL=<your-environment-url>SCALEKIT_CLIENT_ID=<your-client-id>SCALEKIT_CLIENT_SECRET=<your-client-secret>Create the HitPay connection
In AgentKit > Connections, create a HitPay connection and copy its redirect URI. The name you give it is the
connection_nameyour code passes. See Configure connections.Register an OAuth app
HitPay connections use your own OAuth app. Register one with HitPay and add the redirect URI you copied.
Then enter the app's Client ID and Client Secret on the HitPay connection.
Authorize a user and make your first call
quickstart.mts import { ScalekitClient } from '@scalekit-sdk/node'import 'dotenv/config'import { createInterface } from 'node:readline/promises'const scalekit = new ScalekitClient(process.env.SCALEKIT_ENVIRONMENT_URL,process.env.SCALEKIT_CLIENT_ID,process.env.SCALEKIT_CLIENT_SECRET,)const actions = scalekit.actionsconst connector = 'hitpay'const identifier = 'user_123'// Generate an authorization link for the userconst { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })console.log('Authorize HitPay:', link)const rl = createInterface({ input: process.stdin, output: process.stdout })await rl.question('Press Enter after authorizing...')rl.close()// Make your first callconst result = await actions.executeTool({connector,identifier,toolName: 'hitpay_get_business_info',toolInput: {},})console.log(result)Terminal window npx tsx quickstart.mtsquickstart.py import osfrom scalekit import ScalekitClientfrom dotenv import load_dotenvload_dotenv()scalekit_client = ScalekitClient(env_url=os.getenv("SCALEKIT_ENVIRONMENT_URL"),client_id=os.getenv("SCALEKIT_CLIENT_ID"),client_secret=os.getenv("SCALEKIT_CLIENT_SECRET"),)actions = scalekit_client.actionsconnection_name = "hitpay"identifier = "user_123"# Generate an authorization link for the userlink_response = actions.get_authorization_link(connection_name=connection_name,identifier=identifier,)print("Authorize HitPay:", link_response.link)input("Press Enter after authorizing...")# Make your first callresult = actions.execute_tool(tool_input={},tool_name="hitpay_get_business_info",connection_name=connection_name,identifier=identifier,)print(result)Terminal window python quickstart.pyEach user signs in once. See Authorize a user for the full flow and statuses.
Tools
Pass the exact name toexecute_toolhitpay_get_business_infoFetch the profile of the HitPay business the connected account belongs to.Read-onlyGet Business Info
Fetch the profile of the HitPay business the connected account belongs to. Returns the business name, country, currency, and whether payments are enabled. Use this first to confirm which merchant is connected. Use list_charges for transaction data.
Inputs
This tool takes no inputs.
hitpay_get_chargeFetch one charge (a received payment) by id.Read-onlyGet Charge
Fetch one charge (a received payment) by id. Returns amount, fees, refunded amount, status, currency, payment method, and customer details. Use this before create_refund to confirm the payment id and refundable amount. Use list_charges to find the id.
Inputs
charge_idstringrequired- ID of the charge (payment). Get it from list_charges.
hitpay_get_customerFetch one saved customer by id.Read-onlyGet Customer
Fetch one saved customer by id. Returns name, email, phone number, address, gender, birth date, and remark. Use this to view a customer in full. Use list_customers to find the id.
Inputs
customer_idstringrequired- ID of the customer. Get it from list_customers or create_customer.
hitpay_get_orderFetch one order by id.Read-onlyGet Order
Fetch one order by id. Returns status, currency, customer, line items, charges, and discount and tax totals. Use this to view an order in full. Use list_orders to find the id.
Inputs
order_idstringrequired- ID of the order. Get it from list_orders or create_order.
hitpay_get_payment_requestFetch one payment request and its current status by id.Read-onlyGet Payment Request
Fetch one payment request and its current status by id. Returns id, status (pending, completed, failed, expired, canceled, or inactive), amount, currency, purpose, reference number, and checkout url. Use this to check whether a customer has paid. Use list_payment_requests to find the id.
Inputs
request_idstringrequired- ID of the payment request. Get it from create_payment_request or list_payment_requests.
hitpay_get_productFetch one product by id.Read-onlyGet Product
Fetch one product by id. Returns name, description, price, currency, status, categories, and variations. Use this to view a product in full. Use list_products to find the id.
Inputs
product_idstringrequired- ID of the product. Get it from list_products.
hitpay_get_recurring_billingFetch one recurring billing subscription by id.Read-onlyGet Recurring Billing
Fetch one recurring billing subscription by id. Returns customer, plan id, amount, cycle, times charged, status, and payment methods. Use this to view a subscription in full. Use list_recurring_billings to find the id.
Inputs
recurring_billing_idstringrequired- ID of the recurring billing record. Get it from list_recurring_billings or create_recurring_billing.
hitpay_get_refundFetch one refund by id.Read-onlyGet Refund
Fetch one refund by id. Returns refund id, payment id, amount refunded, total amount, currency, status, and timestamps. Use this to check refund progress. Use create_refund to issue a new refund.
Inputs
refund_idstringrequired- ID of the refund. Get it from create_refund.
hitpay_get_subscription_planFetch one subscription plan by id.Read-onlyGet Subscription Plan
Fetch one subscription plan by id. Returns name, description, cycle, currency, amount, and reference. Use this to view a plan in full. Use list_subscription_plans to find the id.
Inputs
plan_idstringrequired- ID of the subscription plan. Get it from list_subscription_plans or create_subscription_plan.
hitpay_list_chargesList payments (charges) received by the business, filtered by status, date range, amount, customer, or payment request.Read-onlyList Charges
List payments (charges) received by the business, filtered by status, date range, amount, customer, or payment request. Returns a page of charges with id, amount, currency, fees, status, payment method, and a cursor for the next page. Use this to review transactions. Use get_charge for one charge in full.
Inputs
amount_fromnumber- Return charges with an amount at or above this value. Example: 10.
amount_tonumber- Return charges with an amount at or below this value. Example: 500.
cursorstring- Cursor for the next page. Pass the meta.next_cursor value from the previous response. Leave empty for the first page. Example: eyJpZCI6MTIzfQ.
customer_idstring- Return only charges made by this customer. Get the id from list_customers. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
date_fromstring- Return charges created on or after this date, in YYYY-MM-DD format. Example: 2026-01-01.
date_tostring- Return charges created on or before this date, in YYYY-MM-DD format. Example: 2026-01-31.
keywordsstring- Search for fields: amount ,charge_id ,customer_email, remark. Example: coffee.
payment_request_idstring- Return only charges paid against this payment request. Get the id from list_payment_requests. Example: 974ee233-bc3e-4aac-a212-15af0d155133.
payout_idstring- Return only charges included in this payout. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
per_pageinteger- Number of results per page. Example: 20.
statusstring- Filter charges by status: succeeded, failed, or refunded. Leave empty for all statuses. Example: succeeded.one of
succeededfailedrefunded
hitpay_list_customersList the business's saved customers.Read-onlyList Customers
List the business's saved customers. Returns a page of customers with id, name, email, phone number, address, and timestamps. Use this to find a customer id. Use get_customer for one customer.
Inputs
pagenumber- Page number to return, starting at 1. Example: 1.
per_pagenumber- Number of results per page. Example: 20.
hitpay_list_invoicesList the business's invoices, optionally filtered by customer email, status, or reference.Read-onlyList Invoices
List the business's invoices, optionally filtered by customer email, status, or reference. Returns a page of invoices (the vendor reference documents no response body for this call). Use this to find an invoice id for update_invoice or delete_invoice.
Inputs
customer_emailstring- Return only invoices for this customer email. Example: jane@example.com.
pagestring- The page index. Example: 1.
per_pagestring- The number of per page. Example: 20.
referencestring- Return only invoices with this reference. Example: ORDER-1001.
statusstring- Filter invoices by status. Example: paid.
hitpay_list_ordersList the business's orders, optionally filtered by keyword or date range.Read-onlyList Orders
List the business's orders, optionally filtered by keyword or date range. Returns orders with id, display number, status, currency, line items, and totals. Use this to browse orders. Use get_order for one order.
Inputs
dateFromstring- Return orders created on or after this date, in YYYY-MM-DD format. Example: 2026-01-01.
dateTostring- Return orders created on or before this date, in YYYY-MM-DD format. Example: 2026-01-31.
keywordsstring- Search for fields: amount ,created_at ,order id, remark, customer_name. Example: coffee.
perPageinteger- Number of results per page. Example: 20.
versionstring- Order format version to return, 1.0 or 2.0. Example: 2.0.one of
1.02.0 withstring- Related data to include with each order. Example: products.
hitpay_list_payment_requestsList the business's payment requests, optionally searching by email, id, or reference number.Read-onlyList Payment Requests
List the business's payment requests, optionally searching by email, id, or reference number. Returns a page of payment requests with id, status, amount, currency, and checkout url. Use this to browse or look up requests. Use get_payment_request when you already have the id.
Inputs
current_pageinteger- Page number to return, starting at 1. The HitPay API uses current_page here, not page. Example: 1.
is_defaultboolean- When true, return only default payment links (created from the dashboard or a payment link). Leave empty for all payment requests.
per_pageinteger- Number of payment requests per page. Example: 20.
searchstring- Search by buyer email, payment request id, or reference number (partial match). Example: jane@example.com.
hitpay_list_product_categoriesList product categories, optionally filtered by parent, active state, or keyword.Read-onlyList Product Categories
List product categories, optionally filtered by parent, active state, or keyword. Returns a page of categories with id, name, description, active flag, and child categories. Use this to find category ids that appear on products.
Inputs
activeboolean- Set to true to return only active categories, or false for inactive ones. Example: true.
keywordsstring- Filter by keywords, name. Example: coffee.
pageinteger- Page number to return, starting at 1. Example: 1.
parent_idstring- Return only child categories of this parent category id. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
perPageinteger- Number of results per page. Example: 20.
hitpay_list_productsList products in the business's HitPay catalog, optionally searching by keyword.Read-onlyList Products
List products in the business's HitPay catalog, optionally searching by keyword. Returns a page of products with id, name, price, currency, status, and category ids. Use this to find a product id for an invoice. Use get_product for one product.
Inputs
keywordsarray- Free-text search term. Example: coffee.
pagenumber- Page number to return, starting at 1. Example: 1.
per_pagenumber- Number of results per page. Example: 20.
hitpay_list_recurring_billingsList recurring billing subscriptions, optionally filtered by customer email, reference, plan, or status.Read-onlyList Recurring Billings
List recurring billing subscriptions, optionally filtered by customer email, reference, plan, or status. Returns recurring billing records with id, customer, plan, amount, cycle, and status (the vendor reference documents no response body for this call). Use this to find a recurring billing id. Use get_recurring_billing for one record.
Inputs
business_recurring_plans_idstring- Return only subscriptions on this subscription plan. Get the id from list_subscription_plans. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
customer_emailstring- Return only subscriptions for this customer email. Example: jane@example.com.
referencestring- Return only subscriptions with this reference. Example: ORDER-1001.
statusstring- Filter by status: active, scheduled, retrying, inactive, or canceled. Example: active.one of
activescheduledretryinginactivecanceled
hitpay_list_subscription_plansList recurring billing subscription plans.Read-onlyList Subscription Plans
List recurring billing subscription plans. Returns a page of plans with id, name, cycle, currency, and amount. Use this to find a plan id for create_recurring_billing. Use get_subscription_plan for one plan.
Inputs
pagenumber- Page number to return, starting at 1. Example: 1.
per_pagenumber- Number of plans per page. Example: 20.
hitpay_charge_saved_cardCharge the card or payment method saved on a recurring billing record for a given amount.WriteCharge Saved Card
Charge the card or payment method saved on a recurring billing record for a given amount. Returns the payment id, recurring billing id, amount, currency, and status. Use this for on-demand charges against a saved payment method. The record must have been created with save_card enabled.
Inputs
amountintegerrequired- Amount to bill, as a whole number, in the plan or record currency. Maximum 999999.99. Example: 25.
currencystringrequired- The currency. Example: SGD.
recurring_billing_idstringrequired- ID of the recurring billing record. Get it from list_recurring_billings or create_recurring_billing.
hitpay_create_customerCreate a saved customer in the business's HitPay account.WriteCreate Customer
Create a saved customer in the business's HitPay account. Returns the new customer with its id. Use this before creating an invoice or order for a new customer. Use update_customer to edit an existing one.
Inputs
emailstringrequired- The email of the customer. Example: jane@example.com.
phone_numberstringrequired- The phone number of the customer. Example: 91234567.
addressobject- Postal address as an object. Example: {"line1": "1 Raffles Place", "city": "Singapore", "state": "Singapore", "country": "SG", "postal_code": "048616"}. Required keys inside the object are line1, city, state, country, and postal_code for payment requests; customers use street, city, state, and postal_code.
birth_datestring- The birth date of the customer. Example: 1990-05-21.
genderstring- The gender of the customer. Example: female.
namestring- The name of the customer. Example: Jane Tan.
phone_number_country_codestring- The country code of the phone number. Example: 65.
remarkstring- The remark of the customer. Example: Gift wrap requested.
hitpay_create_invoiceCreate an invoice for a customer, optionally with products, discounts, and partial payments.WriteCreate Invoice
Create an invoice for a customer, optionally with products, discounts, and partial payments. Returns the created invoice (the vendor reference documents no response body for this call). Use this to bill a customer for products or a fixed amount. Use create_payment_request for a one-off payment link.
Inputs
currencystringrequired- Three-letter currency code for the invoice. Example: SGD.
invoice_datestringrequired- Date the invoice is issued, in YYYY-MM-DD format. Example: 2026-01-15.
payment_bystringrequired- Whether the invoice is billed by product (send products) or by amount (send amount and subtotal). Example: product.
allow_partial_paymentsstring- Set to 1 to let the customer pay the invoice in instalments (also set partial_payments), or 0 for a single payment. Example: 0.
amountnumber- Invoice total amount in the invoice currency. Only needed when payment_by is amount. Example: 90.00.
auto_invoice_numberstring- Set to true to have HitPay assign the invoice number automatically instead of sending invoice_number. Example: true.
customerobject- New customer details for the invoice as an object with name, email, and an optional address. Use customer_id instead for a saved customer. Example: {"name": "Jane Tan", "email": "jane@example.com"}.
customer_idstring- ID of a saved customer to bill. Get it from list_customers. Use customer instead to enter new customer details. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
due_datestring- Date the invoice is due, in YYYY-MM-DD format. Example: 2026-02-15.
footerstring- Text shown at the bottom of the invoice. Example: Thank you for your business.
invoice_numberstring- Your own invoice number. Leave empty when auto_invoice_number is set. Example: INV-0001.
partial_paymentsarray- Instalment schedule as an array of objects, each with an amount and a due_date. Use with allow_partial_payments. Example: [{"amount": 50, "due_date": "2026-02-01"}, {"amount": 50, "due_date": "2026-03-01"}].
payment_methodsarray- Payment methods the customer may use, as an array of method codes available on your HitPay account and currency. Example: ["card", "paynow_online"].
productsarray- Line items as an array of objects, each with a product_id and optional quantity, variation_id, and discount. Get product ids from list_products. Example: [{"product_id": "9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d", "quantity": "2"}].
recipientsarray- People who receive the invoice, as an array of objects with an email or a customer_id. Example: [{"email": "jane@example.com"}].
referencestring- Your own reference for the invoice, used to match it to your internal systems. Example: ORDER-1001.
send_emailinteger- Set to 1 to have HitPay email receipts to the customer, or 0 for no email. HitPay defaults to 0. Example: 1.
stackable_discountsarray- Discounts applied in sequence, as an array of objects, each with a name, a discount amount, a percentage_discount, and an order. Example: [{"name": "Early bird", "discount": "5", "percentage_discount": "0", "order": "1"}].
subtotalnumber- Subtotal before discounts and tax. Needed when payment_by is amount. Example: 90.00.
tax_settingstring- ID of the tax to apply to the invoice, taken from the tax settings in the HitPay dashboard. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
webhookstring- URL HitPay calls with a POST when the invoice is paid. Example: https://yourshop.example.com/hitpay/webhook.
hitpay_create_orderCreate an order for the business.WriteCreate Order
Create an order for the business. Returns the new order with its id, status, and totals. Use this to record a sale. Use update_order to change an existing order.
Inputs
amountnumberrequired- Total amount of the order in the order currency. Example: 25.00.
currencystringrequired- Three-letter currency code of the order. HitPay defaults to SGD. Example: SGD.
business_user_idstring- ID of the staff user who took the order. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
channelstring- Sales channel of the order. HitPay defaults to point_of_sale. Example: point_of_sale.
customer_idstring- ID of the saved customer who placed the order. Get it from list_customers. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
customer_pickupboolean- Whether the customer collects the order in person (true) or not (false). HitPay defaults to true. Example: true.
discount_amountnumber- Discount amount deducted from the order. Example: 5.00.
discount_reasonstring- Why a discount was applied to the order. Example: Loyalty discount.
location_idstring- ID of the business location the order belongs to. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
remarkstring- Free-text note stored on the order. Example: Gift wrap requested.
versionstring- Order format version, 1.0 or 2.0. HitPay defaults to 1.0. Example: 1.0.
hitpay_create_payment_requestCreate a HitPay payment request and get back a hosted checkout link to send to a customer.WriteCreate Payment Request
Create a HitPay payment request and get back a hosted checkout link to send to a customer. Returns the payment request id, status, amount, currency, and the checkout url. Use this to start collecting a payment. Use update_payment_request to change an unpaid request and get_payment_request to check its status.
Inputs
currencystringrequired- It's required field. Currency related to the payment. Example: SGD.
add_admin_feestring- If set to true, the admin fee will be included in total.one of
truefalse addressobject- Postal address as an object. Example: {"line1": "1 Raffles Place", "city": "Singapore", "state": "Singapore", "country": "SG", "postal_code": "048616"}. Required keys inside the object are line1, city, state, country, and postal_code for payment requests; customers use street, city, state, and postal_code.
allow_repeated_paymentsstring- If set to true, multiple payments can be paid on a payment request link. Default value is false.one of
truefalse amountnumber- It's optional field. Amount related to the payment. Example: 2500. If we pass, it should be greater than 0.3 and less than 999999999.99.
business_location_idstring- The active location belongs to business. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
emailstring- Buyer’s email. Example: jane@example.com.
expires_afterstring- E.g "30 mins" Other supported keys are "mins", "hours", "days". Example: 30 mins.
expiry_datestring- Time after which the payment link will be expired (time in SG with YYYY-MM-DD HH:mm:ss format). Applicable for repeated payments. Example: 2026-12-31 23:59:59.
generate_qrboolean- Only valid for paynow_online, qrph_netbank, doku_qris and shopee_pay if generate_qr was true.
location_idstring- The active location belongs to business. Support both `location_id` and `business_location_id` for backward compatibility, but we recommend using `business_location_id` for future use. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
metadataobject- Support the key-value. The value must be string type, and the max length of the value is 500 characters, up to 50 key-value. Example: {"car_model": "toyota", "car_color": "red"}.
namestring- Buyer’s name. Example: Jane Tan.
payment_methodsarray- They're available payment methods supported on your account.(Example: paynow_online , card, wechat, alipay, grabpay_direct, grabpay_paylater, shopee_pay ... etc.). If we don't pass, use the available methods.
phonestring- Buyer’s phone number and should be in E.164 format. Example: +6591234567.
purposestring- Purpose of the Payment request. Example: Order 123.
redirect_urlstring- URL where we redirect the user after a payment. Query arguments reference (payment request id) and status are sent along. Example: https://yourshop.example.com/order/123/complete.
reference_numberstring- Arbitrary reference number that you can map to your internal reference number. This value cannot be edited by the customer. Example: ORDER-1001.
send_emailstring- It's "true" or "false". If set to true, an email receipt will be sent to the customer after the payment is completed. Default is false.one of
truefalse send_smsstring- It's "true" or "false". If set to "true", SMS will be sent to the customer after the payment is completed. Default is false.one of
truefalse staff_idstring- It's active staff id from the dashboard. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
webhookstring- URL where our server do POST request after a payment If done. Example: https://yourshop.example.com/hitpay/webhook.
hitpay_create_recurring_billingCreate a recurring billing subscription for a customer, from a plan or with custom amount and cycle.WriteCreate Recurring Billing
Create a recurring billing subscription for a customer, from a plan or with custom amount and cycle. Returns the created recurring billing record (the vendor reference documents no response body for this call). Use this to subscribe a customer. Use create_subscription_plan first to define a reusable plan.
Inputs
customer_emailstringrequired- Customer's email. Example: jane@example.com.
amountinteger- Amount to bill, as a whole number, in the plan or record currency. Maximum 999999.99. Example: 25.
customer_namestring- Customer's name. Example: Jane Tan.
cyclestring- Billing frequency: weekly, monthly, yearly, or custom. Required when plan_id is empty; otherwise the plan cycle is used. Example: monthly.one of
weeklymonthlyyearlycustom cycle_frequencystring- It is required field when the cycle is custom. For cycle = custom, set the frequency for cycle repeat field options [day, week, month, year].one of
dayweekmonthyear cycle_repeatinteger- It is required field when cycle is custom. New cycle will only be affective at the end of the current cycle.
namestring- Name of the subscription. Required when save_card is true or plan_id is empty; otherwise the plan name is used. Example: Premium membership.
payment_methodsarray- Payment methods allowed for the subscription, as an array containing card, giro, or shopee_recurring. Example: ["card"].
plan_idstring- Subscription plan id created from Create a Subscription Plan API. If you would like to create a subscription without a plan, plan_id should be null. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
redirect_urlstring- URL where HitPay redirects the user after the users enters the card details and the subscription is active. Query arguments reference (subscription id) and status are sent along. Example: https://yourshop.example.com/order/123/complete.
referencestring- Your own reference for this record, used to match it to your internal systems. Example: ORDER-1001.
save_cardstring- Only set the value “true” if you wish to save the card and charge the customer later on. More details in “Save Card” section.one of
truefalse save_payment_methodstring- It's new field that will replace save_card field in the future. Only set the value “true” if you wish to save the payment method and charge the customer later on. More details in “Save Payment Method” section.one of
truefalse send_emailstring- HitPay to send email receipts to the customer. Default value is false.one of
truefalse start_datestring- Required when save_card is not true. Billing start date (YYYY-MM-DD) in SGT. Must be today or a future date. Example: 2026-02-01.
start_date_methodstring- It's an optional field and only applicable when save_payment_method is true. By default, the start_date_method is null. Options are sign_up_date or no_initial_charge.one of
sign_up_dateno_initial_charge times_to_be_chargednumber- It's time to be charged. Default value is 1.
hitpay_create_refundRefund all or part of a completed charge.WriteCreate Refund
Refund all or part of a completed charge. Returns the refund id, payment id, amount refunded, currency, and status. Use this to return money to a customer. Use get_refund to check an existing refund.
Inputs
amountnumberrequired- The remaining amount to be refunded.
payment_idstringrequired- Payment ID for the successful payment request. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
emailstring- Email address of the person. Example: jane@example.com.
send_emailstring- Whether to email the customer. Use true or false as the HitPay API expects. Example: true.one of
truefalse webhookstring- The webhook URL. Example: https://yourshop.example.com/hitpay/webhook.
hitpay_create_subscription_planCreate a reusable recurring billing plan with a name, amount, and billing cycle.WriteCreate Subscription Plan
Create a reusable recurring billing plan with a name, amount, and billing cycle. Returns the new plan with its id. Use this to define a plan before subscribing customers with create_recurring_billing.
Inputs
amountintegerrequired- Amount to bill, as a whole number, in the plan or record currency. Maximum 999999.99. Example: 25.
cyclestringrequired- Billing frequency (weekly / monthly / yearly / custom). If cycle = custom then the user has to send the fields cycle_repeat and cycle_frequency.one of
weeklymonthlyyearlycustom namestringrequired- Plan name. It's required field. Example: Premium membership.
currencystring- Three-letter currency code for the amount. Example: SGD.
cycle_frequencystring- [This field is only applicable when cycle = custom] It's the frequency of the cycle [day / week / month / year].one of
dayweekmonthyear cycle_repeatinteger- [This field is only applicable when cycle = custom] It's the number of times the cycle will repeat.
descriptionstring- The description of subscription plan. Example: Monthly premium membership.
fixed_datenumber- it's required if start_date_method = fixed_date.
redirect_urlstring- The redirected URL after the payment. Example: https://yourshop.example.com/order/123/complete.
referencestring- Arbitrary reference number that you can map to your internal reference number. This value cannot be edited by the customer. Example: ORDER-1001.
start_date_methodstring- How the billing start date is chosen. Valid values depend on the endpoint; see the allowed options. Example: sign_up_date.one of
sign_up_datecustomer_select_datefixed_date times_to_be_chargednumber- How many times the customer is charged before the subscription ends. Leave empty to charge until cancelled. Example: 12.
hitpay_update_customerUpdate fields on a saved customer.WriteUpdate Customer
Update fields on a saved customer. Only the fields you send are changed. Returns the updated customer. Use this to correct contact details. Use create_customer for a new customer.
Inputs
customer_idstringrequired- ID of the customer. Get it from list_customers or create_customer.
addressobject- Postal address as an object. Example: {"line1": "1 Raffles Place", "city": "Singapore", "state": "Singapore", "country": "SG", "postal_code": "048616"}. Required keys inside the object are line1, city, state, country, and postal_code for payment requests; customers use street, city, state, and postal_code.
birth_datestring- The birth date of the customer. Example: 1990-05-21.
emailstring- The email of the customer. Example: jane@example.com.
genderstring- The gender of the customer. Example: female.
namestring- The name of the customer. Example: Jane Tan.
phone_numberstring- The phone number of the customer. Example: 91234567.
phone_number_country_codestring- The country code of the phone number. Example: 65.
remarkstring- The remark of the customer. Example: Gift wrap requested.
hitpay_update_invoiceReplace the details of an existing invoice.WriteUpdate Invoice
Replace the details of an existing invoice. Returns the updated invoice (the vendor reference documents no response body for this call). Use this to fix an invoice before it is paid. Use create_invoice for a new one.
- Idempotent
Inputs
currencystringrequired- Three-letter currency code for the invoice. Example: SGD.
invoice_datestringrequired- Date the invoice is issued, in YYYY-MM-DD format. Example: 2026-01-15.
invoice_idstringrequired- ID of the invoice. Get it from list_invoices.
payment_bystringrequired- Whether the invoice is billed by product (send products) or by amount (send amount and subtotal). Example: product.
allow_partial_paymentsstring- Set to 1 to let the customer pay the invoice in instalments (also set partial_payments), or 0 for a single payment. Example: 0.
amountnumber- Invoice total amount in the invoice currency. Only needed when payment_by is amount. Example: 90.00.
auto_invoice_numberstring- Set to true to have HitPay assign the invoice number automatically instead of sending invoice_number. Example: true.
customerobject- New customer details for the invoice as an object with name, email, and an optional address. Use customer_id instead for a saved customer. Example: {"name": "Jane Tan", "email": "jane@example.com"}.
customer_idstring- ID of a saved customer to bill. Get it from list_customers. Use customer instead to enter new customer details. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
due_datestring- Date the invoice is due, in YYYY-MM-DD format. Example: 2026-02-15.
footerstring- Text shown at the bottom of the invoice. Example: Thank you for your business.
invoice_numberstring- Your own invoice number. Leave empty when auto_invoice_number is set. Example: INV-0001.
partial_paymentsarray- Instalment schedule as an array of objects, each with an amount and a due_date. Use with allow_partial_payments. Example: [{"amount": 50, "due_date": "2026-02-01"}, {"amount": 50, "due_date": "2026-03-01"}].
payment_methodsarray- Payment methods the customer may use, as an array of method codes available on your HitPay account and currency. Example: ["card", "paynow_online"].
productsarray- Line items as an array of objects, each with a product_id and optional quantity, variation_id, and discount. Get product ids from list_products. Example: [{"product_id": "9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d", "quantity": "2"}].
recipientsarray- People who receive the invoice, as an array of objects with an email or a customer_id. Example: [{"email": "jane@example.com"}].
referencestring- Your own reference for the invoice, used to match it to your internal systems. Example: ORDER-1001.
send_emailinteger- Set to 1 to have HitPay email receipts to the customer, or 0 for no email. HitPay defaults to 0. Example: 1.
stackable_discountsarray- Discounts applied in sequence, as an array of objects, each with a name, a discount amount, a percentage_discount, and an order. Example: [{"name": "Early bird", "discount": "5", "percentage_discount": "0", "order": "1"}].
subtotalnumber- Subtotal before discounts and tax. Needed when payment_by is amount. Example: 90.00.
tax_settingstring- ID of the tax to apply to the invoice, taken from the tax settings in the HitPay dashboard. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
webhookstring- URL HitPay calls with a POST when the invoice is paid. Example: https://yourshop.example.com/hitpay/webhook.
hitpay_update_orderUpdate fields on an existing order.WriteUpdate Order
Update fields on an existing order. Only the fields you send are changed. Returns the updated order. Use this to change an order's amount, customer, or remark. Use create_order for a new order.
Inputs
order_idstringrequired- ID of the order. Get it from list_orders or create_order.
amountnumber- Total amount of the order in the order currency. Example: 25.00.
business_user_idstring- ID of the staff user who took the order. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
channelstring- Sales channel of the order. HitPay defaults to point_of_sale. Example: point_of_sale.
currencystring- Three-letter currency code of the order. HitPay defaults to SGD. Example: SGD.
customer_idstring- ID of the saved customer who placed the order. Get it from list_customers. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
customer_pickupboolean- Whether the customer collects the order in person (true) or not (false). HitPay defaults to true. Example: true.
discount_amountnumber- Discount amount deducted from the order. Example: 5.00.
discount_reasonstring- Why a discount was applied to the order. Example: Loyalty discount.
location_idstring- ID of the business location the order belongs to. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
remarkstring- Free-text note stored on the order. Example: Gift wrap requested.
versionstring- Order format version, 1.0 or 2.0. HitPay defaults to 1.0. Example: 1.0.
hitpay_update_payment_requestUpdate an existing payment request that has not been paid yet.WriteUpdate Payment Request
Update an existing payment request that has not been paid yet. Returns the updated payment request. Use this to change the amount, buyer details, expiry, or payment methods. Use create_payment_request for a new request.
- Idempotent
Inputs
currencystringrequired- Currency related to the payment. Example: SGD.
request_idstringrequired- ID of the payment request. Get it from create_payment_request or list_payment_requests.
add_admin_feestring- If set to true, the admin fee will be included in total.one of
truefalse addressobject- Postal address as an object. Example: {"line1": "1 Raffles Place", "city": "Singapore", "state": "Singapore", "country": "SG", "postal_code": "048616"}. Required keys inside the object are line1, city, state, country, and postal_code for payment requests; customers use street, city, state, and postal_code.
allow_repeated_paymentsstring- If set to true, multiple payments can be paid on a payment request link. Default value is false.one of
truefalse amountnumber- It's required field. Amount related to the payment.
emailstring- Buyer’s email. Example: jane@example.com.
expires_afterstring- E.g "30 mins" Other supported keys are "mins", "hours", "days". Example: 30 mins.
expiry_datestring- Time after which the payment link will be expired(time in SG with YYYY-MM-DD HH:mm:ss format). Applicable for repeated payments. Default is Null. Example: 2026-12-31 23:59:59.
generate_qrboolean- Only valid for payment methods: paynow_online, qrph_netbank, doku_qris and shopee_pay if generate_qr was true.
namestring- Buyer’s name. Example: Jane Tan.
payment_methodsarray- Payment method type (paynow_online , card, wechat, alipay, grabpay_direct, grabpay_paylater, shopee_pay, zip, fpx). If we don't pass, use the available methods.
phonestring- Buyer’s phone number. Example: +6591234567.
purposestring- Purpose of the Payment request. Example: Order 123.
redirect_urlstring- URL where we redirect the user after a payment. Query arguments reference (payment request id) and status are sent along. Example: https://yourshop.example.com/order/123/complete.
reference_numberstring- Arbitrary reference number that you can map to your internal reference number. This value cannot be edited by the customer. Example: ORDER-1001.
send_emailstring- It's "true" or "false". If set to true, an email receipt will be sent to the customer after the payment is completed. Default is false.one of
truefalse send_smsstring- It's "true" or "false". If set to "true", SMS will be sent to the customer after the payment is completed. Default is false.one of
truefalse staff_idstring- It's active staff id from the dashboard. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
webhookstring- URL where our server do POST request after a payment If done. Example: https://yourshop.example.com/hitpay/webhook.
hitpay_update_recurring_billingUpdate a recurring billing subscription's plan, amount, cycle, or customer details.WriteUpdate Recurring Billing
Update a recurring billing subscription's plan, amount, cycle, or customer details. Returns the updated recurring billing record. Use this to change a subscription. Use delete_recurring_billing to cancel it.
- Idempotent
Inputs
recurring_billing_idstringrequired- ID of the recurring billing record. Get it from list_recurring_billings or create_recurring_billing.
amountnumber- New amount to bill each cycle in the record currency. Example: 25.
customer_emailstring- Customer's email. Example: jane@example.com.
customer_namestring- Customer's name. Example: Jane Tan.
cyclestring- Billing frequency (weekly / monthly / yearly / custom).one of
weeklymonthlyyearlycustom cycle_frequencystring- It is required field when the cycle is custom. For cycle = custom, set the frequency for cycle repeat field options [day, week, month, year].one of
dayweekmonthyear cycle_repeatinteger- It is required field when cycle is custom. New cycle will only be affective at the end of the current cycle.
descriptionstring- The description of subscription plan. Example: Monthly premium membership.
namestring- Plan name. Example: Premium membership.
payment_methodsarray- Payment methods allowed for the subscription, as an array containing card, giro, or shopee_recurring. Example: ["card"].
plan_idstring- The plan ID, if plan_id is not null it will update [cycle, cycle_repeat, cycle_frequency and amount] with the values from Subscription plan. if plan_id is null you can update each field individually. When save_card is true, you disallow to set plan_id. Example: 9a1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d.
redirect_urlstring- URL where HitPay redirects the user after the users enters the card details and the subscription is active. Query arguments reference (subscription id) and status are sent along. Example: https://yourshop.example.com/order/123/complete.
referencestring- Arbitrary reference number that you can map to your internal reference number. This value cannot be edited by the customer. Example: ORDER-1001.
save_cardstring- Only set the value “true” if you wish to save the card and charge the customer later on. More details in “Save Card” section.one of
truefalse save_payment_methodstring- It's new field that will replace save_card field in the future. Only set the value “true” if you wish to save the payment method and charge the customer later on. More details in “Save Payment Method” section.one of
truefalse send_emailstring- Whether HitPay emails the customer about this subscription. Use true or false. Example: true.one of
truefalse start_datestring- The start date must be a date after or equal to today and Billing start date (YYYY-MM-DD) in SGT, only possible to change start date for recurring billing ID with status = scheduled or active. Example: 2026-02-01.
start_date_methodstring- It's an optional field and only applicable when save_payment_method is true. By default, the start_date_method is null. Options are sign_up_date or no_initial_charge.one of
sign_up_dateno_initial_charge
hitpay_update_subscription_planUpdate a subscription plan's name, amount, cycle, or other settings.WriteUpdate Subscription Plan
Update a subscription plan's name, amount, cycle, or other settings. Returns the updated plan. Use this to change a plan. Use create_subscription_plan for a new plan.
- Idempotent
Inputs
amountintegerrequired- Amount to bill, as a whole number, in the plan or record currency. Maximum 999999.99. Example: 25.
cyclestringrequired- Billing frequency (weekly / monthly / yearly / custom / save_card). If cycle = custom then the user has to send the fields cycle_repeat and cycle_frequency.one of
weeklymonthlyyearlycustomsave_card namestringrequired- Plan name. It's required field. Example: Premium membership.
plan_idstringrequired- ID of the subscription plan. Get it from list_subscription_plans or create_subscription_plan.
currencystring- Three-letter currency code for the amount. Example: SGD.
cycle_frequencystring- [This field is only applicable when cycle = custom] It's the frequency of the cycle [day / week / month / year].one of
dayweekmonthyear cycle_repeatinteger- [This field is only applicable when cycle = custom] It's the number of times the cycle will repeat.
descriptionstring- The description of subscription plan. Example: Monthly premium membership.
fixed_datenumber- it's required if start_date_method = fixed_date.
redirect_urlstring- The redirected URL after the payment. Example: https://yourshop.example.com/order/123/complete.
referencestring- Arbitrary reference number that you can map to your internal reference number. This value cannot be edited by the customer. Example: ORDER-1001.
start_date_methodstring- How the billing start date is chosen. Valid values depend on the endpoint; see the allowed options. Example: sign_up_date.one of
sign_up_datecustomer_select_datefixed_date times_to_be_chargednumber- How many times the customer is charged before the subscription ends. Leave empty to charge until cancelled. Example: 12.
hitpay_delete_customerDelete a saved customer.DestructiveDelete Customer
Delete a saved customer. Returns only the HTTP status; the response body is empty. Use this to remove a customer permanently. Use update_customer to edit instead.
- Idempotent
Inputs
customer_idstringrequired- ID of the customer. Get it from list_customers or create_customer.
hitpay_delete_invoiceDelete an invoice.DestructiveDelete Invoice
Delete an invoice. Returns only the HTTP status; the response body is empty. Use this to remove an invoice permanently. Use update_invoice to correct it instead.
- Idempotent
Inputs
invoice_idstringrequired- ID of the invoice. Get it from list_invoices.
hitpay_delete_orderDelete an order.DestructiveDelete Order
Delete an order. Returns only the HTTP status; the response body is empty. Use this to remove an order permanently.
- Idempotent
Inputs
order_idstringrequired- ID of the order. Get it from list_orders or create_order.
hitpay_delete_payment_requestDelete a payment request so its checkout link can no longer be paid.DestructiveDelete Payment Request
Delete a payment request so its checkout link can no longer be paid. Returns a success flag. Completed payment requests cannot be deleted. Use this to withdraw an unpaid request. Use update_payment_request to change it instead.
- Idempotent
Inputs
request_idstringrequired- ID of the payment request. Get it from create_payment_request or list_payment_requests.
hitpay_delete_productDelete a product from the catalog.DestructiveDelete Product
Delete a product from the catalog. Returns only the HTTP status; the response body is empty. Use this to remove a product permanently.
- Idempotent
Inputs
product_idstringrequired- ID of the product. Get it from list_products.
hitpay_delete_recurring_billingCancel and delete a recurring billing subscription.DestructiveDelete Recurring Billing
Cancel and delete a recurring billing subscription. Returns the deleted recurring billing record. Use this to stop future charges. Use update_recurring_billing to change it instead.
- Idempotent
Inputs
recurring_billing_idstringrequired- ID of the recurring billing record. Get it from list_recurring_billings or create_recurring_billing.
hitpay_delete_subscription_planDelete a subscription plan.DestructiveDelete Subscription Plan
Delete a subscription plan. Returns only the HTTP status; the response body is empty. Use this to remove a plan permanently.
- Idempotent
Inputs
plan_idstringrequired- ID of the subscription plan. Get it from list_subscription_plans or create_subscription_plan.
No tools match.