GET /users/{user_jid}

Get user profile information by JID

Path parameters

  • user_jid string Required

Responses

  • 200 application/json

    User info retrieved successfully

    Hide response attributes Show response attributes object
    • status boolean
    • code integer
    • message string
    • data object
      Hide data attributes Show data attributes object
      • jid string
      • name string
      • status string
      • picture_url string
  • 401 application/json

    Unauthorized

    Hide response attributes Show response attributes object
    • status boolean
    • code integer
    • message string
    • error string
  • 404 application/json

    User not found

    Hide response attributes Show response attributes object
    • status boolean
    • code integer
    • message string
    • error string
  • 500 application/json

    Internal server error

    Hide response attributes Show response attributes object
    • status boolean
    • code integer
    • message string
    • error string
GET /users/{user_jid}
curl \
 --request GET 'http://localhost:7001/users/6281234567890@s.whatsapp.net' \
 --header "Authorization: $API_KEY"
Response examples (200)
{
  "code": 200,
  "data": {
    "jid": "6281234567890@s.whatsapp.net",
    "name": "John Doe",
    "status": "Hey there! I am using WhatsApp",
    "picture_url": "https://pps.whatsapp.net/v/t61.24694-24/..."
  },
  "status": true,
  "message": "User info retrieved successfully"
}
Response examples (200)
{
  "status": true,
  "code": 200,
  "message": "User info retrieved successfully",
  "data": {
    "jid": "6281234567890@s.whatsapp.net",
    "name": "John Doe",
    "status": "Hey there! I am using WhatsApp",
    "picture_url": "https://pps.whatsapp.net/v/..."
  }
}
Response examples (401)
{
  "code": 401,
  "error": "Invalid or expired JWT token",
  "status": false,
  "message": "Unauthorized"
}
Response examples (401)
{
  "status": false,
  "code": 401,
  "message": "Unauthorized",
  "error": "Invalid or missing authentication"
}
Response examples (404)
{
  "code": 404,
  "error": "User not found",
  "status": false,
  "message": "Not found"
}
Response examples (404)
{
  "status": false,
  "code": 404,
  "message": "Not found",
  "error": "Resource not found"
}
Response examples (500)
{
  "code": 500,
  "error": "Failed to retrieve user info",
  "status": false,
  "message": "Internal server error"
}
Response examples (500)
{
  "status": false,
  "code": 400,
  "message": "Bad request",
  "error": "Bad request"
}