Referansen er generert fra API-ets egen OpenAPI-spesifikasjon ved bygging av denne siden; spesifikasjonen kan lastes ned nedenfor for bruk i egne verktøy (kodegeneratorer, Postman, Bruno og lignende). Alle endepunkter krever autentisering — se Autentisering. Basis-URL-er for test og produksjon står under API integrasjon.

Spesifikasjonsversjon 2.372 · OpenAPI 3.0.3 · Last ned spesifikasjonen (YAML)

Asset Listing Resource

/assets/v2/asset/{id}/listing

PUTOffer an object on a marketplace, or edit the offer

Creates a listing when the asset has none (201) and updates one when it does (200). Requires write:assets and publish:marketplace.

The asking price is indicative — prisantydning, not a committed sale price; the settled price is agreed as an offer in sirk-service-backend. An absent price means 'price on request', which is a valid listed state.

The listing location is the seller's chosen pickup or viewing site, separate from the asset's own location (which the public passport never discloses). Send its name and coordinates alongside the id — they are stored as a snapshot and never resolved against orgadmin. Without coordinates the listing is still valid but is absent from map- and bounds-filtered marketplace queries.

Three location cases, and the difference matters: omitting the block publishes the asset's own location; sending a block publishes exactly what it carries (the id is optional — a name and coordinates alone are a valid pickup site); and 'deleteFields': ['location'] publishes no pickup location at all, for an object whose delivery address is agreed in the offer instead. Sending 'location': null is NOT a clear — it parses the same as an omitted block and falls back to the asset's own location, so a client clearing the field must say so with deleteFields. Sending both the block and the clear is a 400. 'location' is the only clearable field.

Listing does NOT publish the Digital Product Passport and does not require publish:dpp: the two are separate publications under separate permissions.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — ListingDto
201–
400–
401–
403–
404–
409–
DELETETake an object off the market

The reason is required and is what the event log records: WITHDRAWN writes a DELIST event, SOLD writes a SOLD event carrying the asking price and, when supplied, the settled price. There is no SOLD status — a sale is a moment, and in the good case it is an ownership transfer to another tenant, which delists automatically.

Idempotent: delisting something already unlisted succeeds and records nothing.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
reason *queryDelistReason
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
204–
400–
401–
403–

/assets/v2/asset/{id}/listing/reservation

POSTHold an object for a period

A reserved listing stays publicly visible, badged with its end date — a hold nobody can see is not a hold. The holding party is optional and may be a tenant or free text: a project reserving an object months ahead need not be an organization here.

Requires write:assets only. Placing a hold edits an offer this organization has already published; it is not a second act of publishing.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — ListingDto
400–
401–
403–
409–
DELETEEnd a hold

Returns the object to available without touching its price or location. An order-driven hold is released by the order that placed it, named through reservationRef; the owning organization may override with force=true, which the RELEASE event records. Idempotent when nothing is held.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
forcequeryboolean
reservationRefquerystring
X-auth-ownerheaderstring

Svar

StatusInnhold
204–
401–
403–
409–

Asset Resource

/assets/v2/asset

GETGet assets filtered by location, batch and/or category.

The filters are optional and can be combined. Categories and locations are referenced by orgadmin category id (Long); pass repeated query params for multi-select (?categoryIds=42&categoryIds=87). Subtree expansion is the frontend's job — pass the full id list (see docs/V2_API_GUIDE.md §5). A list too long for a query string (~45 ids, since global class ids are ~17 characters) goes to POST /asset/search instead. With batchId, the listing (and its count) also includes members of the batch that the caller's organization deleted after they joined it, so a completed round keeps every point it had. A deleted member is listed with deleted: true and still answers 404 on GET /asset/{id}. CSV and PDF exports leave deleted members out. Assets can be exported as csv ('Accept' header 'application/octet-stream') or pdf ('Accept' header 'application/pdf'), where the pdf export will be QR codes for the assets' tags

Parametre

NavnITypeBeskrivelse
batchIdqueryinteger (int64)
categoryIdsqueryliste av integer (int64)
formatqueryPdfFormat
locationCategoryIdsqueryliste av integer (int64)
searchquerystring
statesqueryliste av AssetState
X-auth-ownerheaderstring
listingStatusesqueryliste av ListingStatus
pageOffsetqueryinteger (int32)
pageSizequeryinteger (int32)

Svar

StatusInnhold
200application/json — liste av AssetBasicDto
application/pdf — StreamingOutput
text/csv — StreamingOutput
401–
403–
POSTCreate a new asset

Optional events are recorded against the new asset, in array order, in the same transaction as the create, under the same rules as POST /asset/{id}/events (max 10). The response echoes them as events, in order.

Parametre

NavnITypeBeskrivelse
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — AssetDto
400–
401–
403–
PATCHUpdate categoryIds and/or locationCategoryId on multiple assets identified by id. categoryIds, if present, replaces the existing set on each asset.

Parametre

NavnITypeBeskrivelse
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
204–
401–
403–
DELETEDelete multiple assets identified by id. Atomic: if any id is missing or belongs to another tenant, no assets are deleted.

Parametre

NavnITypeBeskrivelse
ids *queryliste av integer (int64)
X-auth-ownerheaderstring

Svar

StatusInnhold
204–
401–
403–

/assets/v2/asset/claim/{tag}

GETWhat the current organization may do with a printed code

CLAIMABLE when the tag is allocated to this organization and unclaimed; CLAIMED with its assetId when this organization claimed it; UNAVAILABLE for everything else. Every negative case answers identically on purpose — tag ids are enumerable, so distinguishing "does not exist" from "belongs to someone else" would map out which codes are live and who holds them.

Parametre

NavnITypeBeskrivelse
tag *pathstring
X-auth-ownerheaderstring

Svar

StatusInnhold
200application/json — ClaimStatusDto
401–
403–
POSTBind a pre-printed tag to a new asset

Same body as POST /asset. Succeeds only when the tag is allocated to the current organization, unclaimed, and its run is not voided. With no events, the asset is created PROVISIONED and activates on first write exactly like any other, so claiming itself is not billable activity. Optional events are recorded against the new asset, in array order, in the same transaction, under the same rules as POST /asset/{id}/events (max 10); the response echoes them as events, in order. A claim carrying events ends COMMISSIONED with one ACTIVATE event and can no longer be unclaimed with DELETE /asset/claim/{tag}, which requires PROVISIONED.

Parametre

NavnITypeBeskrivelse
tag *pathstring
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
201–
400–
401–
403–
404–
409–
DELETEReverse a mis-scanned claim

Allowed while the asset is still PROVISIONED, has no documents, and the claim is younger than the configured window. Soft-deletes the asset and returns the tag to its allocation. An ordinary DELETE /asset/{id} does not release the tag — the label is on an object by then.

Parametre

NavnITypeBeskrivelse
tag *pathstring
X-auth-ownerheaderstring

Svar

StatusInnhold
204–
401–
403–
404–
409–

/assets/v2/asset/groups

GETGroup assets by category, location or state after applying the same filters as GET /asset.

Returns a flat list of { id, state, count } entries, where count is the number of items (the sum of quantity, so a lot of 50 counts 50), keyed by whichever of `id` and `state` `by` selects — the other is null. For `by=category` and `by=location`, `id` is the categoryId or locationCategoryId; for `by=state` the key is the AssetState name. Buckets with no matching assets are omitted, as is the unassigned (null) location bucket. `by=state` does keep its null bucket: every asset has exactly one state, so those buckets sum to the total number of matching items, and only do so with the stateless assets among them. Backend is hierarchy-blind — frontend rolls counts up against the taxonomy tree. For `by=category`, an asset tagged with N categories contributes its quantity to each of those N buckets, so the sum of counts may exceed the total matching item count. The pagination headers of GET /asset stay row counts (assets, not items). With batchId, the batch's members deleted by the caller's organization after joining it are counted, as in GET /asset.

Parametre

NavnITypeBeskrivelse
batchIdqueryinteger (int64)
by *queryAssetGroupBy
categoryIdsqueryliste av integer (int64)
locationCategoryIdsqueryliste av integer (int64)
searchquerystring
statesqueryliste av AssetState
X-auth-ownerheaderstring

Svar

StatusInnhold
200application/json — liste av AssetGroupDto
401–
403–

/assets/v2/asset/import

POSTImport a csv file to update existing assets

Parametre

NavnITypeBeskrivelse
X-auth-ownerheaderstring

Forespørselskropp *

  • multipart/form-data — object

Svar

StatusInnhold
204–
401–
403–

/assets/v2/asset/search

POSTGet assets filtered by location, batch and/or category, with the filter in the request body.

Identical in behaviour and response to GET /asset — including the X-page-total and X-entries-total headers — but the filter travels as JSON, so it is not limited by query-string length. Use it when the expanded id list is too large for a URL (see docs/V2_API_GUIDE.md §5); GET /asset remains the right call for ordinary filters. Subtree expansion is still the frontend's job: pass the full id list. With batchId, the batch's members deleted by the caller's organization after joining it are included, as in GET /asset (rows marked deleted: true).

Parametre

NavnITypeBeskrivelse
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — liste av AssetBasicDto
400–
401–
403–

/assets/v2/asset/stats

GETGet asset statistics for the current organization

Counts are items (the sum of quantity), not asset rows. newAssetsPerMonth sums the current quantity of the assets activated in each month, so it is retroactive: changing a lot's quantity later moves the month it was activated in.

Parametre

NavnITypeBeskrivelse
X-auth-ownerheaderstring

Svar

StatusInnhold
200application/json — AssetStatisticsDto
401–
403–

/assets/v2/asset/{id}

GETGet an asset by id

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Svar

StatusInnhold
200application/json — AssetDto
401–
403–
PATCHUpdate an existing asset. Only fields that are included in the message body are updated. Fields that are to be removed must be included in the 'deleteFields' list. ownerOrg/ownerLabel and holderOrg/holderLabel/holderSince describe the physical object's owner and current holder -- distinct from the asset's tenant organization, and neither grants any access. Setting ownerOrg to another organization requires write:assets for that organization; setting holderOrg does not. ownerOrg/ownerLabel are mutually exclusive for display (the slug always wins over the label), as are holderOrg/holderLabel: setting only one of a pair in a request clears the other. holderSince is optional even when the holder changes -- it defaults to now when the holder identity actually changes and is cleared automatically when the holder is cleared. Optional events are recorded against the asset after the update is applied, in array order, in the same transaction, under the same rules as POST /asset/{id}/events (max 10); the response echoes them as events, in order. quantity (at least 1) sets how many interchangeable items the asset stands for; a change is recorded on the UPDATE event with previousQuantity, quantity and the optional quantityReason (max 200), and quantity cannot be cleared via deleteFields.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — AssetDto
401–
403–
DELETEDelete an asset by id

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Svar

StatusInnhold
204–
401–
403–

/assets/v2/asset/{id}/consume

POSTConsume items from a lot into another asset

Decreases the lot {id} by quantity and records the link on both assets: a CONSUME event on the lot and an INCORPORATE event on the target (read them via GET /event). The lot and the target must both belong to the current organization (X-auth-owner), where write:assets is required; any other case gives 404. The target is not modified. When quantity equals the lot's quantity the lot is deleted as by DELETE /asset/{id} (open listing withdrawn, DELETE event with reason CONSUMED) and the response has remainingQuantity 0 and sourceDeleted true. 400 (error-message header): target is the lot, quantity below 1 or above the lot's, note over 500 characters. 409: the asset (quantity 1) is reserved, or the lot changed concurrently (retry).

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — ConsumeResultDto
400–
401–
403–
404–
409–

/assets/v2/asset/{id}/documents

POSTUpload a document to an asset. The file is processed inline: for images, EXIF rotation is applied, the original is scaled to fit within 2048x2048 if larger, and 100x100 + 200x200 JPEG thumbnails are generated. Only JPEG and PNG images are accepted; other formats are rejected with 400. Every image upload is privacy-gated by the iris classifier — blocked images (e.g. containing faces) return 422 with body 'image_blocked:<reason>'. Gating is best-effort: if the classifier sidecar is unreachable or unconfigured the upload proceeds ungated (failures are logged). When classify=true the classifier also applies category, description, and color suggestions to empty asset fields. Accept-Language (nb/nn/no → Norwegian, else English) selects the language of the description suggestion. Returns the updated AssetDto with the new document attached. When 'includeNextHint'=true the response carries response header 'X-next-tag-hint' — the encoded tag for the current tag's id + 1. Pure arithmetic on the tag id, no DB lookup. The hint may resolve to a tag the caller cannot access (different org, deleted, already activated); the frontend is expected to attempt GET /tag/{hint} and fall back to its own discovery on 404. When 'requireProvisioned'=true the call short-circuits with 400 ('error-message: asset_not_provisioned') if the asset's current state is anything other than PROVISIONED. The spec-012 register flow sends this to defend against a race where a stale UI cache lets the operator POST to an already-COMMISSIONED asset. 'additionalAssetIds' (repeated) links the same uploaded document to more assets in the same call: the file is stored once and the one Document row is linked to the path asset and every additional id (deduplicated, path id dropped, capped at 100 — over the cap returns 400 'error-message: too_many_additional_assets'). A non-numeric value in 'additionalAssetIds' returns 400 'error-message: invalid_additional_asset_ids'. Sending more than 1000 multipart form parts in total returns 400 'error-message: too_many_form_fields'. 'onDuplicateName' decides what happens when the upload's resolved storage key already belongs to an existing document row, anywhere -- the check is per storage key (which already embeds the path asset's id and the file name), not limited to documents the path asset or an additional asset currently references: absent or 'REJECT' keeps the existing 400; 'RETURN_EXISTING' makes no S3 write, thumbnail or classifier call, links the existing document to every asset not yet referencing it and returns 200 (422 'image_blocked:<reason>' if that document was privacy-blocked); any other value returns 400 'error-message: invalid_on_duplicate_name'. requireProvisioned/includeNextHint/classify apply to the path asset only. Authorization: requires write:assets for the caller's organization, plus access to the path asset and every additional asset -- each is loaded under the caller's organizations before anything is stored, so a missing or unclaimed id 404s, an id belonging to another organization 403s, and the whole call fails with nothing written.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
Accept-Languageheaderstring
X-auth-ownerheaderstring

Forespørselskropp *

  • multipart/form-data — object

Svar

StatusInnhold
200application/json — AssetDto
401–
403–

/assets/v2/asset/{id}/documents/{documentId}

PATCHChange a document's visibility. Publishing is what puts an asset's photo on the public marketplace and on its public product passport — both read this flag and nothing else — and uploads arrive private, so this is how a picture is published after the fact. Making a document private again removes it from both on the next read. An image the privacy classifier blocked cannot be published: the call returns 422 with body 'image_blocked:<reason>', exactly as the upload did. Requires write:assets.

Parametre

NavnITypeBeskrivelse
documentId *pathinteger (int64)
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — DocumentDto
401–
403–
DELETERemove a document from an asset. If the document is not referenced by any other asset, its S3 objects (original and thumbnails) and the document row are also deleted.

Parametre

NavnITypeBeskrivelse
documentId *pathinteger (int64)
id *pathinteger (int64)
X-auth-ownerheaderstring

Svar

StatusInnhold
204–
401–
403–

/assets/v2/asset/{id}/documents/{documentId}/replace

POSTReplace the bytes of an existing document. Reuses the existing S3 key, so any links that referenced the old document continue to work. Image documents re-run thumbnail generation but classification is not re-run.

Parametre

NavnITypeBeskrivelse
documentId *pathinteger (int64)
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

  • multipart/form-data — object

Svar

StatusInnhold
200application/json — DocumentDto
401–
403–

/assets/v2/asset/{id}/events

POSTRecord a manual event against an asset

Adds a user-authored event (e.g. a completed service, control round or note) to the asset's activity log. Read it back via GET /event?type=ASSET&id={id}. The kind is one of AssetEventType; specifics belong in the free-text note. Optional documentIds must already be attached to this asset (POST /asset/{id}/documents). Optional occurredAt/performedBy/location describe when the thing actually happened, by whom and where -- distinct from the event's own timestamp, which is always the server clock at the moment it was recorded, never occurredAt. Optional co2eKg is kilograms of CO2 equivalent attributed to this event; must be zero or greater and finite. Optional co2eReference (max 200 characters) is an opaque caller reference identifying the calculation or record co2eKg came from, e.g. reinventar:order:123:line:2 -- never parsed, resolved or otherwise interpreted by this service. There is no separate report endpoint for the figure's supporting document: upload it via POST /asset/{id}/documents with documentType: DOCUMENT, then pass the returned document id in this event's documentIds. Optional checklist records a control point's checklist visit; requires manualType INSPECTION. Its template is validated (version 1, CHECK items only, unique keys, 1-100 items), every required template item must be answered, each item's documentIds must already be attached to this asset, and resolution is not supported here. answeredBy/answeredAt on each item are server-stamped (client values ignored); the event's result is derived as DEVIATION iff any item is DEVIATION -- a supplied result must agree. Stored verbatim as data.checklist. Requires write:assets; allowed cross-tenant wherever the asset is visible to the caller.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — EventDto
400–
401–
403–

Batch Resource

/assets/v2/batch

GETGet all batches. The 'states' and 'types' query params must be a comma separated list of the corresponding enum.

Returns a set of all batches

Parametre

NavnITypeBeskrivelse
statesquerystring
tagquerystring
typesquerystring
X-auth-ownerheaderstring

Svar

StatusInnhold
200application/json — liste av BatchDto
401–
403–
POSTCreate a new batch of existing assets, or create a given number of new assets as well

If 'numberOfNewAssets' is set, type is set to ASSET_CREATION and 'assetIds' is ignored

Parametre

NavnITypeBeskrivelse
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — BatchDto
400–
401–
403–

/assets/v2/batch/tags

GETGenerate Qr Codes

Parametre

NavnITypeBeskrivelse
nqueryinteger (int32)

Svar

StatusInnhold
200text/csv — StreamingOutput
401–
403–

/assets/v2/batch/{id}

GETGet a batch by id or guid

Parametre

NavnITypeBeskrivelse
id *pathstring
X-auth-ownerheaderstring

Svar

StatusInnhold
200application/json — BatchDto
401–
403–
POSTUpdate all assets within a given batch. Only fields that are included in the message body are updated

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
204–
400–
401–
403–
PATCHUpdate an existing batch. Only fields that are included in the message body are updated. Fields that are to be removed must be included in the 'deleteFields' list

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — BatchDto
401–
403–

Config Resource

/assets/v2/config/asset/states

GETAsset States

Svar

StatusInnhold
200application/json — liste av AssetState

/assets/v2/config/batch/states

GETBatch States

Svar

StatusInnhold
200application/json — liste av BatchState

/assets/v2/config/batch/types

GETBatch Types

Svar

StatusInnhold
200application/json — liste av BatchType

/assets/v2/config/external

GETExternal Ids

Svar

StatusInnhold
200application/json — liste av ExternalIdDto
401–
403–

/assets/v2/config/pdf

GETPdf Formats

Svar

StatusInnhold
200application/json — liste av PdfFormat

/assets/v2/config/pdf/empty

GETGet Empty Pdf

Svar

StatusInnhold
200application/pdf — StreamingOutput

/assets/v2/config/user/{id}

GETUser Preferences

Parametre

NavnITypeBeskrivelse
id *pathstring

Svar

StatusInnhold
200application/json — UserPreferencesDto
401–
403–
POSTUpdate User Preference

Parametre

NavnITypeBeskrivelse
id *pathstring

Forespørselskropp *

Svar

StatusInnhold
201–
400–
401–
403–

/assets/v2/config/warranty/period

GETWarranty Period

Svar

StatusInnhold
200application/json — liste av WarrantyPeriod
401–
403–

Deviation Resource

/assets/v2/deviation

GETGet all deviations, optionally filtered.

The 'states' query param is a comma separated list of DeviationState (OPEN, CLOSED); 'batchGuid' filters on the originating batch (e.g. a control round); 'assetId' on the anchoring asset; 'checkKey' on the checklist check the deviation was raised from (keys are only unique within one asset's template, so combine it with 'assetId' for a per-check history).

Parametre

NavnITypeBeskrivelse
assetIdqueryinteger (int64)
batchGuidquerystring
checkKeyquerystring
statesquerystring
X-auth-ownerheaderstring

Svar

StatusInnhold
200application/json — liste av DeviationDto
401–
403–
POSTCreate a deviation (created OPEN)

A follow-up record for a fault found on an asset. Anchored on the asset ('assetId'); 'batchGuid' optionally references the batch (e.g. control round) it was found in. Creator and timestamp are server-derived. Optional documentIds must already be attached to the asset. Optional checkKey names the check this deviation was found from: it requires batchGuid, must match ^[a-z0-9][a-z0-9_-]{0,63}$, and must be a key of the template on the latest ASSET/MANUAL checklist visit on this asset in that batch, else 400. Fixed at creation; not settable on update. Audited via the event log (GET /event?type=DEVIATION&id={id}).

Parametre

NavnITypeBeskrivelse
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — DeviationDto
400–
401–
403–

/assets/v2/deviation/{id}

GETGet a deviation by id

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Svar

StatusInnhold
200application/json — DeviationDto
401–
403–
PATCHUpdate a deviation's follow-up fields (only while OPEN)

Enrichment of correctiveAction, dueDate and responsible. A CLOSED deviation is immutable and rejects updates with 400.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — DeviationDto
401–
403–

/assets/v2/deviation/{id}/close

POSTClose a deviation

Records the closing user id and timestamp as the auditable signature; the deviation is immutable afterwards. Closing an already CLOSED deviation is rejected with 400.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
200application/json — DeviationDto
400–
401–
403–

Event Resource

/assets/v2/event

GETReturn all events, filtered by type (optional) or type and id (also optional)

Parametre

NavnITypeBeskrivelse
actionqueryEventAction
idqueryinteger (int64)
pageOffsetqueryinteger (int32)
pageSizequeryinteger (int32)
typequeryEventType
X-auth-ownerheaderstring

Svar

StatusInnhold
200application/json — liste av EventDto
401–
403–

Marketplace Resource

/assets/v2/marketplace/listings

GETObjects currently offered on a marketplace

Anonymous and cross-tenant: no JWT, no X-auth-owner. Returns only listings a tenant explicitly published, excluding discarded and deleted assets and anything outside the queried channel.

Pagination follows the solutions marketplace rather than this backend's house style — pageNumber/pageSize (max 100), a flat array, and the match count in X-Total-Count — so the marketplace frontend consumes both the same way. Ordered by listedAt descending with an id tiebreak, so paging is stable.

categoryMatch=DESCENDANTS expands each global taxonomy id to its subtree server-side; an organization-specific id is always matched exactly, because it means nothing to another tenant. A bounding box needs all four coordinates, and a listing whose location carries none is absent from a bounded result. status defaults to AVAILABLE; an elapsed reservation reads as AVAILABLE whether or not the sweep has run. UNLISTED is not a queryable status.

The asking price is indicative and is per item; quantity is the number of items on offer, and a reservation or sale takes the whole lot. askingPriceMin and askingPriceMax filter on the price per item. A listing with no price is returned with a null amount ('price on request') and matches neither price bound.

Parametre

NavnITypeBeskrivelse
askingPriceMaxquerynumber
askingPriceMinquerynumber
categoryIdsqueryliste av integer (int64)
categoryMatchqueryCategoryMatch
channelquerystring
maxLatitudequerynumber (double)
maxLongitudequerynumber (double)
minLatitudequerynumber (double)
minLongitudequerynumber (double)
organizationIdsqueryliste av string
pageNumberqueryinteger (int32)
pageSizequeryinteger (int32)
searchquerystring
statusqueryliste av string

Svar

StatusInnhold
200application/json — liste av MarketplaceListingDto
400–
429–

/assets/v2/marketplace/listings/{listingId}

GETOne offered object, by listing id

Anonymous and cross-tenant like the list, and bounded by the same rule: only a listing a tenant published, on the queried channel, whose asset is neither discarded nor deleted.

A held object is served — its status reads RESERVED and carries the end date, never the party holding it — because the list's AVAILABLE default is a browsing convenience, not a rule about what may be read.

A listing that was withdrawn and one that never existed answer the same 404, so ids cannot be walked to discover what a tenant has not published.

Parametre

NavnITypeBeskrivelse
listingId *pathinteger (int64)
channelquerystring

Svar

StatusInnhold
200application/json — MarketplaceListingDto
400–
404–
429–

Site Admin Asset Resource

/assets/v2/site/statistics

GETUsage statistics for every organization

One entry per organization owning at least one asset, document or activation event. 'stored' is current inventory in items (the sum of quantity) regardless of range; 'handled.asset' counts activation events (one per lot) and has one zero-filled bucket per month in the range. Figures may be up to the cache TTL old — see the Cache-Control header.

Parametre

NavnITypeBeskrivelse
fromquerystringFirst month, YYYY-MM. Defaults to 12 months before the current one.
toquerystringLast month, YYYY-MM. Defaults to the current month.

Svar

StatusInnhold
200application/json — liste av SiteStatisticsDto
400–
401–
403–

Site Admin Tag Resource

/assets/v2/site/tags/runs

GETEvery print run, newest first, with its counts

Svar

StatusInnhold
200application/json — liste av TagPrintRunDto
401–
403–
POSTMint a print run of unclaimed tags

Creates `quantity` tags belonging to a new run, none attached to an asset and none allocated. Between 1 and 5000. Records one TAG/CREATE event for the run, not one per tag.

Forespørselskropp *

Svar

StatusInnhold
201–
400–
401–
403–

/assets/v2/site/tags/runs/{id}

GETOne print run with its counts and allocations

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)
formatqueryPdfFormat

Svar

StatusInnhold
200application/pdf — StreamingOutput
text/csv — StreamingOutput
401–
403–
404–

/assets/v2/site/tags/runs/{id}/allocations

POSTShip a range of the run to one organization

Give the range as fromTag+toTag or fromTag+count. Resolved run-relative in id order, never by id arithmetic. All-or-nothing on conflict; re-applying an identical allocation is a no-op, not an error. With `?dryRun=true` the range is resolved and validated exactly as a real allocation — same 400s, same 409s, same body — but nothing is written and no event is recorded, so an operator can check the resolved end code against the stack of labels in their hand before committing. The resolution is advisory: the commit re-validates, and an allocation landing in between still fails it with a 409. The flag takes `true` or `false` and nothing else — any other value is a 400, not a commit — and the answer echoes `dryRun` so a caller can tell the two apart.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)

Forespørselskropp *

Svar

StatusInnhold
200application/json — AllocationResultDto
400–
401–
403–
409–

/assets/v2/site/tags/runs/{id}/allocations/release

POSTReturn a range to the unallocated pool

The reversal for an allocation to the wrong organization. Same range forms as the allocation. Refused if any tag in the range has been claimed, or is allocated to a different organization than the one given. All-or-nothing.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)

Forespørselskropp *

Svar

StatusInnhold
200application/json — AllocationResultDto
400–
401–
403–
409–

/assets/v2/site/tags/runs/{id}/void

POSTVoid a run whose labels were lost or misprinted

Unclaimed tags become unclaimable and unallocatable. Already-claimed tags are unaffected — they are on objects in use. Idempotent.

Parametre

NavnITypeBeskrivelse
id *pathinteger (int64)

Svar

StatusInnhold
200application/json — TagPrintRunDto
401–
403–

/assets/v2/site/tags/{tag}

GETWhere a single code lives

Which run, which organization, whether claimed, whether voided — the answer to "this code doesn't work". Carries no asset content.

Parametre

NavnITypeBeskrivelse
tag *pathstring

Svar

StatusInnhold
401–
403–
404–

Tag Resource

/assets/v2/tag/{tag}

GETReturn information about the asset associated with the tag. For non-owners, only public information is returned. If tag/id is from an external system, set the name of that system in the `externalSystem` query param.

Parametre

NavnITypeBeskrivelse
tag *pathstring
externalSystemquerystring
Accept-Languageheaderstring

Svar

StatusInnhold
200application/json — AssetDto
text/html

Warranty Resource

/assets/v2/warranty

POSTAdds a warranty on an asset. Either assetId or batchId must be set. duration (one of the WarrantyPeriod values) is required. granted optionally backdates the start date (not in the future); defaults to now. expiration = granted + duration's period.

Parametre

NavnITypeBeskrivelse
X-auth-ownerheaderstring

Forespørselskropp *

Svar

StatusInnhold
204–
400–
401–
403–

Skjemaer

AllocateRangeDto

Request to allocate a range of a run to one organization. Give either toTag or count, not both.

FeltTypeBeskrivelse
countinteger (int32)How many tags to take, starting at fromTag.
fromTag *stringFirst code of the range, as typed or scanned.
organizationId *stringSlug of the receiving organization. Shape is checked here; existence is not, because organizations live in sirk-orgadmin-backend and this service holds no registry of them. A mistyped-but-well-formed slug is reversed with POST /site/tags/runs/{id}/allocations/release.
toTagstringLast code of the range, inclusive.

AllocationDto

One shipment: a slice of a run allocated to one organization.

FeltTypeBeskrivelse
allocatedAtLocalDateTime
countinteger (int64)
fromTagstring
organizationIdstring
toTagstring

AllocationResultDto

What an allocation resolved to. The resolved end code lets an operator check the result against the physical stack, which matters most for the count form where it is not known up front.

FeltTypeBeskrivelse
alreadyAllocatedbooleanTrue when this allocation was already in place and nothing changed. Operators re-scan; that is not an error.
countinteger (int64)
dryRunbooleanTrue when this was a `?dryRun=true` preview and nothing was written. A client asking for a preview must check it: an unrecognised query parameter is ignored rather than rejected, so against a backend that has not shipped the flag a 200 is indistinguishable from a preview while having shipped the range for real. False on every committing path.
fromTagstring
organizationIdstring
skippedliste av stringCodes inside the range that exist but are not part of it — they belong to another run, or to no run at all — and were skipped. Ids are near-contiguous, not contiguous.
toTagstring

AskingPriceDto

FeltTypeBeskrivelse
amountnumber
currencystring
onRequestboolean

AssetBasicDto

FeltTypeBeskrivelse
askingPriceAskingPriceDto
categoryIdsliste av integer (int64)
deletedboolean
holderOwnerDto
holderSinceLocalDateTime
idinteger (int64)
listingStatusListingStatusÉn av: AVAILABLE, RESERVED, UNLISTED
locationCategoryIdinteger (int64)
namestring
quantityinteger (int32)
stateAssetStateÉn av: PROVISIONED, COMMISSIONED, STORED, SERVICE, TRANSPORT, DISCARDED
tagstring
thumbnailsliste av DocumentDto
warrantyExpirationLocalDateTime

AssetDto

FeltTypeBeskrivelse
batchesliste av BatchDto
categoryIdsliste av integer (int64)
descriptionstring
documentsliste av DocumentDto
eventsliste av EventDto
externalIdsliste av ExternalIdDto
holderOwnerDto
holderSinceLocalDateTime
idinteger (int64)
listingListingDto
locationCategoryIdinteger (int64)
name *string
organizationOwnerDto
ownerOwnerDto
propertiesmap av string
publicDppboolean
quantityinteger (int32)
stateAssetStateÉn av: PROVISIONED, COMMISSIONED, STORED, SERVICE, TRANSPORT, DISCARDED
tagstring
thumbnailsliste av DocumentDto
warrantyWarrantyDto

AssetEventResult

Én av: OK, DEVIATION

AssetEventType

Én av: INSPECTION, MAINTENANCE, REPAIR, INCIDENT, NOTE, MOVEMENT, SERVICE, PRODUCTION

AssetGroupBy

Én av: CATEGORY, LOCATION, STATE

AssetGroupDto

FeltTypeBeskrivelse
countinteger (int64)
idinteger (int64)
statestring

AssetMultiEditDto

FeltTypeBeskrivelse
assetIds *liste av integer (int64)
categoryIdsliste av integer (int64)
deleteFieldsliste av string
deleteFieldsSupportedboolean
locationCategoryIdinteger (int64)
notMixingSetAndClearboolean
publicDppboolean
recipientOrgIdstring
stateAssetStateÉn av: PROVISIONED, COMMISSIONED, STORED, SERVICE, TRANSPORT, DISCARDED
stateNotProvisionedboolean
transferboolean
transferExclusiveboolean

AssetSearchRequestDto

FeltTypeBeskrivelse
batchIdinteger (int64)
categoryIdsliste av integer (int64)
listingStatusesliste av ListingStatus
locationCategoryIdsliste av integer (int64)
pageOffsetinteger (int32)
pageSizeinteger (int32)
searchstring
statesliste av AssetState

AssetState

Én av: PROVISIONED, COMMISSIONED, STORED, SERVICE, TRANSPORT, DISCARDED

AssetStatisticsDto

FeltTypeBeskrivelse
activeAssetCountinteger (int64)
eventCountinteger (int64)
eventsPerMonth *map av integer (int64)
newAssetsPerMonth *map av integer (int64)
organizationId *string
organizationNamestring

BatchDto

FeltTypeBeskrivelse
categoryIdsliste av integer (int64)
countinteger (int64)
descriptionstring
guidstring
idinteger (int64)
namestring
ownerOwnerDto
propertiesmap av string
stateBatchStateÉn av: PLANNED, IN_PROGRESS, COMPLETED, CANCELLED
tagstring
timestampLocalDateTime
typeBatchTypeÉn av: ASSET_CREATION, REGISTRATION, TRANSPORT, SERVICE, COUNT, CONTROL_ROUND, OTHER

BatchMultiEditDto

FeltTypeBeskrivelse
categoryIdsliste av integer (int64)
deleteFieldsliste av string
deleteFieldsSupportedboolean
locationCategoryIdinteger (int64)
notMixingSetAndClearboolean
stateAssetStateÉn av: PROVISIONED, COMMISSIONED, STORED, SERVICE, TRANSPORT, DISCARDED
stateNotProvisionedboolean
validboolean

BatchState

Én av: PLANNED, IN_PROGRESS, COMPLETED, CANCELLED

BatchType

Én av: ASSET_CREATION, REGISTRATION, TRANSPORT, SERVICE, COUNT, CONTROL_ROUND, OTHER

CategoryMatch

Én av: EXACT, DESCENDANTS

ChecklistItemResultDto

FeltTypeBeskrivelse
answeredAtInstant
answeredBystring
documentIdsliste av integer (int64)
keystring
notestring
resolutionChecklistResolutionDto
resultChecklistOutcomeÉn av: OK, DEVIATION, NOT_APPLICABLE

ChecklistOutcome

Én av: OK, DEVIATION, NOT_APPLICABLE

ChecklistResolutionDto

object

ChecklistResponseType

Én av: CHECK

ChecklistResultDto

FeltTypeBeskrivelse
itemsliste av ChecklistItemResultDto
templateChecklistTemplateDto
version *integer (int32)

ChecklistTemplateDto

FeltTypeBeskrivelse
itemsliste av ChecklistTemplateItemDto
version *integer (int32)

ChecklistTemplateItemDto

FeltTypeBeskrivelse
guidancestring
keystring
requiredboolean
responseType *ChecklistResponseTypeÉn av: CHECK
textstring

ClaimStatus

What the current organization may do with a printed code.

Én av: CLAIMABLE, CLAIMED, UNAVAILABLE

ClaimStatusDto

FeltTypeBeskrivelse
assetIdinteger (int64)
statusClaimStatusWhat the current organization may do with a printed code. Én av: CLAIMABLE, CLAIMED, UNAVAILABLE
tagstring

CloseDeviationDto

FeltTypeBeskrivelse
notestring

ConsecutiveAssetsDto

FeltTypeBeskrivelse
assetId *integer (int64)
countinteger (int32)

ConsumeFromLotDto

FeltTypeBeskrivelse
notestring
quantity *integer (int32)
targetAssetId *integer (int64)

ConsumeResultDto

FeltTypeBeskrivelse
remainingQuantityinteger (int32)
sourceAssetIdinteger (int64)
sourceDeletedboolean
targetAssetIdinteger (int64)

CreateAssetDto

FeltTypeBeskrivelse
batchesliste av integer (int64)
categoryIdsliste av integer (int64)
descriptionstring
eventsliste av CreateAssetEventDto
externalIdsliste av ExternalIdDto
locationCategoryIdinteger (int64)
namestring
propertiesmap av string
publicDppboolean
quantityinteger (int32)

CreateAssetEventDto

FeltTypeBeskrivelse
batchGuidstring
checklistChecklistResultDto
co2eKgnumber (double)
co2eReferencestring
documentIdsliste av integer (int64)
locationstring
manualType *AssetEventTypeÉn av: INSPECTION, MAINTENANCE, REPAIR, INCIDENT, NOTE, MOVEMENT, SERVICE, PRODUCTION
notestring
occurredAtLocalDateTime
performedBystring
resultAssetEventResultÉn av: OK, DEVIATION

CreateBatchDto

FeltTypeBeskrivelse
assetIdsliste av integer (int64)
categoryIdsliste av integer (int64)
consecutiveAssetIdsConsecutiveAssetsDto
descriptionstring
guidstring
initialCountinteger (int64)
locationCategoryIdinteger (int64)
namestring
numberOfNewAssetsinteger (int32)
propertiesmap av string
stateBatchStateÉn av: PLANNED, IN_PROGRESS, COMPLETED, CANCELLED
typeBatchTypeÉn av: ASSET_CREATION, REGISTRATION, TRANSPORT, SERVICE, COUNT, CONTROL_ROUND, OTHER

CreateDeviationDto

FeltTypeBeskrivelse
assetId *integer (int64)
batchGuidstring
checkKeystring
description *string
documentIdsliste av integer (int64)

CreateReservationDto

FeltTypeBeskrivelse
forLabelstring
forOrganizationIdstring
from *LocalDateTime
reservationRefstring
until *LocalDateTime

DelistDto

FeltTypeBeskrivelse
settledPriceAskingPriceDto

DelistReason

Én av: WITHDRAWN, SOLD

DeviationDto

FeltTypeBeskrivelse
assetIdinteger (int64)
assetNamestring
batchGuidstring
batchNamestring
checkKeystring
closeNotestring
closedAtLocalDateTime
closedBystring
correctiveActionstring
createdAtLocalDateTime
createdBystring
descriptionstring
documentIdsliste av integer (int64)
dueDateLocalDate
idinteger (int64)
responsiblestring
stateDeviationStateÉn av: OPEN, CLOSED

DeviationState

Én av: OPEN, CLOSED

DocumentDto

FeltTypeBeskrivelse
documentTypeDocumentTypeÉn av: IMAGE, DOCUMENT, LINK, OTHER
idinteger (int64)
isPublicboolean
urlstring

DocumentType

Én av: IMAGE, DOCUMENT, LINK, OTHER

EventAction

Én av: CREATE, ACTIVATE, UPDATE, APPROVE, START, COMPLETE, WARRANTY, SERVICE, DELETE, REQUEST, TRANSFER, MANUAL, ALLOCATE, UNALLOCATE, CLAIM, UNCLAIM, VOID, LIST, DELIST, RESERVE, RELEASE, SOLD, CONSUME, INCORPORATE

EventDto

FeltTypeBeskrivelse
actionEventActionÉn av: CREATE, ACTIVATE, UPDATE, APPROVE, START, COMPLETE, WARRANTY, SERVICE, DELETE, REQUEST, TRANSFER, MANUAL, ALLOCATE, UNALLOCATE, CLAIM, UNCLAIM, VOID, LIST, DELIST, RESERVE, RELEASE, SOLD, CONSUME, INCORPORATE
idinteger (int64)
propertiesmap av string
timestampLocalDateTime
typeEventTypeÉn av: ASSET, BATCH, ORDER, LOCATION, USER, DEVIATION, TAG
userstring

EventType

Én av: ASSET, BATCH, ORDER, LOCATION, USER, DEVIATION, TAG

ExternalIdDto

FeltTypeBeskrivelse
id *string
systemName *string
urlStringFormatstring

GeoJsonPoint

FeltTypeBeskrivelse
coordinatesliste av number (double)
typestring

GrantWarrantyDto

FeltTypeBeskrivelse
assetIdinteger (int64)
batchIdinteger (int64)
duration *WarrantyPeriodÉn av: ONE_YEAR, TWO_YEARS, THREE_YEARS, FOUR_YEARS, FIVE_YEARS, TEN_YEARS
grantedLocalDateTime

Instant

string (date-time)

Language

Én av: ENGLISH, NORWEGIAN

ListingDto

FeltTypeBeskrivelse
askingPriceAskingPriceDto
channelsliste av string
idinteger (int64)
listedAtLocalDateTime
locationListingLocationDto
reservationReservationDto
statusListingStatusÉn av: AVAILABLE, RESERVED, UNLISTED
updatedAtLocalDateTime

ListingLocationDto

FeltTypeBeskrivelse
categoryIdinteger (int64)
latitudenumber (double)
longitudenumber (double)
namestring

ListingStatus

Én av: AVAILABLE, RESERVED, UNLISTED

LocalDate

string (date)

LocalDateTime

string (date-time)

MarketplaceListingDto

FeltTypeBeskrivelse
assetIdinteger (int64)
categoryIdsliste av integer (int64)
descriptionstring
imagesliste av string
listedAtLocalDateTime
listingIdinteger (int64)
locationMarketplaceLocationDto
namestring
organizationIdstring
organizationNamestring
passportUrlstring
priceAskingPriceDto
propertiesmap av string
quantityinteger (int32)
reservedUntilLocalDateTime
statusListingStatusÉn av: AVAILABLE, RESERVED, UNLISTED
tagstring
thumbnailsliste av string

MarketplaceLocationDto

FeltTypeBeskrivelse
categoryIdinteger (int64)
namestring
pointGeoJsonPoint

MintRunDto

Request to mint a new print run.

FeltTypeBeskrivelse
namestringOperator-facing name for the run, e.g. "Autumn 2026 stock".
notesstring
quantityinteger (int32)How many tags to mint. Between 1 and 5000 inclusive.

MonthRange

Inclusive YYYY-MM month window

FeltTypeBeskrivelse
fromYearMonth
toYearMonth

OwnerDto

FeltTypeBeskrivelse
idstring
namestring

PdfFormat

Én av: A4_3X8_66MM, A4_3X8_70MM, A4_2X5_80MM, STRIP_1X1_40MM, A4_5X8_30MM, A4_5X8_30MM_CLEAN

ReservationDto

FeltTypeBeskrivelse
forLabelstring
forOrganizationIdstring
fromLocalDateTime
reservationRefstring
sourceReservationSourceÉn av: MANUAL, ORDER
untilLocalDateTime

ReservationSource

Én av: MANUAL, ORDER

SiteStatisticsDto

Usage statistics for one organization

FeltTypeBeskrivelse
handledmap av map av integer (int64)Objects handled per calendar month (UTC), by object type
organizationIdstringOrganization slug
storedmap av integer (int64)Current inventory counts by object type

StreamingOutput

object

TagLookupDto

Where a single code lives. Support-facing; carries no asset content.

FeltTypeBeskrivelse
allocatedAtLocalDateTime
allocatedOrgstring
belongsToPrintRunbooleanFalse for a tag created by asset or batch creation.
claimedboolean
claimedAtLocalDateTime
printRunIdinteger (int64)
printRunNamestring
runVoidedboolean
tagstring

TagPrintRunDto

A print run with its current counts.

FeltTypeBeskrivelse
allocatedinteger (int64)Tags shipped to an organization. Includes the claimed ones.
allocationsliste av AllocationDto
claimedinteger (int64)
createdAtLocalDateTime
createdBystring
firstTagstringFirst code of the run in printed order; null for an empty run.
idinteger (int64)
lastTagstring
namestring
notesstring
quantityinteger (int32)
totalinteger (int64)Tag rows actually in the run. Equals quantity unless a mint was interrupted.
unallocatedinteger (int64)Tags not yet shipped to any organization.
voidedboolean
voidedAtLocalDateTime

UpdateAssetDto

FeltTypeBeskrivelse
addBatchesliste av integer (int64)
batchesliste av integer (int64)
batchesUnambiguousboolean
categoryIdsliste av integer (int64)
deleteFieldsliste av string
descriptionstring
documentIdsliste av integer (int64)
eventsliste av CreateAssetEventDto
externalIdsliste av ExternalIdDto
holderLabelstring
holderOrgstring
holderSinceLocalDateTime
locationCategoryIdinteger (int64)
namestring
ownerLabelstring
ownerOrgstring
propertiesmap av string
publicDppboolean
quantityinteger (int32)
quantityReasonstring
stateAssetStateÉn av: PROVISIONED, COMMISSIONED, STORED, SERVICE, TRANSPORT, DISCARDED
stateNotProvisionedboolean

UpdateBatchDto

FeltTypeBeskrivelse
assetIdsliste av integer (int64)
categoryIdsliste av integer (int64)
countinteger (int64)
deleteFieldsliste av string
descriptionstring
guidstring
locationCategoryIdinteger (int64)
namestring
stateBatchStateÉn av: PLANNED, IN_PROGRESS, COMPLETED, CANCELLED
typeBatchTypeÉn av: ASSET_CREATION, REGISTRATION, TRANSPORT, SERVICE, COUNT, CONTROL_ROUND, OTHER

UpdateDeviationDto

FeltTypeBeskrivelse
correctiveActionstring
dueDateLocalDate
responsiblestring

UpdateDocumentDto

FeltTypeBeskrivelse
isPublic *boolean

UpsertListingDto

FeltTypeBeskrivelse
askingPriceAskingPriceDto
channelsliste av string
deleteFieldsliste av string
deleteFieldsSupportedboolean
locationListingLocationDto
notMixingSetAndClearboolean

UserPreferencesDto

FeltTypeBeskrivelse
languageLanguageÉn av: ENGLISH, NORWEGIAN

WarrantyDto

FeltTypeBeskrivelse
expirationLocalDateTime
grantedLocalDateTime
grantedByOrganizationstring
grantedByUserIdstring
idinteger (int64)

WarrantyPeriod

Én av: ONE_YEAR, TWO_YEARS, THREE_YEARS, FOUR_YEARS, FIVE_YEARS, TEN_YEARS

YearMonth

FeltTypeBeskrivelse
leapYearboolean
monthinteger (int32)
monthValueinteger (int32)
prolepticMonthinteger (int64)
yearinteger (int32)