Skip to main content
GET
/
v1
/
assets
/
{serialNumber}
Get an asset
curl --request GET \
  --url https://api-eu.flexportal.io/v1/assets/{serialNumber} \
  --header 'Authorization: Bearer <token>' \
  --header 'Tenant-ID: <tenant-id>'
{
  "serialNumber": "<string>",
  "tenantId": "<string>",
  "sku": "<string>",
  "productName": "<string>",
  "status": "available",
  "createdAt": "<string>",
  "updatedAt": "<string>",
  "productId": "<string>",
  "productImageUrl": "<string>",
  "variantId": "<string>",
  "location": "<string>",
  "customerId": "<string>",
  "rentalId": "<string>",
  "notes": "<string>"
}

Overview

Retrieve details for a single asset by its serial number. Assets are identified by their unique serial number (not an auto-generated ID), making it easy to look up devices using manufacturer serial numbers or your own identifiers.

Common Use Cases

  • Warehouse Lookup: Scan a barcode/serial number to get asset details
  • Support Queries: Find asset info during customer support calls
  • Pre-Assignment Check: Verify asset details before creating a subscription
  • Audit Trail: Track asset history and current assignment

Response Fields

FieldDescription
serialNumberUnique asset identifier
skuProduct variant SKU
productNameProduct display name
statusavailable, rented_out, returned, sold, or unavailable
acquisitionCostYour cost to acquire
acquisitionDateWhen the asset was acquired
customerIdCurrent customer (if assigned)
rentalIdCurrent subscription ID (if assigned)
locationPhysical location
conditionAsset condition notes
notesAdditional notes
createdAtWhen asset was added to system
updatedAtLast modification timestamp

Asset Status Details

StatusMeaningTypical Scenario
availableReady for subscriptionIn warehouse, ready to ship
rented_outAssigned to subscriptionWith customer
unavailableNot availableDamaged, sold, retired, or in repair

Example: Warehouse Scan Lookup

async function handleBarcodeScan(serialNumber) {
  try {
    const asset = await getAsset(serialNumber);

    return {
      found: true,
      product: asset.productName,
      sku: asset.sku,
      status: asset.status,
      location: asset.location,
      canAssign: asset.status === 'available',
      currentCustomer: asset.customerId || null
    };
  } catch (error) {
    if (error.code === 'NOT_FOUND') {
      return { found: false, serialNumber };
    }
    throw error;
  }
}

Example: Check Before Assignment

async function canAssignToOrder(serialNumber, orderSku) {
  const asset = await getAsset(serialNumber);

  const issues = [];

  if (asset.status !== 'available') {
    issues.push(`Asset is ${asset.status}, not available`);
  }

  if (asset.sku !== orderSku) {
    issues.push(`SKU mismatch: asset is ${asset.sku}, order needs ${orderSku}`);
  }

  return {
    canAssign: issues.length === 0,
    issues
  };
}

Authorizations

Authorization
string
header
required

API key obtained from FlexPortal dashboard

Headers

Tenant-ID
string
required

Your tenant identifier

Path Parameters

serialNumber
string
required

The asset serial number

Response

Asset details

serialNumber
string
required
tenantId
string
required
sku
string
required
productName
string
required
status
enum<string>
required
Available options:
available,
rented_out,
returned,
sold,
unavailable
createdAt
string
required
updatedAt
string
required
productId
string
productImageUrl
string
variantId
string
location
string
customerId
string
rentalId
string
notes
string