rivet
Version:
Suite of utilities for working with the Rivet consumer-driven API contacts testing model.
8 lines (7 loc) • 436 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.default = {
id: 'types.phone',
type: 'string',
pattern: '^(?:(?:\\+?1\\s*(?:[.-]\\s*)?)?(?:\\(\\s*([2-9]1[02-9]|[2-9][02-8]1|[2-9][02-8][02-9])\\s*\\)|([2-9]1[02-9]|[2-9][02-8]1|[2-9][02-8][02-9]))\\s*(?:[.-]\\s*)?)?([2-9]1[02-9]|[2-9][02-9]1|[2-9][02-9]{2})\\s*(?:[.-]\\s*)?([0-9]{4})(?:\\s*(?:#|x\\.?|ext\\.?|extension)\\s*(\\d+))?$'
};