This guide will help you understand how to interact with the Huly API for various operations by providing examples of authentication and performing CRUD operations on issues. Whether you're integrating Huly into your application or building a custom client, the examples provided here will help you get started.
To run the examples, you will need to have Huly running locally or have workspace on the Huly Cloud.
npm install
npx ts-node examples/issue-list.ts
In order to be able to install required packages, you will need to obtain GitHub access token. You can create a token by following the instructions here.
There are two ways to connect to the platform.
const client = await connect('http://localhost:8087', {
email: 'user1',
password: '1234',
workspace: 'ws1'
})
...
await client.close()
const client = await connect('http://localhost:8087', {
token: '...',
workspace: 'ws1'
})
...
await client.close()
You can find usage examples in the examples
directory.
Code example demonstrating how to query issues in specific project. Location: issue-list.ts
Code example demonstrating how to create an issue. Location: issue-create.ts
Need help? Get in touch with our team in our Huly Community on Slack.