Skip to content

Make your first request

Use GET /user as a read-only connectivity check.

GET/userReturn the current account
Terminal window
curl --fail-with-body \
"https://api.ltesocks.io/v2/user" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${LTESOCKS_API_TOKEN}"

A successful response is a JSON user object. Exact fields are listed in the API reference.

Check these conditions before continuing:

  1. DNS and TLS connect to api.ltesocks.io.
  2. The response status is in the 2xx range.
  3. The response Content-Type is JSON.
  4. The returned account is the account you intended to automate.
  5. Logs do not contain the bearer token.

Do not hard-code plan, server, or signature identifiers from examples. Request current values:

Terminal window
curl "https://api.ltesocks.io/v2/plans" \
-H "Authorization: Bearer ${LTESOCKS_API_TOKEN}"
curl "https://api.ltesocks.io/v2/servers" \
-H "Authorization: Bearer ${LTESOCKS_API_TOKEN}"
curl "https://api.ltesocks.io/v2/signatures" \
-H "Authorization: Bearer ${LTESOCKS_API_TOKEN}"

Then follow Order a mobile port.