openagents_sdk::issues
Issue claims linked to account runs, and GitHub project board status.
| Item | What it does |
|---|---|
BoardStatus enum | The status to set on each of an issue's GitHub projects. |
Claim struct | A GitHub issue's latest unreleased claim. |
ClaimRequest struct | Options for taking an issue claim. |
Issues struct | Issue coordination using the signed-in account's GitHub connection. |
BoardStatus
pub enum BoardStatus {
Ready,
InProgress,
Blocked,
Done,
}
The status to set on each of an issue's GitHub projects.
Claim
pub struct Claim {
pub repo: String,
pub issue: u64,
pub holder: String,
pub run: Option<String>,
pub claimed_at: i64,
pub last_progress_at: Option<i64>,
}
A GitHub issue's latest unreleased claim.
ClaimRequest
pub struct ClaimRequest {
pub holder: String,
pub run: Option<String>,
pub batch: Vec<u64>,
pub force: bool,
}
Options for taking an issue claim. A chat holds one issue or an explicit batch of at most three.
ClaimRequest::valid_for
pub fn valid_for(&self, issue: u64) -> bool
Checks identifiers and the named batch before sending an issue claim.
Issues
pub struct Issues<'a> {}
Issue coordination using the signed-in account's GitHub connection.
Issues::claims
pub async fn claims(
&self,
repo: &str,
cancel: &CancellationToken,
) -> Result<Vec<Claim>, Error>
Read the repository's unreleased claims and join them to this account's run progress.
Issues::claim
pub async fn claim(
&self,
repo: &str,
issue: u64,
holder: &str,
cancel: &CancellationToken,
) -> Result<Claim, Error>
Claim an issue for a holder with one matching live run. Use claim_with to name a run or batch.
Issues::claim_with
pub async fn claim_with(
&self,
repo: &str,
issue: u64,
request: &ClaimRequest,
cancel: &CancellationToken,
) -> Result<Claim, Error>
Claim an issue for a live run, optionally naming a batch or replacing another holder. An exact retry keeps the existing claim. Force never bypasses the batch limit.
Issues::release
pub async fn release(
&self,
repo: &str,
issue: u64,
note: Option<&str>,
cancel: &CancellationToken,
) -> Result<(), Error>
Release an issue claim, remove the GitHub assignee, and move its projects to Ready or Todo.
Issues::board
pub async fn board(
&self,
repo: &str,
issue: u64,
status: BoardStatus,
cancel: &CancellationToken,
) -> Result<(), Error>
Set each project's Status option. This does not close the GitHub issue.