Skip to main content
POST
/
external
/
v1
/
applications
/
magic-link
Magic Link
curl --request POST \
  --url https://api.example.com/external/v1/applications/magic-link/
Generate a one-time login link for a candidate. This allows candidates to access their application without needing to remember a password.

Endpoint

POST /external/v1/applications/magic-link/

Request Body

FieldTypeRequiredDescription
emailstringYesCandidate’s email address
application_idstring (UUID)NoSpecific application to link to

Example Request

curl -X POST "https://your-instance.firstwork.com/external/v1/applications/magic-link/" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "email": "john.doe@example.com",
    "application_id": "7c9e6679-7425-40de-944b-e07fc1f90ae7"
  }'

Example Response

{
  "status": "success",
  "data": {
    "magic_link": "https://app.firstwork.com/login?token=abc123def456...",
    "expires_at": "2025-01-21T10:30:00Z"
  }
}

Notes

  • Magic links expire after a configured period (default: 24 hours)
  • Each link can only be used once
  • The link logs the user in and redirects to their application
  • Useful for sending in SMS or email notifications