Tokens API
Overviewโ
The Tokens API enables you to securely tokenize credit card information without handling sensitive card data on your servers. Tokens are single-use, encrypted references to card data that can be used to create charges.
What are Tokens?โ
Tokens are temporary, single-use representations of credit card information that:
- Expire after use - Each token can only be used once to create a charge or attach to a customer
- Protect card data - Your server never handles raw card details
- Enable PCI compliance - Reduces your PCI compliance scope significantly
- Validate immediately - Card details are validated during tokenization
Key Featuresโ
Security Firstโ
- Public key authentication - Use your public key (safe to expose in client-side code)
- Single-use tokens - Tokens cannot be reused after creating a charge
- No sensitive data storage - Card data never touches your servers
- PCI DSS compliant - Meets strictest security standards
Easy Integrationโ
- Client-side tokenization - Create tokens directly from browser/mobile app
- Omise.js library - Pre-built JavaScript library for easy integration
- Mobile SDKs - Native iOS and Android SDKs available
- Server-to-server - API available for server-side tokenization when needed
Flexibilityโ
- Works with all card types - Visa, Mastercard, JCB, etc.
- 3D Secure support - Automatic 3DS handling
- Card validation - Validates card number, CVV, expiration
- International support - Process cards from any country
How Tokens Workโ
Standard Flowโ
โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโ
โ Client โ โ Omise.jsโ โ Your โ โ Omise โ
โ Browser โ โ Library โ โ Server โ โ API โ
โโโโโโฌโโโโโ โโโโโโฌโโโโโ โโโโโโฌโโโโโ โโโโโโฌโโโโโ
โ โ โ โ
โ 1. Enter card โ โ โ
โโโโโโโโโโโโโโโโโโโ>โ โ โ
โ โ โ โ
โ โ 2. Create token โ โ
โ โ (with public key) โ
โ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ>