Live demo.

The real API, no token needed. Pick an operation, edit the patterns and compute.

Computes one pattern matching exactly the strings that both patterns accept.

RESULT

THE SAME CALL WITH THE SDK

import { RegexSolverClient, Term } from 'regexsolver';

const client = new RegexSolverClient({
  apiToken: process.env.REGEXSOLVER_API_TOKEN,
});

const term1 = Term.regex("/api/v[12]/.*");
const term2 = Term.regex(".*/users/[0-9]+");

console.log(await client.intersection(term1, term2));