Source-Backed Research

Исследование с проверкой источников: Backpack API Ed25519 Batch

5 мин

Текст статьи показан в проверенном английском оригинале. Перевод будет добавлен после проверки источников.

Verified Fact Boundary

1. Backpack's API documentation says endpoints that mutate state require signed requests using an ED25519 keypair unless documented otherwise. 2. Backpack signed requests include X-Timestamp, X-Window, X-API-Key and X-Signature headers, with the default window documented as 5000 milliseconds and a maximum of 60000 milliseconds. 3. Backpack documents instruction-prefixed signing strings for order execution and cancel workflows, including batch order execution. 4. Backpack's order query and cancel documentation says one of orderId or clientId should be specified and warns that orderId takes precedence when both are provided. 5. Backpack's API-key support page says API key creation is web-only and the Read Only button restricts a key to view-only access. 6. The safe readiness record separates key custody, request signing, time window, batch item identity, cancel evidence, accepted-but-not-executed states and non-secret reconciliation logs.

Свернуть

Decision Matrix

Таблица статьи: прокрутите по горизонтали или установите фокус на области таблицы и используйте клавиши со стрелками.

CheckWhat it meansPractical actionUnknown to keep explicit
Key scopeAPI keys can be created and permissioned before code sends orderscreate the minimum needed key and record whether it is read-onlywhether sub-account selection matches the intended trading account
Signing stringinstruction-specific canonical strings determine whether a request is acceptedunit-test the exact ordered parameters and header fieldswhether a library silently reorders or omits a parameter
Timestamp windowsigned requests are valid only within a bounded time windowmonitor local clock drift and reject stale submissions locallywhether network delay pushes a request outside the window
Batch mappingbatch order execution contains multiple item-level intentspersist each item, clientId and expected response separatelywhich item should be retried after a partial failure
Cancel evidenceorderId and clientId have precedence rules during query or canceluse one identifier per lookup and reconcile final statewhether an accepted cancel is already executed
Non-secret loggingdebuggability must not expose secretslog instruction, timestamp, window, clientId and result class but never private key or signature seedwhether support evidence requires additional private account context

Source Map

  • Backpack Exchange: Backpack Exchange API (backpack-api)
  • Backpack Exchange Support: Generate API keys for Backpack Exchange (backpack-api-keys)
  • Backpack Exchange Support: API and developer docs FAQs (backpack-api-faq)

Control Notes

1. Key scope

Key scope is the point where public documentation must become an operating rule. In this package, it means API keys can be created and permissioned before code sends orders. The practical action is to create the minimum needed key and record whether it is read-only. The unresolved edge is whether sub-account selection matches the intended trading account, so the article keeps that edge explicit instead of turning it into a reward claim, licensing claim, approval claim, safety guarantee, recovery promise, platform ranking or price implication.

2. Signing string

Signing string is the point where public documentation must become an operating rule. In this package, it means instruction-specific canonical strings determine whether a request is accepted. The practical action is to unit-test the exact ordered parameters and header fields. The unresolved edge is whether a library silently reorders or omits a parameter, so the article keeps that edge explicit instead of turning it into a reward claim, licensing claim, approval claim, safety guarantee, recovery promise, platform ranking or price implication.

The operating test is narrow.

3. Timestamp window

Timestamp window is the point where public documentation must become an operating rule. In this package, it means signed requests are valid only within a bounded time window. The practical action is to monitor local clock drift and reject stale submissions locally. The unresolved edge is whether network delay pushes a request outside the window, so the article keeps that edge explicit instead of turning it into a reward claim, licensing claim, approval claim, safety guarantee, recovery promise, platform ranking or price implication.

The operating test is narrow.

4. Batch mapping

Batch mapping is the point where public documentation must become an operating rule. In this package, it means batch order execution contains multiple item-level intents. The practical action is to persist each item, clientId and expected response separately. The unresolved edge is which item should be retried after a partial failure, so the article keeps that edge explicit instead of turning it into a reward claim, licensing claim, approval claim, safety guarantee, recovery promise, platform ranking or price implication.

The operating test is narrow.

5. Cancel evidence

Cancel evidence is the point where public documentation must become an operating rule. In this package, it means orderId and clientId have precedence rules during query or cancel. The practical action is to use one identifier per lookup and reconcile final state. The unresolved edge is whether an accepted cancel is already executed, so the article keeps that edge explicit instead of turning it into a reward claim, licensing claim, approval claim, safety guarantee, recovery promise, platform ranking or price implication.

The operating test is narrow.

6. Non-secret logging

Non-secret logging is the point where public documentation must become an operating rule. In this package, it means debuggability must not expose secrets. The practical action is to log instruction, timestamp, window, clientId and result class but never private key or signature seed. The unresolved edge is whether support evidence requires additional private account context, so the article keeps that edge explicit instead of turning it into a reward claim, licensing claim, approval claim, safety guarantee, recovery promise, platform ranking or price implication.

The operating test is narrow.

Known Unknowns

  • whether sub-account selection matches the intended trading account
  • whether a library silently reorders or omits a parameter
  • whether network delay pushes a request outside the window
  • which item should be retried after a partial failure
  • whether an accepted cancel is already executed
  • whether support evidence requires additional private account context

Practical Takeaway

Backpack Exchange API integration should be treated as a signed-order control workflow, not just a REST endpoint copy task. Backpack's official API documentation says mutating calls require ED25519 signing, timestamp and window headers, and instruction-specific signing strings. It also documents order execution, batch order execution, order query and cancel behavior, including clientId and orderId boundaries. The useful outcome is to test key creation, timestamp window, canonical signing string, batch-item mapping, cancel acknowledgement, 202 accepted states and non-secret logs before allowing automation to submit production orders. The article stops at the evidence boundary. It helps the reader decide what to inspect next without converting public documentation into a promise that a private account, wallet, API key, pool route, stablecoin balance, tokenized asset or policy framework will work under every future condition.

Источники

03
  1. Backpack ExchangeBackpack Exchange API · docs.backpack.exchange
  2. Backpack Exchange SupportGenerate API keys for Backpack Exchange · support.backpack.exchange
  3. Backpack Exchange SupportAPI and developer docs FAQs · support.backpack.exchange