The SDK's prescription typings lag the API contract in three places:
activities.calculatePrescription is typed Promise<NutritionCalculateResponse>. The tier, teaser and trial fields match, but full-tier exact values now live under .prescription.
activities.getPrescription returns a {prescription, safety} wrapper, not a bare NutritionCalculateResponse.
- The activity import response now carries
prescriptions[] (one tier-aware envelope per item) and the request accepts calculate flags, globally and per activity. Batch endpoints debit rate limits per work item, which the client docs should say.
Definition of done: a typed PrescriptionEnvelope, the corrected getPrescription return type, import-time calculate support, and a contract test against the sandbox environment so the typings cannot drift silently.
Until this lands, the curl examples in the quickstart are the reference for these shapes.
The SDK's prescription typings lag the API contract in three places:
activities.calculatePrescriptionis typedPromise<NutritionCalculateResponse>. The tier, teaser and trial fields match, but full-tier exact values now live under.prescription.activities.getPrescriptionreturns a{prescription, safety}wrapper, not a bareNutritionCalculateResponse.prescriptions[](one tier-aware envelope per item) and the request acceptscalculateflags, globally and per activity. Batch endpoints debit rate limits per work item, which the client docs should say.Definition of done: a typed
PrescriptionEnvelope, the correctedgetPrescriptionreturn type, import-time calculate support, and a contract test against the sandbox environment so the typings cannot drift silently.Until this lands, the curl examples in the quickstart are the reference for these shapes.