Trainees

POST /api/public/trainees/{traineeId}/send-credentials

Changed on

Send the trainee their app access details by email, and optionally by WhatsApp. This generates a new password for the trainee and emails it to them, so it doubles as a password reset. Use it after creating a trainee, since POST /trainees does not send access details on its own. Set sendWhatsApp to true to also deliver the details over WhatsApp, which requires a connected WhatsApp account and a trainee phone number; the password follows in a separate message. Provide whatsappTemplate to override the message, using the {firstName}, {email}, {password} and {appLink} placeholders; when omitted the template saved in the dashboard is used.

Request

  • Base URL
    https://api.coach-platform.com
  • Auth
    HTTP bearer

Path parameters

traineeIdstring required

Headers

Idempotency-Keystring

Optional. Send a unique key (e.g. a UUID) to make this POST safe to retry. The same key within 24h returns the original result instead of creating a duplicate.

Request body

sendWhatsAppboolean
whatsappTemplatestring

Response

Successful response

Changes

    • breaking

      added required request body

    • info

      added the optional property / to the response with the status