IntelligenceX
Class

GitHubAppSettings

IntelligenceX.Telemetry.GitHub

Namespace
IntelligenceX.Telemetry.GitHub
Assembly
IntelligenceX
Modifiers
sealed

A GitHub App installation to sign in as instead of a user token. Its installation tokens have their own rate limit, separate from the user's. The private key stays in a local file named here; nothing in this record is a secret.

Inheritance

  • object
  • GitHubAppSettings

Usage

Explore 2 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Returned or exposed by 1

Accepted by parameters 1

Constructors

public GitHubAppSettings(long appId, long installationId, string privateKeyPath, string? apiBaseUrl = null, bool enabled = true) #

Creates settings for one App installation.

Parameters

appId long required
installationId long required
privateKeyPath string required
apiBaseUrl string? = null optional
enabled bool = true optional

Methods

public static string DefaultPath() #

The settings file: INTELLIGENCEX_GITHUB_APP when set, otherwise github-app.json in the local IntelligenceX folder.

Returns

string
public static GitHubAppSettings? Load(string? path = null) #

Reads the settings, or null when the file is missing, disabled or incomplete, so the user token stays in use.

Parameters

path string? = null optional

Properties

public long AppId { get; } #

The App's numeric ID.

public long InstallationId { get; } #

The installation's numeric ID on the account or organisation.

public string PrivateKeyPath { get; } #

Path to the App's private key (PEM).

public string ApiBaseUrl { get; } #

The REST API root; GitHub.com unless set.

public bool Enabled { get; } #

False keeps the file but signs in with the user token again.