export function getRequiredScopes(id, securities) {
    const allScopes = new Set();
    securities.forEach(({ schemes }) => {
        schemes.forEach(({ id: schemeId, scopes }) => {
            if (schemeId === id) {
                scopes.forEach((scope) => allScopes.add(scope));
            }
        });
    });
    return Array.from(allScopes);
}
export function getOptionalScopes(requiredScopes, allScopes) {
    const requiredScopesSet = new Set(requiredScopes);
    return allScopes.filter((scope) => !requiredScopesSet.has(scope));
}
//# sourceMappingURL=helper.js.map