Skip to main content

Simulate the recommender for a station

POST 

/recommendations

A read-only simulation: runs the same pure recommender that issues hints against the current open-task pool and the site's policy, and returns the ranked candidates. It issues no hint, publishes no event and changes no state. The origin is the station's recorded position, or fromLocation when given (a what-if). The site is the station's site, or the site of fromLocation. An empty candidates list means no hint would be issued. The site must have a declared policy (422 policy-not-declared otherwise) and the origin must have known geometry (422 origin-unknown). Requires an Idempotency-Key; replaying the same key and request within 24 hours returns the original answer with Idempotency-Replayed: true when that answer is final for the request: a 200, or a refusal that is a function of the request alone (400 malformed-request, invalid-station-id). A refusal that depends on state that can change (422 policy-not-declared, origin-unknown, station-position-unknown) and every 5xx is NOT stored: the key is released and the same request under the same key executes again. A copy that arrives while the original is still in flight answers the original's stored answer, never a refusal of its own.

Request​

Responses​

The ranked candidates; possibly empty.

Response Headers
    Idempotency-Replayed

    true when this response is the stored answer of an earlier request with the same Idempotency-Key and the same method, path and body (the handler did not run again): a success or a refusal that is final for the request. Absent on the first execution, and on the retry of a released key (a refusal that depends on changeable state is not stored).