Skip to main content
POST
/
payments
/
items
Create Item
curl --request POST \
  --url https://api.rootfi.dev/v4/payments/items \
  --header 'Content-Type: application/json' \
  --header 'api_key: <api-key>' \
  --data '
{
  "company_id": 123,
  "name": "<string>",
  "price": 123,
  "currency_id": "<string>",
  "description": "<string>",
  "sku": "<string>",
  "status": "DRAFT",
  "variants": [
    {
      "name": "<string>",
      "sku": "<string>",
      "price": 123,
      "attributes": {}
    }
  ]
}
'
{
  "rootfi_id": 157,
  "rootfi_created_at": "2024-01-22T05:07:31.465Z",
  "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
  "rootfi_company_id": 1089,
  "platform_id": "123456",
  "rootfi_deleted_at": "2023-11-07T05:31:56Z",
  "platform_unique_id": "<string>",
  "raw_data": {},
  "data_hash": "<string>",
  "name": "<string>",
  "description": "<string>",
  "sku": "<string>",
  "price": 123,
  "currency_id": "<string>",
  "type": "INVENTORY",
  "status": "DRAFT",
  "created_at": "<string>",
  "updated_at": "<string>",
  "variants": [
    {
      "rootfi_id": 123,
      "platform_id": "<string>",
      "name": "<string>",
      "sku": "<string>",
      "price": 123,
      "attributes": {}
    }
  ]
}
Create a new item (product or service) in the payment platform catalog.

Request Body

FieldTypeRequiredDescription
namestringYesDisplay name of the item
descriptionstringNoDetailed description
skustringNoStock Keeping Unit code
pricenumberYesBase price for this item
currency_idstringYesISO 4217 currency code
statusstringNoItem status (default: active)
variantsarrayNoProduct variants

Variant Fields

FieldTypeRequiredDescription
namestringYesVariant name (e.g., “Monthly”, “Annual”)
skustringNoVariant-specific SKU
pricenumberNoVariant price (if different from base)
attributesobjectNoKey-value attributes
See Item Overview for complete field details.

Authorizations

api_key
string
header
required

Body

application/json
company_id
integer
required
name
string
required
price
number<double>
required
currency_id
string
required
description
string | null
sku
string | null
status
enum<string> | null
Available options:
DRAFT,
ACTIVE,
ARCHIVED,
UNKNOWN
variants
paymentsV4ItemVariantCreate · object[] | null

Response

Item created successfully

V4 Item model representing products or services with variant support.

rootfi_id
number<double>
required

The unique ID we assign for that data's information

Example:

157

rootfi_created_at
string<date-time>
required

The date at which RootFi first synced this data

Example:

"2024-01-22T05:07:31.465Z"

rootfi_updated_at
string<date-time>
required

The latest date at which RootFi updated this data

Example:

"2024-01-22T05:07:31.000Z"

rootfi_company_id
number<double>
required

The ID of the company in the accounting platform

Example:

1089

platform_id
string
required

An unique custom RootFi ID made from platform's unique_id.

Example:

"123456"

rootfi_deleted_at
string<date-time> | null

The date at which the data was deleted in the accounting platform

platform_unique_id
string | null

The ID of the data in the accounting platform.

raw_data
object

A JSON containing fields that you can directly get from the accounting platform.

data_hash
string | null

The hash of the data

name
string | null

Display name of the item.

description
string | null

Detailed description of the item.

sku
string | null

Stock Keeping Unit code.

price
number<double> | null

Base price for this item.

currency_id
string | null

ISO 4217 currency code.

type
enum<string> | null

Type of item (INVENTORY, NON_INVENTORY, SERVICE, DIGITAL, UNKNOWN).

Available options:
INVENTORY,
NON_INVENTORY,
SERVICE,
DIGITAL,
UNKNOWN
status
enum<string> | null

Item availability status (DRAFT, ACTIVE, ARCHIVED, UNKNOWN).

Available options:
DRAFT,
ACTIVE,
ARCHIVED,
UNKNOWN
created_at
string | null

Original creation timestamp (ISO 8601).

updated_at
string | null

Last update timestamp (ISO 8601).

variants
paymentsV4ItemVariant · object[] | null

Product variants with different pricing/attributes.