MyanLex
SDKs and examples

HTTP examples

Call MyanLex with curl, JavaScript or Python. No SDK required.

Set MYANLEX_API_KEY and MYANLEX_API_URL in your server environment. The base URL must include /v1 and use HTTPS outside local development. These examples do not follow redirects or retry automatically. They print only their own sample text; do not turn this into automatic logging of private submissions.

printf 'Authorization: Bearer %s\n' "$MYANLEX_API_KEY" |
  curl --silent --show-error --fail-with-body --max-time 30 \
  --header @- --header 'Content-Type: application/json' \
  --data '{"text":"α€€πŸ˜€"}' "$MYANLEX_API_URL/syllabify"