"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.DockerAuthTokenCriteria = void 0;
class DockerAuthTokenCriteria {
    /**
     *
     * @param service The name of the service which hosts the resource.  eg:  "registry.docker.io"
     * @param scope TL;DR: Colon-delimited string in format:  "[scopeLevel]:[scopeName]:[actions]".  eg: "?scope=repository:letmeaskmydog/toyhauler-base:pull,push".
     *        The resource in question, formatted as one of the space-delimited entries from the scope parameters
     *        from the WWW-Authenticate header returned in an http 401 response.
     *        This query parameter should be specified multiple times if there is more than one scope entry
     *        from the WWW-Authenticate header.
     *        The scope field may be empty to request a refresh token without providing any resource permissions to the returned bearer token.
     *
     * @param offline_token Whether to return a refresh token along with the bearer token.
     *         A refresh token is capable of getting additional bearer tokens for the same subject with different scopes.
     *         The refresh token does not have an expiration and should be considered completely opaque to the client.
     * @param client_id String identifying the client. This client_id does not need to be registered with the authorization server
     *         but should be set to a meaningful value in order to allow auditing keys created by unregistered clients.
     *         Accepted syntax is defined in [RFC6749 Appendix A.1](https://tools.ietf.org/html/rfc6749#appendix-A.1).
     *
     * @see https://docs.docker.com/registry/spec/auth/token/#how-to-authenticate How to Authenticate
     * @see https://docs.docker.com/registry/spec/auth/token/#requesting-a-token Requesting a Token
     * @see https://docs.docker.com/registry/spec/auth/jwt/ Token Authentication Implementation
     * @see https://tools.ietf.org/html/rfc6750#section-3 Section 3 of RFC 6750: The OAuth 2.0 Authorization Framework: Bearer Token Usage
     * @see https://tools.ietf.org/html/rfc6749#appendix-A.1 RFC6749 Appendix A.1
     */
    constructor(service, scope, offline_token, client_id) {
        this.service = service;
        this.scope = scope;
        this.offline_token = offline_token;
        this.client_id = client_id;
    }
}
exports.DockerAuthTokenCriteria = DockerAuthTokenCriteria;
//# sourceMappingURL=docker-auth-token-criteria.js.map