### Payment Configuration Example - JSON Source: https://docs.hitpayapp.com/apis/payment-request/update-request An example JSON object demonstrating the structure for configuring a payment transaction. It includes essential fields like amount, currency, customer details, and notification settings. ```json { "amount": 100, "currency": "SGD", "payment_methods": [ "" ], "email": "jsmith@example.com", "name": "", "phone": "", "wifi_terminal_id": "", "staff_id": "98888a24-d6b2-430d-9063-d2be76d443cd", "purpose": "", "reference_number": "", "redirect_url": "https://www.google.com", "webhook": "https://www.google.com", "allow_repeated_payments": "false", "expiry_date": "", "expires_after": "5 minutes", "add_admin_fee": "false", "send_email": "false", "send_sms": "true", "address": { "line1": "", "line2": "", "city": "", "country": "", "state": "", "postal_code": "" }, "generate_qr": false } ``` -------------------------------- ### Order Data Structure Example Source: https://docs.hitpayapp.com/apis/order/get-all-order This example demonstrates the structure of an order object as returned by the API. It includes fields for order identification, customer and business details, pricing information, and status fields for payment and fulfillment. Note that some fields like 'products', 'charges', and 'line_items' are provided as empty arrays in this specific example. ```json { "id": "9b4bc2a2-4721-4636-a6dc-4effec3b00fc", "order_display_number": 5660, "business_id": "9130c422-bf97-4bd1-b370-07a3a6f40708", "channel": "point_of_sale", "version": "1.0", "customer_id": null, "business_customer_id": null, "customer": null, "customer_pickup": true, "currency": "sgd", "order_discount_name": null, "status": "draft", "remark": "Razaq is a fool", "created_at": "2024-02-10T00:41:42+08:00", "updated_at": "2024-02-10T00:41:42+08:00", "closed_at": null, "location_id": null, "location": null, "business_user_id": "34", "slot_date": null, "slot_time": null, "messages": null, "products": [], "charges": [], "line_items": [], "order_form": { "membership_id": { "type": "input", "title": "Membership ID", "deleted": false, "include": true, "required": true } }, "order_form_response": [], "coupon": null, "payment_status": null, "fulfilment_status": "", "line_items_total": 0, "order_discount_amount": 0, "line_item_discount_amount": 0, "line_item_tax_amount": 0, "additional_discount_amount": 0, "total_discount_amount": 0, "line_item_price": 0, "shipping_amount": 0, "total_coupon_amount": 0, "amount": 0, "subtotal": 0 } ``` -------------------------------- ### HitPay API Subscription Plan Response Example Source: https://docs.hitpayapp.com/apis/recurring-billing/get-all-plans This example shows a typical JSON response for a subscription plan listing from the HitPay API. It includes details about the subscription plans, pagination links, and metadata. This response is commonly used when retrieving a list of subscription plans. ```json { "data": [ { "id": "975b1909-38f6-44f3-a0b1-c198b7478978", "name": "subscription-plan_new_1664175178", "description": "New_Description_1664175178", "cycle": "custom", "cycle_repeat": 1, "cycle_frequency": "day", "currency": "sgd", "price": 123.45, "amount": 123.45, "reference": null, "created_at": "2022-09-26T14:52:58", "updated_at": "2022-09-26T14:52:58" }, { "id": "97533e84-4f48-4625-83de-1d2b3e3ae17b", "name": "subscription-plan_new_1663837869", "description": "New_Description_1663837869", "cycle": "custom", "cycle_repeat": 1, "cycle_frequency": "day", "currency": "sgd", "price": 9999999.99, "amount": 9999999.99, "reference": null, "created_at": "2022-09-22T17:11:09", "updated_at": "2022-09-22T17:11:09" } ], "links": { "first": "https://api.sandbox.hit-pay.com/v1/subscription-plan?page=1", "last": "https://api.sandbox.hit-pay.com/v1/subscription-plan?page=1", "prev": null, "next": null }, "meta": { "current_page": 1, "from": 1, "last_page": 1, "links": [ { "url": null, "label": "« Previous", "active": false }, { "url": "https://api.sandbox.hit-pay.com/v1/subscription-plan?page=1", "label": "1", "active": true }, { "url": null, "label": "Next »", "active": false } ], "path": "https://api.sandbox.hit-pay.com/v1/subscription-plan", "per_page": 25, "to": 2, "total": 2 } } ``` -------------------------------- ### GET /v1/account-status Source: https://docs.hitpayapp.com/apis/accounts/account-status Retrieves the account status for your HitPay account. This includes information about bank account completion, verification status, and the setup status of various payment providers. ```APIDOC ## GET /v1/account-status ### Description Retrieves the account status for your HitPay account. This includes information about bank account completion, verification status, and the setup status of various payment providers. ### Method GET ### Endpoint /v1/account-status ### Parameters #### Header Parameters - **X-BUSINESS-API-KEY** (string) - Required - Your HitPay Business API Key. ### Request Example ```json { "message": "No request body needed for this GET request." } ``` ### Response #### Success Response (200) - **bank_account_status** (string) - The status of the bank account. - **verification** (object) - Contains verification details: - **overall_status** (string) - The overall verification status of the account. - **owner_verification** (string) - The verification status for the account owner. - **business_verification** (string) - The verification status for the business. - **payment_providers** (object) - An object detailing the setup status for each payment provider. #### Response Example ```json { "bank_account_status": "completed", "verification": { "overall_status": "completed", "owner_verification": "not_required", "business_verification": "completed" }, "payment_providers": { "airwallex_sg": { "setup_status": "completed" }, "atome_sg": { "setup_status": "completed" }, "dbs_sg": { "setup_status": "pending" }, "fave_sg": { "setup_status": "completed" }, "shopback_sg": { "setup_status": "completed" }, "shopee_pay": { "setup_status": "completed" }, "stripe_sg": { "setup_status": "completed", "payment_enabled": true, "payout_enabled": true } } } ``` ``` -------------------------------- ### POST /v1/products Source: https://docs.hitpayapp.com/apis/product/create-product Creates a new product in the HitPay system. This endpoint allows for detailed product information including name, description, pricing, inventory, and category/location associations. ```APIDOC ## POST /v1/products ### Description Creates a new product in the HitPay system. This endpoint allows for detailed product information including name, description, pricing, inventory, and category/location associations. ### Method POST ### Endpoint https://api.sandbox.hit-pay.com/v1/products ### Parameters #### Header Parameters - **X-BUSINESS-API-KEY** (string) - Required - Your HitPay Business API Key. #### Request Body - **name** (string) - Required - The name of the product. - **description** (string) - Optional - The description of the product. - **barcode** (string) - Optional - The barcode of the product (max 255 characters). - **headline** (string) - Optional - The headline of the product. - **stock_keeping_unit** (string) - Optional - The stock keeping unit of the product (max 255 characters). - **quantity** (number) - Optional - The quantity of the product (minimum 0). - **quantity_alert_level** (number) - Optional - The quantity alert level for the product (minimum 0). - **currency** (string) - Optional - The currency of the product (e.g., 'sgd'). - **price** (number) - Optional - The price of the product. - **category_ids** (array[string]) - Optional - A list of business product category IDs (UUID format). - **channels** (array[string]) - Optional - The channels where the product is available (e.g., 'online_store', 'pos', 'invoice'). - **location_ids** (array[string]) - Optional - A list of location IDs (UUID format) where the product is available. - **locations** (array[object]) - Optional - Details about the product's availability at specific locations. - **id** (string) - Required - The location ID (UUID format). - **manage_inventory** (string) - Optional - Whether to manage inventory for this location ('1' or '0', default '1'). - **quantity** (integer) - Optional - The quantity of the product at this location (minimum 0). - **quantity_alert_level** (integer) - Optional - The quantity alert level at this location (minimum 0). - **open_amount** (string) - Optional - Whether the product has an open amount ('1' or '0'). ### Request Example ```json { "name": "Product Beanie", "description": "

Stylish hat suitable for the winter.

", "barcode": "1234567890123", "headline": "Stylish hat suitable for the winter.", "stock_keeping_unit": "SKU123456", "quantity": 10, "quantity_alert_level": 2, "currency": "sgd", "price": 15, "category_ids": ["9a12fab0-d282-4437-9460-c3d26662d11a"], "channels": ["online_store", "pos"], "location_ids": ["9a12fab4-d112-48af-9d6b-050d650b0a25"], "locations": [ { "id": "9a12fab4-d112-48af-9d6b-050d650b0a25", "manage_inventory": "1", "quantity": 5, "quantity_alert_level": 1 } ], "open_amount": "0" } ``` ### Response #### Success Response (200) - **id** (string) - The unique identifier of the created product. - **name** (string) - The name of the product. - **description** (string) - The description of the product. - **barcode** (string) - The barcode of the product. - **headline** (string) - The headline of the product. - **stock_keeping_unit** (string) - The stock keeping unit of the product. - **quantity** (number) - The current quantity of the product. - **quantity_alert_level** (number) - The quantity alert level for the product. - **currency** (string) - The currency of the product. - **price** (number) - The price of the product. - **category_ids** (array[string]) - The list of business product category IDs. - **channels** (array[string]) - The channels where the product is available. - **locations** (array[object]) - Details about the product's availability at specific locations. - **id** (string) - The location ID. - **manage_inventory** (string) - Whether inventory is managed for this location. - **quantity** (integer) - The quantity of the product at this location. - **quantity_alert_level** (integer) - The quantity alert level at this location. - **open_amount** (string) - Whether the product has an open amount. #### Response Example ```json { "id": "a1b2c3d4-e5f6-7890-1234-567890abcdef", "name": "Product Beanie", "description": "

Stylish hat suitable for the winter.

", "barcode": "1234567890123", "headline": "Stylish hat suitable for the winter.", "stock_keeping_unit": "SKU123456", "quantity": 10, "quantity_alert_level": 2, "currency": "sgd", "price": 15, "category_ids": ["9a12fab0-d282-4437-9460-c3d26662d11a"], "channels": ["online_store", "pos"], "locations": [ { "id": "9a12fab4-d112-48af-9d6b-050d650b0a25", "manage_inventory": "1", "quantity": 5, "quantity_alert_level": 1 } ], "open_amount": "0" } ``` ``` -------------------------------- ### HitPay Quick Sale Deep Link Generation Source: https://docs.hitpayapp.com/pos/deep-linking This example demonstrates how to construct a deep link URL to initiate a Quick Sale payment within the HitPay app. It includes essential parameters like amount, currency, description, and a callback URL. Ensure the user is logged into the HitPay app for this to function. ```URL hitpay://quick_sale?amount=100.00¤cy=SGD&description=Payment%20for%20order%201234&callback_url=https%3A%2F%2Fexample.com%2Fcallback ``` -------------------------------- ### Example API Response Data (JSON) Source: https://docs.hitpayapp.com/apis/payout/get-transfers Provides an example of the data payload returned by the API, showcasing a list of payment objects, each with detailed beneficiary information, transaction specifics, and status. This example uses JSON format. ```json { "data": [ { "id": "9ec02ec7-a121-457f-9efc-1c4610fbe4e6", "beneficiary": { "id": "9ec01865-7af1-4937-813d-7801912d2cd1", "status": "approved", "country": "sg", "currency": "sgd", "transfer_method": "bank_transfer", "transfer_type": "local", "nickname": null, "remark": null, "holder_name": "John Test", "holder_type": "individual", "account_number": "1409828", "bank_name": "BANK OF AMERICA", "bank_id": "BOFASG2XXXX[7065]", "email": null, "bank_swift_code": "BOFASG2XXXX", "is_favourite": false, "created_at": "2025-04-24T15:13:22+08:00", "updated_at": "2025-04-24T15:13:22+08:00", "deleted_at": null }, "payment_currency": "sgd", "payment_amount": 20, "source_currency": "usd", "source_amount": 15.45, "exchange_rate": "1.293876", "fee": { "amount": 0, "currency": "usd", "paid_by": "payer" }, "remark": "Remark In deserunt voluptates aspernatur aut nisi occaecati.", "reference": null, "status": "scheduled", "attachment": null, "created_at": "2025-04-24T16:15:57+08:00" }, { "id": "9ec01866-a609-4ce4-a3d1-e3e230872509", "beneficiary": { "id": "9ec01865-7af1-4937-813d-7801912d2cd1", "status": "approved", "country": "sg", "currency": "sgd", "transfer_method": "bank_transfer", "transfer_type": "local", "nickname": null, "remark": null, "holder_name": "John Test", "holder_type": "individual", "account_number": "1409828", "bank_name": "BANK OF AMERICA", "bank_id": "BOFASG2XXXX[7065]", "email": null, "bank_swift_code": "BOFASG2XXXX", "is_favourite": false, "created_at": "2025-04-24T15:13:22+08:00", "updated_at": "2025-04-24T15:13:22+08:00", "deleted_at": null }, "payment_currency": "sgd", "payment_amount": 20, "source_currency": "usd", "source_amount": 15.45, "exchange_rate": "1.293876", "fee": { "amount": 0, "currency": "usd", "paid_by": "payer" } } ] } ``` -------------------------------- ### Create Product Source: https://docs.hitpayapp.com/apis/product/create-product This endpoint allows you to create a new product with various attributes such as name, price, inventory, variations, and publishing status. ```APIDOC ## POST /websites/hitpayapp/products ### Description Creates a new product with specified details. ### Method POST ### Endpoint /websites/hitpayapp/products ### Parameters #### Request Body - **name** (string) - Required - The name of the product. - **description** (string) - Optional - The description of the product. - **barcode** (string) - Optional - The barcode of the product. - **headline** (string) - Optional - A short headline for the product. - **stock_keeping_unit** (string) - Optional - The stock keeping unit (SKU) for the product. - **quantity** (integer) - Optional - The initial quantity of the product. - **quantity_alert_level** (integer) - Optional - The alert level for product quantity. - **currency** (string) - Optional - The currency for the product price. - **price** (number) - Required - The price of the product. - **category_ids** (array of strings) - Optional - IDs of the categories the product belongs to. - **channels** (array of strings) - Optional - Channels where the product is available. - **locations** (array of objects) - Optional - Details of product availability in different locations. - **id** (string) - Required - Location ID. - **manage_inventory** (string) - Optional - Whether to manage inventory for this location ('1' or '0'). - **quantity** (integer) - Optional - Quantity at this location. - **quantity_alert_level** (integer) - Optional - Alert level at this location. - **open_amount** (string) - Optional - Whether the amount is open ('1' or '0'). - **is_manageable** (string) - Optional - Whether the product is manageable ('1' or '0'). Default: '1'. - **is_pinned** (string) - Optional - Whether the product is pinned ('1' or '0'). Default: '0'. - **product_weight** (integer) - Optional - The weight of the product in grams. - **delivery_method_required** (boolean) - Optional - Whether delivery method is required. Default: true. - **variations** (array of objects) - Optional - Product variations. - **image** (binary) - Optional - Image for the variation. - **price** (number) - Required - Price of the variation. - **quantity** (integer) - Required - Quantity of the variation. - **quantity_alert_level** (integer) - Required - Alert level for the variation quantity. - **product_variation_weight** (integer) - Optional - Weight of the variation in grams. - **variation_value_1** (string) - Optional - Value for the first variation attribute. - **variation_value_2** (string) - Optional - Value for the second variation attribute. - **variation_value_3** (string) - Optional - Value for the third variation attribute. - **image** (array of objects) - Optional - Images for the product. - **image** (binary) - Optional - Product image file. - **publish** (string) - Optional - Whether to publish the product ('1' or '0'). Default: '1'. ### Request Example ```json { "name": "Product Beanie", "description": "

Stylish hat suitable for the winter.

", "barcode": "1234567890123", "headline": "Stylish hat suitable for the winter.", "stock_keeping_unit": "SKU123456", "quantity": 1, "quantity_alert_level": 1, "currency": "sgd", "price": 15, "category_ids": [ "9a12fab0-d282-4437-9460-c3d26662d11a" ], "channels": [ "online_store" ], "locations": [ { "id": "9a12fab4-d112-48af-9d6b-050d650b0a25", "manage_inventory": "1", "quantity": 1, "quantity_alert_level": 1 } ], "open_amount": "0", "is_manageable": "1", "is_pinned": "0", "product_weight": 250, "delivery_method_required": true, "variations": [ { "price": 123, "quantity": 123, "quantity_alert_level": 123, "product_variation_weight": 123, "variation_value_1": "", "variation_value_2": "", "variation_value_3": "" } ], "publish": "1" } ``` ### Response #### Success Response (201) - **id** (string) - The unique identifier of the created product. - **business_id** (string) - The identifier of the business the product belongs to. - **category_id** (array of strings) - IDs of the categories the product belongs to. - **name** (string) - The name of the product. - **headline** (string) - A short headline for the product. - **description** (string) - The description of the product. - **currency** (string) - The currency for the product price. - **price** (number) - The price of the product. - **price_display** (string) - The displayed price of the product. - **price_stored** (string) - The stored price of the product. #### Response Example ```json { "id": "a1b2c3d4-e5f6-7890-1234-567890abcdef", "business_id": "biz-12345", "category_id": [ "9a12fab0-d282-4437-9460-c3d26662d11a" ], "name": "Product Beanie", "headline": "Stylish hat suitable for the winter.", "description": "

Stylish hat suitable for the winter.

", "currency": "sgd", "price": 15.0, "price_display": "$15.00", "price_stored": "1500" } ``` ``` -------------------------------- ### GET /websites/hitpayapp/products Source: https://docs.hitpayapp.com/apis/product/get-all-products Retrieves a list of products with pagination and associated meta information. ```APIDOC ## GET /websites/hitpayapp/products ### Description Retrieves a paginated list of products. Includes detailed information about each product, its variations, images, and associated meta data like current page, total pages, and links for navigation. ### Method GET ### Endpoint /websites/hitpayapp/products ### Parameters #### Query Parameters - **page** (integer) - Optional - The page number to retrieve. - **per_page** (integer) - Optional - The number of items to display per page. ### Request Example ```json { "example": "" } ``` ### Response #### Success Response (200) - **data** (array) - An array of product objects. - **id** (string) - Unique identifier for the product. - **business_id** (string) - Identifier for the associated business. - **category_id** (array of strings) - List of category IDs the product belongs to. - **name** (string) - The name of the product. - **description** (string) - A detailed description of the product (can include HTML). - **currency** (string) - The currency of the product price. - **price** (integer) - The base price of the product in the smallest currency unit. - **price_display** (string) - The formatted price of the product. - **price_stored** (integer) - The price stored in the smallest currency unit. - **is_manageable** (integer) - Indicates if the product is manageable (1 for true, 0 for false). - **is_pinned** (boolean) - Indicates if the product is pinned. - **status** (string) - The publication status of the product (e.g., 'published'). - **product_weight** (integer) - The weight of the product. - **delivery_method_required** (boolean) - Indicates if a delivery method is required. - **has_variations** (boolean) - Indicates if the product has variations. - **is_shopify** (boolean) - Indicates if the product is from Shopify. - **product_url** (string) - URL for the product. - **variations_count** (integer) - The number of variations available for the product. - **variations** (array) - An array of product variation objects. - **id** (string) - Unique identifier for the variation. - **description** (string) - Description of the variation. - **price** (integer) - Price of the variation. - **price_display** (string) - Formatted price of the variation. - **price_stored** (integer) - Stored price of the variation. - **quantity** (integer) - Available quantity of the variation. - **quantity_alert_level** (integer) - Alert level for stock quantity. - **variation_value_1** (string) - Value for the first variation key. - **variation_key_1** (string) - The name of the first variation key (e.g., 'Size'). - **images** (array) - An array of image objects for the product. - **id** (string) - Unique identifier for the image. - **caption** (string) - Caption for the image. - **url** (string) - URL of the image. - **other_dimensions** (array) - Different sizes/resolutions of the image. - **is_published** (boolean) - Indicates if the product is published. - **created_at** (string) - Timestamp of creation. - **updated_at** (string) - Timestamp of last update. - **links** (object) - Pagination links. - **first** (string) - URL for the first page. - **last** (string) - URL for the last page. - **prev** (string|null) - URL for the previous page. - **next** (string) - URL for the next page. - **meta** (object) - Meta information about the pagination. - **current_page** (integer) - The current page number. - **from** (integer) - The starting item number on the current page. - **last_page** (integer) - The total number of pages. - **links** (array) - Array of pagination link objects (usually empty in this context). - **path** (string) - The base URL path for pagination. - **per_page** (integer) - The number of items per page. - **to** (integer) - The ending item number on the current page. - **total** (integer) - The total number of items available. #### Response Example ```json { "data": [ { "id": "9a12fab4-d112-48af-9d6b-050d650b0a25", "business_id": "9130c422-bf97-4bd1-b370-07a3a6f40708", "category_id": [ "9a12fab0-d282-4437-9460-c3d26662d11a" ], "name": "Beanie", "headline": null, "description": "

Stylish hat suitable for the winter.

", "currency": "SGD", "price": 15, "price_display": "SGD 15.00", "price_stored": 1500, "tax_id": null, "is_manageable": 1, "is_pinned": false, "status": "published", "product_weight": 250, "delivery_method_required": true, "has_variations": true, "is_shopify": false, "product_url": "", "variations_count": 2, "variations": [ { "id": "9a12fab4-d998-44ea-ad11-8753be88a1c9", "stock_keeping_unit": null, "description": "Medium", "weight": null, "length": null, "width": null, "depth": null, "price": 18, "price_display": "SGD 18.00", "price_stored": 1800, "quantity": 150, "quantity_alert_level": 10, "product_variation_weight": 250, "variation_value_1": "Medium", "variation_value_2": null, "variation_value_3": null }, { "id": "9a12fab4-dd20-4f8f-9e74-de28629f863a", "stock_keeping_unit": null, "description": "Large", "weight": null, "length": null, "width": null, "depth": null, "price": 20, "price_display": "SGD 20.00", "price_stored": 2000, "quantity": 148, "quantity_alert_level": 10, "product_variation_weight": 255, "variation_value_1": "Large", "variation_value_2": null, "variation_value_3": null } ], "variation_key_1": "Size", "variation_key_2": null, "variation_key_3": null, "images": [ { "id": "9a12fab6-1e76-448e-8c45-e84e2e38f294", "caption": "Beanie", "url": "", "other_dimensions": [ { "size": "icon", "path": "" }, { "size": "large", "path": "" }, { "size": "small", "path": "" }, { "size": "medium", "path": "" }, { "size": "thumbnail", "path": "" } ] } ], "is_published": true, "created_at": "2023-09-07T13:04:22+08:00", "updated_at": "2023-09-18T14:36:54+08:00", "starts_at": null, "ends_at": null } ], "links": { "first": "", "last": "", "prev": null, "next": "h" }, "meta": { "current_page": 1, "from": 1, "last_page": 49, "links": [], "path": "", "per_page": 10, "to": 10, "total": 481 } } ``` ``` -------------------------------- ### Get Account Status OpenAPI Specification Source: https://docs.hitpayapp.com/apis/accounts/account-status This OpenAPI YAML defines the GET /v1/account-status endpoint. It specifies the request headers, including the mandatory `X-BUSINESS-API-KEY`, and the expected JSON response structure for account status and verification details. ```yaml paths: /v1/account-status: get: servers: - url: https://api.sandbox.hit-pay.com request: security: [] parameters: header: X-BUSINESS-API-KEY: schema: type: string required: true example: b286daabf9921b5a01a4621f026c111e046f8911feba212996c92159b98427d style: simple explode: false body: {} response: '200': application/json: schemaArray: - type: object properties: bank_account_status: type: string verification: type: object properties: overall_status: type: string owner_verification: type: string business_verification: type: string required: - overall_status - owner_verification - business_verification payment_providers: type: object properties: {} examples: Result: value: bank_account_status: completed verification: overall_status: completed owner_verification: not_required business_verification: completed payment_providers: airwallex_sg: setup_status: completed atome_sg: setup_status: completed dbs_sg: setup_status: pending fave_sg: setup_status: completed shopback_sg: setup_status: completed shopee_pay: setup_status: completed stripe_sg: setup_status: completed payment_enabled: true payout_enabled: true description: '200' deprecated: false type: path components: schemas: {} ``` -------------------------------- ### Website Assets Source: https://docs.hitpayapp.com/apis/product/get-product-details This section details how to access and manage website assets, specifically image paths categorized by size, and the publication status of the website. ```APIDOC ## Website Assets ### Description Provides access to image paths for a website, categorized by size (large, small, medium, thumbnail), and indicates the publication status, creation, and update timestamps. ### Method GET ### Endpoint /websites/hitpayapp ### Parameters #### Query Parameters - **size** (string) - Optional - Filters images by size (e.g., 'large', 'small', 'medium', 'thumbnail'). ### Response #### Success Response (200) - **paths** (array) - Array of image path objects, each containing a 'path' (string) and 'size' (string). - **is_published** (boolean) - Indicates if the website is published. - **created_at** (string) - Timestamp of creation. - **updated_at** (string) - Timestamp of last update. - **starts_at** (string | null) - Start date for publication. - **ends_at** (string | null) - End date for publication. - **description** (string) - Description of the content. #### Response Example ```json { "paths": [ { "path": "/path/to/large.jpg", "size": "large" }, { "path": "/path/to/small.jpg", "size": "small" }, { "path": "/path/to/medium.jpg", "size": "medium" }, { "path": "/path/to/thumbnail.jpg", "size": "thumbnail" } ], "is_published": true, "created_at": "2023-09-07T13:04:22+08:00", "updated_at": "2023-09-18T14:36:54+08:00", "starts_at": null, "ends_at": null, "description": "200" } ``` #### Error Response (404) - **message** (string) - Error message indicating no results were found. #### Error Response Example ```json { "message": "No query results for model [App\Business\Product]. 973ee456-d28f-4418-93c5-d37e4b311685" } ``` ``` -------------------------------- ### GET /v1/subscription-plan/{plan_id} Source: https://docs.hitpayapp.com/apis/recurring-billing/get-plan-details Retrieves the details of a specific subscription plan using its unique identifier. ```APIDOC ## GET /v1/subscription-plan/{plan_id} ### Description Retrieves the details of a specific subscription plan using its unique identifier. ### Method GET ### Endpoint https://api.sandbox.hit-pay.com/v1/subscription-plan/{plan_id} ### Parameters #### Path Parameters - **plan_id** (string) - Required - The unique identifier of the subscription plan. #### Query Parameters None #### Headers - **X-BUSINESS-API-KEY** (string) - Required - Your HitPay Business API Key. ### Request Example None (GET request with path parameters) ### Response #### Success Response (200) - **id** (string) - The unique identifier of the subscription plan. - **name** (string) - The name of the subscription plan. - **description** (string) - A description of the subscription plan. - **cycle** (string) - The billing cycle (e.g., 'monthly'). - **cycle_repeat** (any) - Details about cycle repetition (nullable). - **cycle_frequency** (any) - Frequency of the cycle (nullable). - **currency** (string) - The currency of the plan amount (e.g., 'sgd'). - **amount** (number) - The price of the subscription plan. - **reference** (string) - A reference identifier for the plan. - **created_at** (string) - The timestamp when the plan was created. - **updated_at** (string) - The timestamp when the plan was last updated. #### Error Response (422) - **message** (string) - An error message indicating that no results were found for the given plan ID. #### Response Example (200) ```json { "id": "973ee344-6737-4897-9929-edbc9d7bf433", "name": "Spotify Premium", "description": "Spotify Monthly Subscription", "cycle": "monthly", "cycle_repeat": null, "cycle_frequency": null, "currency": "sgd", "amount": 9.9, "reference": "spotify_premium_2022", "created_at": "2022-09-12T14:22:26", "updated_at": "2022-09-12T14:22:26" } ``` #### Response Example (422) ```json { "message": "No query results for model [App\Business\SubscriptionPlan] 973ee456-d28f-4418-93c5-d37e4b311685" } ``` ```