Invite someone to a workspace
Invites an email address to join the workspace as athlete or coach. If the email already has a pending invitation in the workspace, its expiry is extended by two days and the existing code is returned instead of creating a new invitation. Set sendInvitationEmail to true to have Vekta email the code to the invitee. Requests to this endpoint are only counted against the per api key rate limit. Responds with 404 if the workspace does not exist or you are not one of its admins or coaches.
Authorization
bearer Vekta api key, e.g. Authorization: Bearer vk_...
In: header
Path Parameters
Id of a workspace where you are admin or coach (see the workspaces field of GET /users/me)
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Email address of the person to invite
email"athlete" | "coach"When true, Vekta emails the invitation code to the invitee. Defaults to false.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/workspaces/wke_01JGXW3KQ2B8C4D5E6F7G8H9J0/invitations" \ -H "Content-Type: application/json" \ -d '{ "email": "athlete@example.com", "role": "athlete" }'{ "id": "win_01JK4W2N9XQ3F5H7B8C6D2E9GT", "email": "athlete@example.com", "role": "athlete", "code": "7XK2QW", "expiresAt": "2026-08-28T09:30:00.000Z"}