Provides GiteaClient class with methods for repos, orgs, secrets, and action runs.
31 lines
595 B
Markdown
31 lines
595 B
Markdown
# @apiclient.xyz/gitea
|
|
|
|
A TypeScript client for the Gitea API, providing easy access to repositories, organizations, secrets, and action runs.
|
|
|
|
## Install
|
|
|
|
```sh
|
|
npm install @apiclient.xyz/gitea
|
|
```
|
|
|
|
## Usage
|
|
|
|
```typescript
|
|
import { GiteaClient } from '@apiclient.xyz/gitea';
|
|
|
|
const client = new GiteaClient('https://gitea.example.com', 'your-api-token');
|
|
|
|
// Test connection
|
|
const result = await client.testConnection();
|
|
|
|
// List repositories
|
|
const repos = await client.getRepos();
|
|
|
|
// Manage secrets
|
|
await client.setRepoSecret('owner/repo', 'SECRET_KEY', 'secret-value');
|
|
```
|
|
|
|
## License
|
|
|
|
MIT
|