{"slug": "i-stopped-hardcoding-model-ids-models-dev-v1-models-changed-the-workflow", "title": "I stopped hardcoding model IDs. models.dev + /v1/models changed the workflow", "summary": "DaoXE, a multi-model multi-protocol API gateway, has been listed on models.dev, enabling developers to discover and use model IDs from a public catalog before hardcoding them. The company recommends a workflow of checking the public catalog first, then the account-specific /v1/models endpoint, and finally testing with curl before configuring IDEs. This approach avoids common footguns like using outdated blog model IDs or marketing names that cause errors.", "body_md": "Disclosure and availability:DaoXE is a multi-model multi-protocol API gateway we operate. It is listed on models.dev as provider key`daoxe`\n\nwith`api=https://daoxe.com/v1`\n\nand env`DAOXE_API_KEY`\n\n. It is not available in mainland China. This article is for developers in regions allowed by the service terms.\n\nFor a long time my gateway setup notes looked like this:\n\n```\nbase_url = https://something/v1\nmodel    = gpt-4o-mini   # hope this still exists\n```\n\nThat pattern fails in three predictable ways:\n\nThis post is the discovery workflow I use now: public catalog first, account catalog second, client third.\n\nEarlier posts covered smoke tests, multiprotocol checks, client setup, and IDE failure isolation:\n\nThis one is about **where model IDs come from** before you paste them into an IDE.\n\n[models.dev](https://models.dev) is a public provider/model catalog many coding tools read.\n\nWhen a gateway lands there, clients that support custom / catalog-driven providers can resolve:\n\n| Field | Why it matters |\n|---|---|\n| provider key | stable id for configs (`daoxe` , not a marketing name) |\n`api` base |\nhost + `/v1` shape |\n| env var | which secret name tools expect |\n\nFor DaoXE the live catalog entry is effectively:\n\n```\nkey: daoxe\napi: https://daoxe.com/v1\nenv: DAOXE_API_KEY\n```\n\nThat is **public discovery**, not proof your account can call every model.\n\nPublic catalogs and account catalogs are different objects.\n\n```\nexport DAOXE_API_KEY=\"your_api_key\"\nexport DAOXE_BASE_URL=\"https://daoxe.com/v1\"\n\ncurl --fail-with-body --show-error --silent \\\n  -H \"Authorization: Bearer $DAOXE_API_KEY\" \\\n  \"$DAOXE_BASE_URL/models\"\n```\n\nI treat the response as **live data for this account only**:\n\n`id`\n\nIf `/models`\n\nreturns 401, stop blaming the IDE. Fix auth first.\n\n```\nexport DAOXE_MODEL=\"paste_exact_id_from_models_response\"\n\ncurl --fail-with-body --show-error --silent \\\n  -H \"Authorization: Bearer $DAOXE_API_KEY\" \\\n  -H \"Content-Type: application/json\" \\\n  -d \"{\n    \\\"model\\\": \\\"$DAOXE_MODEL\\\",\n    \\\"max_tokens\\\": 8,\n    \\\"messages\\\": [{\\\"role\\\":\\\"user\\\",\\\"content\\\":\\\"Reply with OK.\\\"}]\n  }\" \\\n  \"$DAOXE_BASE_URL/chat/completions\"\n```\n\nOnly after this returns HTTP 200 do I open Cline / Continue / Claude-shaped tools.\n\nThe only triple that should move between tools:\n\n| Piece | Example for DaoXE |\n|---|---|\n| Base URL | `https://daoxe.com/v1` |\n| API key storage | env / secret store (`DAOXE_API_KEY` or the client's custom key field) |\n| Model ID | exact id from `/v1/models` now\n|\n\nPublic setup notes:\n\n| Footgun | Symptom | Fix |\n|---|---|---|\n| Blog model ID | model_not_found | re-copy from `/v1/models`\n|\n| Marketing name as API id | client 400 | use catalog `id` , not label |\n| Public catalog only | \"listed but my key fails\" | public catalog ≠ account access |\n| Account catalog only | \"works for me, not for teammate\" | each account has its own list |\n| Skipping smoke | IDE red noise | curl first |\n\nSuccess is not \"every model on models.dev works for every key.\"\n\nSuccess is:\n\nIf you want the product side of this writeup:\n\n[https://daoxe.com/?utm_source=devto&utm_medium=organic&utm_campaign=global_launch_modelsdev](https://daoxe.com/?utm_source=devto&utm_medium=organic&utm_campaign=global_launch_modelsdev)\n\nIf something fails, comment with client name + whether `/v1/models`\n\nreturned 200 for your key. Do not paste API keys.\n\n`/models`\n\ndiscovery", "url": "https://wpnews.pro/news/i-stopped-hardcoding-model-ids-models-dev-v1-models-changed-the-workflow", "canonical_source": "https://dev.to/seven7763/i-stopped-hardcoding-model-ids-modelsdev-v1models-changed-the-workflow-4na2", "published_at": "2026-07-16 14:21:24+00:00", "updated_at": "2026-07-16 14:40:03.192128+00:00", "lang": "en", "topics": ["developer-tools", "ai-infrastructure", "ai-tools"], "entities": ["DaoXE", "models.dev"], "alternates": {"html": "https://wpnews.pro/news/i-stopped-hardcoding-model-ids-models-dev-v1-models-changed-the-workflow", "markdown": "https://wpnews.pro/news/i-stopped-hardcoding-model-ids-models-dev-v1-models-changed-the-workflow.md", "text": "https://wpnews.pro/news/i-stopped-hardcoding-model-ids-models-dev-v1-models-changed-the-workflow.txt", "jsonld": "https://wpnews.pro/news/i-stopped-hardcoding-model-ids-models-dev-v1-models-changed-the-workflow.jsonld"}}