Bluestep JS Documentation
    Preparing search index...

    Interface GitMountSpec

    How a script names a repository to mount, for B.git.repo.open(spec) and for B.ai.agent({repos: [...]}). An internal repo names a purpose and a repo; an external one names a url and a credential.

    interface GitMountSpec {
        alias?: string;
        credential?: { field: SecretField };
        forge?: string;
        onNonText?: "include" | "skip" | "fail";
        pathPrefix?: string;
        purpose?: "script" | "general" | "component" | "marketplace";
        ref?: string;
        repo?: string;
        schema?: string;
        token?: string;
        url?: string;
        username?: string;
    }
    Index
    alias?: string

    Name the model uses for this mount. Required when mounting on an agent, since the model needs a handle; optional for a direct B.git.repo.open. Must start with a letter and hold only letters, digits, _ and -, up to 32 characters.

    credential?: { field: SecretField }

    Credential for an external repository, naming a Relate secret field: { field: entry.fields.githubPat }. The plaintext is read inside Java when a request header is built and never becomes a script value — do not read the secret yourself and pass token.

    forge?: string

    Forge dialect: "github", "gitlab", "forgejo", "gitea" or "bitbucket". Inferred from the host when omitted. It decides how a credential or token is presented — the same personal access token is a different header to each forge — so naming it is what makes a credential work rather than merely travel. Named forge rather than provider because provider already names the model vendor in the same options object.

    onNonText?: "include" | "skip" | "fail"

    What becomes of a file that is not UTF-8 text: "include" (listed, not searched, not readable — the default), "skip" (absent from the mount entirely), or "fail" (mount construction refuses, naming the first offender).

    pathPrefix?: string

    Expose only this subtree, e.g. "published/". Every path argument is checked against it, and history operations are narrowed by it even when no path is given.

    purpose?: "script" | "general" | "component" | "marketplace"

    What an in-cluster repository is for: "script", "general", "component", or "marketplace". The organization is derived from the calling user's tenant and is never supplied. Omit for an external repository.

    ref?: string

    Branch, tag, or commit sha to mount. Resolved to a commit sha once, when the mount is built; every later read uses that sha, so results stay reproducible and a concurrent publish cannot shift the ground mid-run. Defaults to "master".

    repo?: string

    Repository name within the derived organization, e.g. "100001___200002" for a script repo. Required with purpose.

    schema?: string

    Mount into another tenant's organization. Settable only by a global administrator holding the GIT_FULL endorsement; it widens which organization may be named and never which repositories within it, so each repo's own permission still applies.

    token?: string

    A literal token, for a fleet-level credential that is not a Relate secret field. Prefer credential: a token written as a string literal in script source is published into the tenant's script repository, which is the worst place for it.

    url?: string

    URL of an external repository, e.g. "https://github.com/owner/repo". Omit for an in-cluster repository.

    username?: string

    Username, where the forge expects a username and password pair rather than a bare token.