test

Embed
Preview of the card
<a href="https://linkyhub.net/docs/ref-test"><img src="https://linkyhub.net/docs/_api/public/orgs/2fd2a4b7-b627-4925-af1e-1c51bf890403/spaces/c4b920fb-a433-40b5-b354-ff84bf0c3eb1/pages/a291bbc0-dfcf-4415-a6d3-9784127d11ab/social-card.svg?v=3e7ae33eec8b" alt="test" width="600" height="315"></a>
POSThttps://linkyhub.net/api/v3/test/ordersScope orders:write

Test mode: create a PAID order flagged test:true on the creator’s product and fire order.paid. Only for an app in development acting for its owner, or a personal API key. No money moves, the buyer is never emailed, and test orders are left out of earnings, analytics, payouts and salesCount.

Request body

application/json
productIdstringrequired
The product id.
variantIdstring
Required when the product has variants.
buyerobject
Show child parameters
emailstring
namestring
shippingAddressobject
For a physical product; a sample US address when omitted.
Show child parameters
namestring
line1string
line2string
citystring
statestring
postalCodestring
countrystring
ISO 3166-1 alpha-2.
phonestring
{
  "productId": "string",
  "variantId": "string",
  "buyer": {
    "email": "string",
    "name": "string",
    "shippingAddress": {
      "name": "string",
      "line1": "string",
      "line2": "string",
      "city": "string",
      "state": "string",
      "postalCode": "string",
      "country": "string",
      "phone": "string"
    }
  }
}

Code samples

cURL
curl -X POST "https://linkyhub.net/api/v3/test/orders" \
  -H "Authorization: Bearer $LINKYHUB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"productId":"string","variantId":"string","buyer":{"email":"string","name":"string","shippingAddress":{"name":"string","line1":"string","line2":"string","city":"string","state":"string","postalCode":"string","country":"string","phone":"string"}}}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

201 Done.
{}
Headers
RateLimit-Limitinteger
Requests allowed in the current window.
RateLimit-Remaininginteger
Requests left in the current window.
RateLimit-Resetinteger
Seconds until the window resets.
default An error.
Example
{
  "error": "string",
  "message": "string"
}
Schema
errorstringrequired
A stable code to branch on, e.g. insufficient_scope.
messagestringrequired
A sentence to show a person.
Headers
RateLimit-Limitinteger
Requests allowed in the current window.
RateLimit-Remaininginteger
Requests left in the current window.
RateLimit-Resetinteger
Seconds until the window resets.
POSThttps://linkyhub.net/api/v3/test/orders/{orderId}/refundsScope orders:write

Refund a test order in full or in part. Nothing goes through Stripe; the order is marked refunded and order.refunded fires. Idempotency-Key is optional here. Real orders use POST /orders/{orderId}/refunds.

Parameters

orderIdstringpathrequired

Request body

application/json
amountCentsinteger
Omitted: everything not yet refunded.
reasonstring
{
  "amountCents": 0,
  "reason": "string"
}

Code samples

cURL
curl -X POST "https://linkyhub.net/api/v3/test/orders/{orderId}/refunds" \
  -H "Authorization: Bearer $LINKYHUB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"amountCents":0,"reason":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Done.
{}
Headers
RateLimit-Limitinteger
Requests allowed in the current window.
RateLimit-Remaininginteger
Requests left in the current window.
RateLimit-Resetinteger
Seconds until the window resets.
default An error.

Same as default · POST /test/orders

Headers
RateLimit-Limitinteger
Requests allowed in the current window.
RateLimit-Remaininginteger
Requests left in the current window.
RateLimit-Resetinteger
Seconds until the window resets.
Updated