PHP Point of Sale MCP by usefulapi
Read PHP Point of Sale items, sales, customers and 138 reports; manage customers, items, expenses.
Sollte ich dies verwenden
Qualität und Sicherheit
Basierend auf einer automatisierten Analyse der Tool-Definitionen und der Einhaltung des Protokolls.
Kontextkosten
Dies ist die ungefähre Anzahl der Tokens, die jedes Mal verbraucht werden, wenn die Tools des Servers in den Kontext eines Modells geladen werden. Höhere Werte verringern die Aufmerksamkeit, die für andere Aufgaben verfügbar ist.
Installieren
Installation mit einem Klick
Fügen Sie dies Ihrer Datei `claude_desktop_config.json` hinzu:
{
"mcpServers": {
"php-point-of-sale": {
"url": "https://php-point-of-sale.usefulapi.io/mcp"
}
}
}Remote-Endpunkte
https://php-point-of-sale.usefulapi.io/mcpstreamable-httpWas es kann
Tool-Inventar
Tools (26)
🟢phppos_list_locations(search, offset, limit)
List the store's locations (shops/warehouses) with name, address, phone, email, time zone and default tax rates, plus each location's registers (id and name). Use the location ids to filter sales, expenses, customers and reports. Payment-processor credentials and device settings are never returned. GET /locations.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_items(search, search_field, category_id, sort_col, sort_dir, ...)
List or search inventory items with name, item number, category, supplier, prices and reorder level. Search by text, or by one field (name, item_number, product_id, supplier, tag_name...). GET /items.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"search_field": {
"description": "Limit the search to one field.",
"type": "string",
"enum": [
"item_id",
"item_number",
"product_id",
"name",
"description",
"size",
"cost_price",
"unit_price",
"promo_price",
"reorder_level",
"supplier",
"manufacturer_name",
"tag_name",
"ecommerce_product_id"
]
},
"category_id": {
"description": "Only items in this category id - see phppos_list_categories.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"sort_col": {
"description": "Column to sort by (a field name of the rows).",
"type": "string",
"pattern": "^[a-z][a-z0-9_]{0,60}$"
},
"sort_dir": {
"description": "Sort direction.",
"type": "string",
"enum": [
"asc",
"desc"
]
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-1000 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 1000
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_get_item(item_id)
One inventory item by id: prices, tax settings, category, supplier, tags, attributes, variations, tier pricing and per-location settings. GET /items/{id}.
Eingabe-Schema
{
"type": "object",
"properties": {
"item_id": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991,
"description": "PHP Point of Sale item id (find it with phppos_list_items)."
}
},
"required": [
"item_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_categories(search, offset, limit)
List item categories with their ids. Use the ids to filter items or to file a new item. GET /categories.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_item_kits(search, category_id, offset, limit)
List item kits (bundles of items sold together) with their prices. GET /item_kits.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"category_id": {
"description": "Only kits in this category id.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_sales(start_date, end_date, customer_id, email_address, location_id, ...)
List or search completed sales, by date range, customer (id or email) or location. verbosity: minimal (headline fields), medium (adds customer, totals, profit, location - the default here) or full (every line item, payment and tax). Suspended sales (layaways, estimates) are fetched with suspended_type. GET /sales.
Eingabe-Schema
{
"type": "object",
"properties": {
"start_date": {
"description": "Only sales on or after this date or date-time (yyyy-mm-dd or yyyy-mm-dd hh:mm:ss).",
"type": "string"
},
"end_date": {
"description": "Only sales on or before this date or date-time.",
"type": "string"
},
"customer_id": {
"description": "Only this customer's sales.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"email_address": {
"description": "Look the customer up by email address and return their sales.",
"type": "string",
"maxLength": 254,
"format": "email",
"pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
},
"location_id": {
"description": "Only sales at this location id - see phppos_list_locations.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"suspended_type": {
"description": "Fetch suspended sales instead of completed ones: a comma-separated list of layaway, estimate or a sale type name.",
"type": "string",
"pattern": "^[A-Za-z0-9 _.-]{1,60}(,[A-Za-z0-9 _.-]{1,60}){0,4}$"
},
"verbosity": {
"description": "minimal, medium (default) or full.",
"type": "string",
"enum": [
"minimal",
"medium",
"full"
]
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-1000 (default 25).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 1000
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_get_sale(sale_id, verbosity)
One sale by id with line items, payments, taxes, customer and employee (verbosity full by default). GET /sales/{id}.
Eingabe-Schema
{
"type": "object",
"properties": {
"sale_id": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991,
"description": "PHP Point of Sale sale id (the number on the receipt; find it with phppos_list_sales)."
},
"verbosity": {
"description": "minimal, medium or full (default).",
"type": "string",
"enum": [
"minimal",
"medium",
"full"
]
}
},
"required": [
"sale_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_receivings(start_date, end_date, offset, limit)
List receivings (stock received from suppliers, purchase orders, transfers) with supplier, totals and items, by date range. GET /receivings.
Eingabe-Schema
{
"type": "object",
"properties": {
"start_date": {
"description": "Only receivings on or after this date or date-time.",
"type": "string"
},
"end_date": {
"description": "Only receivings on or before this date or date-time.",
"type": "string"
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-1000 (default 25).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 1000
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_get_receiving(receiving_id)
One receiving by id: supplier, items, quantities, costs and payments. GET /receivings/{id}.
Eingabe-Schema
{
"type": "object",
"properties": {
"receiving_id": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991,
"description": "Receiving id (find it with phppos_list_receivings)."
}
},
"required": [
"receiving_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_customers(search, search_field, location_id, sort_col, sort_dir, ...)
List or search customers with contact details, tier, store-account balance, credit limit and loyalty points. Search by text or by one field (email, phone_number, first_name, last_name, account_number). GET /customers.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"search_field": {
"description": "Limit the search to one field.",
"type": "string",
"enum": [
"first_name",
"last_name",
"email",
"phone_number",
"account_number"
]
},
"location_id": {
"description": "Only customers at this location id.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"sort_col": {
"description": "Column to sort by (a field name of the rows).",
"type": "string",
"pattern": "^[a-z][a-z0-9_]{0,60}$"
},
"sort_dir": {
"description": "Sort direction.",
"type": "string",
"enum": [
"asc",
"desc"
]
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_get_customer(person_id)
One customer by person id: contact details, tier, tax settings, balance, credit limit, points, notes and custom fields. GET /customers/{person_id}.
Eingabe-Schema
{
"type": "object",
"properties": {
"person_id": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991,
"description": "Customer person id (find it with phppos_list_customers)."
}
},
"required": [
"person_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_suppliers(search, search_field, sort_col, sort_dir, offset, ...)
List or search suppliers with contact details, company, account number and balance. GET /suppliers.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"search_field": {
"description": "Limit the search to one field.",
"type": "string",
"enum": [
"first_name",
"last_name",
"email",
"phone_number",
"company_name",
"account_number"
]
},
"sort_col": {
"description": "Column to sort by (a field name of the rows).",
"type": "string",
"pattern": "^[a-z][a-z0-9_]{0,60}$"
},
"sort_dir": {
"description": "Sort direction.",
"type": "string",
"enum": [
"asc",
"desc"
]
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_get_supplier(person_id)
One supplier by person id. GET /suppliers/{person_id}.
Eingabe-Schema
{
"type": "object",
"properties": {
"person_id": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991,
"description": "Supplier person id (find it with phppos_list_suppliers)."
}
},
"required": [
"person_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_employees(search, location_id, offset, limit)
List employees with name, contact details, username, hire date, manager, commission and pay rate settings and assigned locations. Passwords and the permission maps are never returned. GET /employees.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"location_id": {
"description": "Only employees at this location id.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_invoices(type, search, sort_col, sort_dir, offset, ...)
List customer invoices (money customers owe) or supplier invoices (money the store owes) with date, due date, status and amount. GET /invoices/customer or /invoices/supplier.
Eingabe-Schema
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"customer",
"supplier"
],
"description": "customer = invoices to customers; supplier = invoices from suppliers."
},
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"sort_col": {
"description": "Column to sort by (a field name of the rows).",
"type": "string",
"pattern": "^[a-z][a-z0-9_]{0,60}$"
},
"sort_dir": {
"description": "Sort direction.",
"type": "string",
"enum": [
"asc",
"desc"
]
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"required": [
"type"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_expenses(search, location_id, sort_col, sort_dir, offset, ...)
List recorded expenses with type, description, date, amount, tax, payment type, category and location. GET /expenses.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"location_id": {
"description": "Only expenses at this location id.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"sort_col": {
"description": "Column to sort by (a field name of the rows).",
"type": "string",
"pattern": "^[a-z][a-z0-9_]{0,60}$"
},
"sort_dir": {
"description": "Sort direction.",
"type": "string",
"enum": [
"asc",
"desc"
]
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_gift_cards(search, offset, limit)
List gift cards with number, description, remaining value, customer and whether inactive. GET /giftcards.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_get_gift_card(giftcard_number)
One gift card by its card number (or id): remaining value, customer and status. GET /giftcards/{giftcard_number}.
Eingabe-Schema
{
"type": "object",
"properties": {
"giftcard_number": {
"type": "string",
"minLength": 1,
"maxLength": 60,
"pattern": "^[A-Za-z0-9_-]+$",
"description": "Gift card number or id."
}
},
"required": [
"giftcard_number"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_appointments(search, start_time, end_time, offset, limit)
List appointments (bookings) with customer, employee, service, start and end time, optionally within a time window. GET /appointments.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Free-text search.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"start_time": {
"description": "Only appointments starting on or after this date or date-time.",
"type": "string"
},
"end_time": {
"description": "Only appointments ending on or before this date or date-time.",
"type": "string"
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-100 (default 20).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_list_reports(search)
The catalog of the store's reports (138 of them: sales summaries, top sellers, inventory low/aging/summary, profit and loss, taxes, payments, employee, customer, supplier and store-account reports) with the inputs each accepts. Without `search` only the report keys are returned; with `search` (for example 'inventory' or 'profit') the matching reports are returned with their inputs. GET /reports.
Eingabe-Schema
{
"type": "object",
"properties": {
"search": {
"description": "Only reports whose key, description or inputs contain this text.",
"type": "string",
"minLength": 1,
"maxLength": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢phppos_run_report(report_key, params, offset, limit)
Run one of the store's reports and return it (title, summary, detail rows); `paging.next_offset` is set when more detail rows remain. Report keys and their inputs come from phppos_list_reports (for example summary_sales, top_sellers, inventory_low, summary_profit_and_loss, summary_taxes, closeout). Typical inputs go in `params`: start_date, end_date, sale_type, location_ids (array), category_id, supplier_id, customer_id, employee_id. A scoped key needs the Reports module plus that report's view permission. GET /reports/{report_key}.
Eingabe-Schema
{
"type": "object",
"properties": {
"report_key": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{0,80}$",
"description": "Report key from phppos_list_reports (for example summary_sales or inventory_low)."
},
"params": {
"description": "The report's inputs as listed by phppos_list_reports, e.g. {\"start_date\":\"2026-10-01\",\"end_date\":\"2026-10-31\",\"location_ids\":[1]}. Do not put limit/offset here.",
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"anyOf": [
{
"type": "string",
"maxLength": 300
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"maxItems": 50,
"type": "array",
"items": {
"anyOf": [
{
"type": "string",
"maxLength": 300
},
{
"type": "number"
}
]
}
}
]
}
},
"offset": {
"description": "Rows to skip (default 0). Pass the previous reply's next_offset (paging.next_offset for a report).",
"type": "integer",
"minimum": 0,
"maximum": 1000000
},
"limit": {
"description": "Rows per page, 1-500 (default 100).",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 500
}
},
"required": [
"report_key"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴phppos_create_customer(first_name, last_name, email, phone_number, address_1, ...)
WRITE: create a customer in the store. Store-account balance, credit limit and loyalty points cannot be set here. Needs a Read/Write API key. Retrying creates a duplicate (check phppos_list_customers first). The store's 'new customer' webhook, if configured, fires. POST /customers.
Eingabe-Schema
{
"type": "object",
"properties": {
"first_name": {
"type": "string",
"minLength": 1,
"maxLength": 100,
"description": "First name (required by PHP Point of Sale)."
},
"last_name": {
"description": "Last name.",
"type": "string",
"minLength": 1,
"maxLength": 100
},
"email": {
"description": "Email address.",
"type": "string",
"maxLength": 254,
"format": "email",
"pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
},
"phone_number": {
"description": "Phone number.",
"type": "string",
"minLength": 1,
"maxLength": 40
},
"address_1": {
"description": "Address line 1.",
"type": "string",
"maxLength": 200
},
"address_2": {
"description": "Address line 2.",
"type": "string",
"maxLength": 200
},
"city": {
"description": "City.",
"type": "string",
"maxLength": 100
},
"state": {
"description": "State or region.",
"type": "string",
"maxLength": 100
},
"zip": {
"description": "Postal code.",
"type": "string",
"maxLength": 30
},
"country": {
"description": "Country.",
"type": "string",
"maxLength": 100
},
"comments": {
"description": "Comments.",
"type": "string",
"maxLength": 2000
},
"company_name": {
"description": "Company name.",
"type": "string",
"maxLength": 200
},
"account_number": {
"description": "Customer account number.",
"type": "string",
"maxLength": 60
},
"taxable": {
"description": "Whether sales to this customer are taxed.",
"type": "boolean"
},
"internal_notes": {
"description": "Internal notes (not shown to the customer).",
"type": "string",
"maxLength": 4000
}
},
"required": [
"first_name"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴phppos_update_customer(person_id, first_name, last_name, email, phone_number, ...)
WRITE: change fields of an existing customer; only the fields you pass are sent. Overwrites the current values. Needs a Read/Write API key. The store's 'edit customer' webhook, if configured, fires. POST /customers/{person_id}.
Eingabe-Schema
{
"type": "object",
"properties": {
"person_id": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991,
"description": "Customer person id (find it with phppos_list_customers)."
},
"first_name": {
"description": "First name.",
"type": "string",
"minLength": 1,
"maxLength": 100
},
"last_name": {
"description": "Last name.",
"type": "string",
"minLength": 1,
"maxLength": 100
},
"email": {
"description": "Email address.",
"type": "string",
"maxLength": 254,
"format": "email",
"pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
},
"phone_number": {
"description": "Phone number.",
"type": "string",
"minLength": 1,
"maxLength": 40
},
"address_1": {
"description": "Address line 1.",
"type": "string",
"maxLength": 200
},
"address_2": {
"description": "Address line 2.",
"type": "string",
"maxLength": 200
},
"city": {
"description": "City.",
"type": "string",
"maxLength": 100
},
"state": {
"description": "State or region.",
"type": "string",
"maxLength": 100
},
"zip": {
"description": "Postal code.",
"type": "string",
"maxLength": 30
},
"country": {
"description": "Country.",
"type": "string",
"maxLength": 100
},
"comments": {
"description": "Comments.",
"type": "string",
"maxLength": 2000
},
"company_name": {
"description": "Company name.",
"type": "string",
"maxLength": 200
},
"account_number": {
"description": "Customer account number.",
"type": "string",
"maxLength": 60
},
"taxable": {
"description": "Whether sales to this customer are taxed.",
"type": "boolean"
},
"internal_notes": {
"description": "Internal notes (not shown to the customer).",
"type": "string",
"maxLength": 4000
}
},
"required": [
"person_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴phppos_create_item(name, description, unit_price, cost_price, promo_price, ...)
WRITE: create an inventory item (name required). Stock quantities are not set here. Needs a Read/Write API key. Retrying creates a duplicate (search with phppos_list_items first). The store's item webhooks, if configured, fire. POST /items.
Eingabe-Schema
{
"type": "object",
"properties": {
"name": {
"type": "string",
"minLength": 1,
"maxLength": 255,
"description": "Item name."
},
"description": {
"description": "Short description.",
"type": "string",
"maxLength": 1000
},
"unit_price": {
"description": "Selling price.",
"type": "number",
"minimum": 0,
"maximum": 10000000000
},
"cost_price": {
"description": "Cost price.",
"type": "number",
"minimum": 0,
"maximum": 10000000000
},
"promo_price": {
"description": "Promotional price.",
"type": "number",
"minimum": 0,
"maximum": 10000000000
},
"category_id": {
"description": "Category id - see phppos_list_categories.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"supplier_id": {
"description": "Supplier person id - see phppos_list_suppliers.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"item_number": {
"description": "Barcode / item number (UPC).",
"type": "string",
"maxLength": 100
},
"product_id": {
"description": "Product id / SKU.",
"type": "string",
"maxLength": 100
},
"size": {
"description": "Size.",
"type": "string",
"maxLength": 100
},
"is_service": {
"description": "True for a service (no stock tracking).",
"type": "boolean"
},
"item_inactive": {
"description": "True to deactivate the item (it can no longer be sold).",
"type": "boolean"
},
"reorder_level": {
"description": "Stock level at which the item shows as low.",
"type": "number",
"minimum": 0,
"maximum": 1000000000
},
"tags": {
"description": "Tag names.",
"maxItems": 20,
"type": "array",
"items": {
"type": "string",
"minLength": 1,
"maxLength": 60
}
}
},
"required": [
"name"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴phppos_update_item(item_id, name, description, unit_price, cost_price, ...)
WRITE: change fields of an existing item (for example its price, category or active state); only the fields you pass are sent. Overwrites the current values, and a price change applies to the next sale. Needs a Read/Write API key. The store's 'edit item' webhook, if configured, fires. POST /items/{item_id}.
Eingabe-Schema
{
"type": "object",
"properties": {
"item_id": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991,
"description": "Item id (find it with phppos_list_items)."
},
"name": {
"description": "Item name.",
"type": "string",
"minLength": 1,
"maxLength": 255
},
"description": {
"description": "Short description.",
"type": "string",
"maxLength": 1000
},
"unit_price": {
"description": "Selling price.",
"type": "number",
"minimum": 0,
"maximum": 10000000000
},
"cost_price": {
"description": "Cost price.",
"type": "number",
"minimum": 0,
"maximum": 10000000000
},
"promo_price": {
"description": "Promotional price.",
"type": "number",
"minimum": 0,
"maximum": 10000000000
},
"category_id": {
"description": "Category id - see phppos_list_categories.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"supplier_id": {
"description": "Supplier person id - see phppos_list_suppliers.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"item_number": {
"description": "Barcode / item number (UPC).",
"type": "string",
"maxLength": 100
},
"product_id": {
"description": "Product id / SKU.",
"type": "string",
"maxLength": 100
},
"size": {
"description": "Size.",
"type": "string",
"maxLength": 100
},
"is_service": {
"description": "True for a service (no stock tracking).",
"type": "boolean"
},
"item_inactive": {
"description": "True to deactivate the item (it can no longer be sold).",
"type": "boolean"
},
"reorder_level": {
"description": "Stock level at which the item shows as low.",
"type": "number",
"minimum": 0,
"maximum": 1000000000
},
"tags": {
"description": "Tag names.",
"maxItems": 20,
"type": "array",
"items": {
"type": "string",
"minLength": 1,
"maxLength": 60
}
}
},
"required": [
"item_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴phppos_create_expense(expense_description, expense_amount, expense_date, expense_tax, expense_type, ...)
WRITE: record an expense in the store's books (description, amount and date). It affects expense and profit-and-loss reports. Needs a Read/Write API key. Retrying records it twice (check phppos_list_expenses first). POST /expenses.
Eingabe-Schema
{
"type": "object",
"properties": {
"expense_description": {
"type": "string",
"minLength": 1,
"maxLength": 500,
"description": "What the expense was for."
},
"expense_amount": {
"type": "number",
"minimum": 0,
"maximum": 10000000000,
"description": "Amount, in the store's currency, before tax."
},
"expense_date": {
"description": "When it was incurred (yyyy-mm-dd or yyyy-mm-dd hh:mm:ss); defaults to now in the store.",
"type": "string"
},
"expense_tax": {
"description": "Tax amount.",
"type": "number",
"minimum": 0,
"maximum": 10000000000
},
"expense_type": {
"description": "Expense type, for example Utilities.",
"type": "string",
"maxLength": 100
},
"expense_reason": {
"description": "Reason.",
"type": "string",
"maxLength": 500
},
"expense_note": {
"description": "Note.",
"type": "string",
"maxLength": 1000
},
"expense_payment_type": {
"description": "Payment type, for example Cash.",
"type": "string",
"maxLength": 60
},
"category_id": {
"description": "Expense category id.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"location_id": {
"description": "Location id - see phppos_list_locations.",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
}
},
"required": [
"expense_description",
"expense_amount"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}Community
Nachweis