# 20153: Invalid Issuer Or Subject

Log Type: TWILIO

Log Level: ERROR

## Description

This error occurs when the issuer or subject of the JSON Web Token provided to the Twilio API is invalid.

For Public Key Client Validation, the `iss` claim must be an API Key SID and the `sub` claim must be the Account SID.

### Possible causes

* The `iss` claim is missing.
* The issuer entity (API Key) is suspended in Twilio.
* The `sub` claim is missing.
* The subject entity (account) is suspended in Twilio.
* The API Key SID in `iss` is not associated with the Account SID in `sub`.

### Possible solutions

* If using Public Key Client Validation, ensure the account and the API key are valid and not suspended.
* Verify that both `iss` and `sub` claims are present and correctly set: API Key SID in `iss` and Account SID in `sub`.
* Confirm that the API Key used to sign the token is associated with the specified account.
* If needed, validate that the token is structurally sound using standard JWT tooling.

#### Additional resources

* [Public Key Client Validation Quickstart](/docs/iam/pkcv/quickstart)
* [Get Started with Public Key Client Validation](/docs/iam/pkcv)
* [REST API: Credentials](/docs/iam/credentials/api)
