Launching a SaaS?·Collect waitlist signups before you build — before.run
SandboxPatternsDetectDocsChangelog
Finance
#stripe
#api-key
#payment
#finance

Stripe API Key

Validates Stripe publishable and secret API keys in both live and test modes.

✓ Payment integration validation✓ Secrets scanning in CI/CD✓ Config file auditing
/
/
Safe
Test String
4 matches
(?:…)Non-capturing group— Non-capturing group — groups without capturing (no index assigned)
pp— 'p' — literal character
kk— 'k' — literal character
||— | — alternation: matches expression on left OR right
ss— 's' — literal character
kk— 'k' — literal character
||— | — alternation: matches expression on left OR right
rr— 'r' — literal character
kk— 'k' — literal character
__— '_' — literal character
(?:…)Non-capturing group— Non-capturing group — groups without capturing (no index assigned)
ll— 'l' — literal character
ii— 'i' — literal character
vv— 'v' — literal character
ee— 'e' — literal character
||— | — alternation: matches expression on left OR right
tt— 't' — literal character
ee— 'e' — literal character
ss— 's' — literal character
tt— 't' — literal character
__— '_' — literal character
[…]{20,99}Character class […]— Matches any single character listed in this set — repeated between 20 and 99 times · {20,99} — between 20 and 99 times
a-za-z— a-z — range from 'a' to 'z'
A-ZA-Z— A-Z — range from 'A' to 'Z'
0-90-9— 0-9 — range from '0' to '9'
Pattern: 45 charsInput: 177 chars
100% client-side · private

✓ Valid Examples

  • pk_test_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
  • sk_test_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
  • rk_test_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
  • pk_test_abcdefghijklmnopqrstuvwxyz01234567

✗ Invalid Examples

  • pk_staging_12345
  • api_key_abcdef123456
  • sk_test_short
  • pk_live_

Usage & Integration

Validate Stripe API Key natively in your backend or frontend without copying regex strings.

Node / Edge

import { validate } from '@regexto/validators';

validate('stripe-key', '...');

Python

from regexto_validators import validate

validate("stripe-key", "...")

Go

import "github.com/regex-to/validators-go"

valid, err := validators.Validate("stripe-key", "...")

PHP

use RegexTo\Validators\Validator;

Validator::validate('stripe-key', '...');

Rust

use regexto_validators::validate;

let is_valid = validate("stripe-key", "...").unwrap();