---
page_type: error
code: 52134
message: "52134: Invalid APNs device token"
level: ERROR
product: Notifications
---

## Error - 52134

### Invalid APNs device token

#### Possible Causes

- APNs device token format is invalid.
- Trying to use a development certificate for a production application or vice-versa.

#### Possible Solutions

- Make sure you do not modify the device token before providing it to Twilio. If using a command line tool make sure to url-encode the token.

- Make sure that you are using a development certificate for a development application and a production certificate for a production application.

  - If you are using a traditional certificate, you can tell its environment by looking at the common name field

    - For a development certificate, it will start with: Apple Development IOS Push Services
    - For a production certificate, it will start with: Apple Push Services

  - If you are using a universal certificate, you can use it for both development and production applications. However you have to make sure that you have properly indicated the type of application by setting the sandbox parameter when you create the credential. You can check the sandbox flag of your credential via the [REST API](/docs/api/ip-messaging/rest/credentials#action-get).