Print Hive Purchase Requests API
Inventory purchase request management endpoints
Inventory purchase request management endpoints
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/printhiv3d-com:printhiv3d-com-purchase-requests-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Print Hive API Documentation Purchase Requests API
description: 'REST API for the Print Hive print farm management platform: printers, print jobs, models, materials, inventory, smart queue, and integrations.'
version: 1.0.0
servers:
- url: https://api.printhiv3d.com
description: Production
tags:
- name: Purchase Requests
description: Inventory purchase request management endpoints
paths:
/v1/inventory-purchase-requests:
post:
summary: Create a purchase request
tags:
- Purchase Requests
description: Any organization member can submit a multi-item purchase request.
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- items
properties:
items:
type: array
minItems: 1
items:
type: object
required:
- materialId
properties:
materialId:
type: string
format: uuid
requestedQuantity:
type: number
minimum: 1
inventoryItemId:
type: string
format: uuid
reason:
type: string
maxLength: 1000
priority:
type: string
enum:
- low
- normal
- high
- urgent
security:
- bearerAuth: []
responses:
'201':
description: Default Response
content:
application/json:
schema:
type: object
additionalProperties: true
'400':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: postV1InventoryPurchaseRequests
x-operation-id-source: derived
get:
summary: List purchase requests
tags:
- Purchase Requests
description: List purchase requests with nested items. materialId filter returns requests containing that material.
parameters:
- schema:
type: string
enum:
- pending
- approved
- ordered
- received
- rejected
- cancelled
in: query
name: status
required: false
- schema:
type: string
format: uuid
in: query
name: materialId
required: false
- schema:
type: string
format: uuid
in: query
name: requestedBy
required: false
- schema:
type: number
minimum: 1
default: 1
in: query
name: page
required: false
- schema:
type: number
minimum: 1
maximum: 100
default: 50
in: query
name: limit
required: false
security:
- bearerAuth: []
responses:
'200':
description: Default Response
content:
application/json:
schema:
type: object
properties:
data:
type: array
items:
type: object
additionalProperties: true
total:
type: number
page:
type: number
limit:
type: number
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: getV1InventoryPurchaseRequests
x-operation-id-source: derived
/v1/inventory-purchase-requests/summary:
get:
summary: Get purchase request counts by status
tags:
- Purchase Requests
description: Returns count of purchase requests grouped by status for the organization.
security:
- bearerAuth: []
responses:
'200':
description: Default Response
content:
application/json:
schema:
type: object
properties:
pending:
type: number
approved:
type: number
ordered:
type: number
received:
type: number
rejected:
type: number
cancelled:
type: number
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: getV1InventoryPurchaseRequestsSummary
x-operation-id-source: derived
/v1/inventory-purchase-requests/{id}:
get:
summary: Get a purchase request by ID
tags:
- Purchase Requests
description: Returns a single purchase request with nested items and material details.
parameters:
- schema:
type: string
format: uuid
in: path
name: id
required: true
security:
- bearerAuth: []
responses:
'200':
description: Default Response
content:
application/json:
schema:
type: object
additionalProperties: true
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'404':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: getV1InventoryPurchaseRequestsById
x-operation-id-source: derived
patch:
summary: Edit a purchase request
tags:
- Purchase Requests
description: Edit request-level fields. Requester can edit while pending (reason, priority). Admins can edit any time (all fields including notes).
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
reason:
type: string
maxLength: 1000
priority:
type: string
enum:
- low
- normal
- high
- urgent
notes:
type: string
maxLength: 2000
parameters:
- schema:
type: string
format: uuid
in: path
name: id
required: true
security:
- bearerAuth: []
responses:
'200':
description: Default Response
content:
application/json:
schema:
type: object
additionalProperties: true
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'403':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'404':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: patchV1InventoryPurchaseRequestsById
x-operation-id-source: derived
delete:
summary: Delete a purchase request
tags:
- Purchase Requests
description: Hard delete a pending purchase request and all its items. Only requester or admin.
parameters:
- schema:
type: string
format: uuid
in: path
name: id
required: true
security:
- bearerAuth: []
responses:
'200':
description: Default Response
content:
application/json:
schema:
type: object
properties:
message:
type: string
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'403':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'404':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'409':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: deleteV1InventoryPurchaseRequestsById
x-operation-id-source: derived
/v1/inventory-purchase-requests/{id}/items:
post:
summary: Add items to a pending purchase request
tags:
- Purchase Requests
description: Add one or more materials to an existing pending request. Requester or admin only.
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- items
properties:
items:
type: array
minItems: 1
items:
type: object
required:
- materialId
properties:
materialId:
type: string
format: uuid
requestedQuantity:
type: number
minimum: 1
inventoryItemId:
type: string
format: uuid
parameters:
- schema:
type: string
format: uuid
in: path
name: id
required: true
security:
- bearerAuth: []
responses:
'201':
description: Default Response
content:
application/json:
schema:
type: object
additionalProperties: true
'400':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'403':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'404':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'409':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: postV1InventoryPurchaseRequestsByIdItems
x-operation-id-source: derived
/v1/inventory-purchase-requests/{id}/items/{itemId}:
delete:
summary: Remove an item from a purchase request
tags:
- Purchase Requests
description: Remove a single item. If it's the last item, the entire request is deleted.
parameters:
- schema:
type: string
format: uuid
in: path
name: id
required: true
- schema:
type: string
format: uuid
in: path
name: itemId
required: true
security:
- bearerAuth: []
responses:
'200':
description: Default Response
content:
application/json:
schema:
type: object
additionalProperties: true
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'403':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'404':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'409':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: deleteV1InventoryPurchaseRequestsByIdItemsByItemId
x-operation-id-source: derived
/v1/inventory-purchase-requests/{id}/approve:
post:
summary: Approve a purchase request
tags:
- Purchase Requests
description: Admin only. Approves the entire request (all items). Only works on pending requests.
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
notes:
type: string
maxLength: 2000
parameters:
- schema:
type: string
format: uuid
in: path
name: id
required: true
security:
- bearerAuth: []
responses:
'200':
description: Default Response
content:
application/json:
schema:
type: object
additionalProperties: true
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'403':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'404':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'409':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: postV1InventoryPurchaseRequestsByIdApprove
x-operation-id-source: derived
/v1/inventory-purchase-requests/{id}/reject:
post:
summary: Reject a purchase request
tags:
- Purchase Requests
description: Admin only. Rejects the entire request. Only works on pending or approved requests.
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- reason
properties:
reason:
type: string
maxLength: 2000
parameters:
- schema:
type: string
format: uuid
in: path
name: id
required: true
security:
- bearerAuth: []
responses:
'200':
description: Default Response
content:
application/json:
schema:
type: object
additionalProperties: true
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'403':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'404':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'409':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: postV1InventoryPurchaseRequestsByIdReject
x-operation-id-source: derived
/v1/inventory-purchase-requests/{id}/cancel:
post:
summary: Cancel a purchase request
tags:
- Purchase Requests
description: Requester or admin can cancel a pending request.
parameters:
- schema:
type: string
format: uuid
in: path
name: id
required: true
security:
- bearerAuth: []
responses:
'200':
description: Default Response
content:
application/json:
schema:
type: object
additionalProperties: true
'401':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'403':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'404':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'409':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
'500':
description: Default Response
content:
application/json:
schema:
type: object
properties:
error:
type: string
message:
type: string
operationId: postV1InventoryPurchaseRequestsByIdCancel
x-operation-id-source: derived
components:
securitySchemes:
bearerAuth:
type: http
scheme: bearer
bearerFormat: JWT
apiKeyAuth:
type: apiKey
in: header
name: x-api-key
apiKey:
type: apiKey
in: header
name: x-api-key