← Back to the chapter · Previous detail · Next detail →
Technical detail · CoAP API Design: Delivery and Security Decisions
CoAP limiter fields and calculation assumptions
A CoAP rate limiter bounds accepted requests, while a radio-charge model estimates selected communication costs.
An example limiter allows 10 requests/minute. A rejected request can receive 4.29 Too Many Requests with a Max-Age backoff interval. Its RATE_LIMIT_EXCEEDED error key and retry_after = 45 are application payload fields, not standard CoAP option names. Keep their retry advice consistent.
11.7.2 Interactive Rate Limit Analysis
A token-bucket calculator displays a sustained rate from requests divided by the time window, but uses a separate refill control for its token timeline, which models permission tokens consumed by requests and replenished over time. Changing the window alone does not change that timeline. Compare its assumptions before implementing and testing one consistent limiter.
11.7.3 Interactive Battery Life Optimizer

Animation · step by step
What the ACK Costs Over a Year
What the ACK Costs Over a Year
A battery calculation that models radio receive windows is also illustrative. Removing an assumed acknowledgement (ACK) receive window reduces modeled radio charge; the model omits retransmissions, security setup, sensor and processor work, and battery behavior. Measure the real device before selecting a battery or treating the estimate as a lifetime promise.