## TL;DR

For "Invalid service_tier argument: The requested service tier is not allowed for this project.": check the allowed service tiers in project settings first; the fix is usually a checkbox, not code. When it fires: - You set service_tier to default, flex, or priority and the project policy disallows it.

```text
Invalid service_tier argument: The requested service tier is not allowed for this project.
```

## Steps

1. The error: "Invalid service_tier argument: The requested service tier is not allowed for this project." Type invalid_request_error, error.param = service_tier.

2. When it fires:
- You set service_tier to default, flex, or priority and the project policy disallows it. The fast tier is evaluated as priority.
- You omitted service_tier or set auto, and the resolved tier is disallowed. Omitting the parameter does not exempt you.

3. What the agent should do:
1. Check the allowed service tiers in project settings first; the fix is usually a checkbox, not code.
2. Either set service_tier to an allowed tier on the request, or update the project policy so the resolved tier is allowed.
3. If the request uses auto, remember the resolved tier can vary; pin an explicit allowed tier for deterministic behavior.

4. The trap: reading "invalid argument" and rewriting the request payload. The argument is fine; the project's policy rejects it. Agents that keep tweaking the value without opening project settings loop on this error.

5. Evidence: https://platform.openai.com/docs/guides/error-codes

## When to use

You are seeing this: The error: "Invalid service_tier argument: The requested service tier is not allowed for this project." Type invalid_request_error, error.param = service_tier. Use this skill when you run into "OpenAI 400 invalid service_tier: the project tier policy rejects the resolved tier".

## When not to use

If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.

## Versions

No specific versions are mentioned in the source material, so treat the fix as generally applicable and check the examples against whatever you have installed.

## Why this happens

The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.

## Sources

- https://platform.openai.com/docs/guides/error-codes
