Match Tax Lots SPECIFIC
tax_lot.match_specific
Overview
Apply SPECIFIC lot matching to one bounded opening inventory and ordered disposal batch while preserving lot and disposal identities, deterministic method order, and exact quantity conservation.
Identity, order, and quantity conservation are guaranteed for tax_lot.match_specific within one business step.
Reliability
For tax_lot.match_specific, TAX_LOT_INPUT_INVALID means an identifier, date, decimal, or closed shape is invalid; correct the batch. INSUFFICIENT_QUANTITY means eligible lots cannot fill a disposal; add quantity or reduce it. ITEM_LIMIT_EXCEEDED means lots, disposals, or matches exceed the published bound; split the business batch. Every failure is atomic.
Context footprint
One bounded call replaces per-disposal and per-lot agent loops. A successful call costs 1 execution credit.
When to use it
When you already name the exact lot identifiers and quantities each disposal must consume.
When allocations are unknown and the engine must choose lots by FIFO, LIFO, or highest cost.
Scope
Non-goals
- Does not persist lot state or execute trades.
- Does not infer tax jurisdiction or policy.
Properties
Capabilities
Cost & billing
Flat rate per invocation
File handling
How we handle your data
What this means
This skill may receive sensitive content, but it does not target sensitive data and returns only a structured non-sensitive result.
Squillify guarantees
- Runs inside Squillify
- This skill runs inside Squillify.
- Payloads are not sent to an external service by this skill.
- Squillify does not permanently store submitted payloads.
- Telemetry records metadata only, not submitted content.
- Submitted payloads are not used for training.
- Submitted payloads are not reviewed by humans.
- This skill does not target sensitive data.
- The response does not contain submitted content.
Your responsibility
Squillify does not determine whether submitted content is sensitive. Your application is responsible for deciding what data it is allowed to submit. Your application is responsible for securing the response.
Input schema
| Field | Type | Required | Description |
|---|---|---|---|
| openingLots | array | Yes | From 1 through 10,000 unique opening lots in stable input order. |
| disposals | array | Yes | From 1 through 1,000 unique disposals processed atomically in caller order. |
Output schema
| Field | Type | Required | Description |
|---|---|---|---|
| disposals | array | Yes | From 1 through 1,000 disposal receipts preserving input order. |
| remainingLots | array | Yes | From 0 through 10,000 positive residual lots in original opening-lot order. |
| matchCount | integer | Yes | Total number of emitted match rows. |
API contract
POST /v1/executecurl -sS -X POST "$BASE/v1/execute" -H "Authorization: Bearer $KEY" -H 'Content-Type: application/json' -d '{"skillKey":"tax_lot.match_specific","input":{"openingLots":[{"lotId":"L1","acquisitionDate":"2026-01-01","quantity":"10","unitCost":"5"},{"lotId":"L2","acquisitionDate":"2026-02-01","quantity":"10","unitCost":"7"}],"disposals":[{"disposalId":"D1","tradeDate":"2026-03-01","quantity":"12","allocations":[{"lotId":"L2","quantity":"10"},{"lotId":"L1","quantity":"2"}]}]}}'import { Squillify } from "@squillify/sdk";
const sq = new Squillify({ apiKey: process.env.SQUILLIFY_API_KEY });
const { output } = await sq.execute("tax_lot.match_specific", {"openingLots":[{"lotId":"L1","acquisitionDate":"2026-01-01","quantity":"10","unitCost":"5"},{"lotId":"L2","acquisitionDate":"2026-02-01","quantity":"10","unitCost":"7"}],"disposals":[{"disposalId":"D1","tradeDate":"2026-03-01","quantity":"12","allocations":[{"lotId":"L2","quantity":"10"},{"lotId":"L1","quantity":"2"}]}]});Errors
| Code | HTTP | Retryable | Description |
|---|---|---|---|
| VALIDATION_ERROR | 400 | No | The request payload failed schema validation. |
| UNAUTHORIZED | 401 | No | Missing or invalid API key. |
| SKILL_NOT_ACCESSIBLE | 403 | No | The API key is not granted access to this skill. |
| SKILL_NOT_AVAILABLE_FOR_PLAN | 403 | No | This skill is not included in your current plan. |
| PLAN_ELIGIBILITY_UNAVAILABLE | 503 | Yes | Plan eligibility could not be decided. Retry after backoff. |
| SKILL_NOT_FOUND | 404 | No | The requested skill or version does not exist. |
| TENANT_RATE_LIMITED | 429 | Yes | Request rate limit exceeded. Retry after backoff. |
| QUOTA_EXCEEDED | 429 | Yes | Plan quota exhausted. Retryable once the quota period resets. |
| EXECUTION_TIMEOUT | 504 | Yes | Execution exceeded the allowed time budget. |
| TAX_LOT_INPUT_INVALID | 400 | No | The request payload failed this skill's input validation. |
| INSUFFICIENT_QUANTITY | 400 | No | The request payload failed this skill's input validation. |
| ITEM_LIMIT_EXCEEDED | 429 | No | A size, quota, rate, or time limit was exceeded. |
Other limits
| Limit | Value |
|---|---|
| Recommended inline bytes | 32 KiB |
Limitations
- Does not persist lot state or execute trades.
- Does not infer tax jurisdiction or policy.
- Unbounded inventories or inferred disposal policy.
How to call
POST /v1/execute (requires authentication)
{
"skillKey": "tax_lot.match_specific",
"input": {
"openingLots": [
{
"lotId": "L1",
"acquisitionDate": "2026-01-01",
"quantity": "10",
"unitCost": "5"
},
{
"lotId": "L2",
"acquisitionDate": "2026-02-01",
"quantity": "10",
"unitCost": "7"
}
],
"disposals": [
{
"disposalId": "D1",
"tradeDate": "2026-03-01",
"quantity": "12",
"allocations": [
{
"lotId": "L2",
"quantity": "10"
},
{
"lotId": "L1",
"quantity": "2"
}
]
}
]
}
}Examples
Verified batch
{
"openingLots": [
{
"lotId": "L1",
"acquisitionDate": "2026-01-01",
"quantity": "10",
"unitCost": "5"
},
{
"lotId": "L2",
"acquisitionDate": "2026-02-01",
"quantity": "10",
"unitCost": "7"
}
],
"disposals": [
{
"disposalId": "D1",
"tradeDate": "2026-03-01",
"quantity": "12",
"allocations": [
{
"lotId": "L2",
"quantity": "10"
},
{
"lotId": "L1",
"quantity": "2"
}
]
}
]
}{
"disposals": [
{
"disposalId": "D1",
"requestedQuantity": "12",
"matches": [
{
"lotId": "L2",
"quantity": "10",
"unitCost": "7",
"acquisitionDate": "2026-02-01"
},
{
"lotId": "L1",
"quantity": "2",
"unitCost": "5",
"acquisitionDate": "2026-01-01"
}
]
}
],
"matchCount": 2,
"remainingLots": [
{
"lotId": "L1",
"acquisitionDate": "2026-01-01",
"quantity": "8",
"unitCost": "5"
}
]
}Repeated batch
{
"openingLots": [
{
"lotId": "L1",
"acquisitionDate": "2026-01-01",
"quantity": "10",
"unitCost": "5"
},
{
"lotId": "L2",
"acquisitionDate": "2026-02-01",
"quantity": "10",
"unitCost": "7"
}
],
"disposals": [
{
"disposalId": "D1",
"tradeDate": "2026-03-01",
"quantity": "12",
"allocations": [
{
"lotId": "L2",
"quantity": "10"
},
{
"lotId": "L1",
"quantity": "2"
}
]
}
]
}{
"disposals": [
{
"disposalId": "D1",
"requestedQuantity": "12",
"matches": [
{
"lotId": "L2",
"quantity": "10",
"unitCost": "7",
"acquisitionDate": "2026-02-01"
},
{
"lotId": "L1",
"quantity": "2",
"unitCost": "5",
"acquisitionDate": "2026-01-01"
}
]
}
],
"matchCount": 2,
"remainingLots": [
{
"lotId": "L1",
"acquisitionDate": "2026-01-01",
"quantity": "8",
"unitCost": "5"
}
]
}Recommended use cases
- Deterministic tax-lot allocation.
- Independent quantity-ledger verification.
Avoid for
- Unbounded inventories or inferred disposal policy.
Related skills
Composable with
Safety & privacy
- Runs without calling any external service.
- Your payloads are never stored permanently.
- Telemetry captures metadata only — never your payload contents.
- We never train models on your payloads.
- No human reviews your payloads.