Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
chialunwu committed Aug 21, 2023
1 parent ef26e9f commit a87da7d
Showing 1 changed file with 7 additions and 22 deletions.
29 changes: 7 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,33 +10,18 @@ API documentation is available at <https://docs.flagright.com>.

## Usage

[![Try it out](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/edit/flagright-typescript-ebcjpf?file=app.ts&view=editor)

```typescript
import { FlagrightClient } from 'flagright';

const client = new FlagrightClient({
apiKey: 'MY_API_KEY',
});

const response = await client.verifyTransaction({
const client = new FlagrightClient({ apiKey: 'YOUR_API_KEY' })
const response = await client.transactions.verify({
body: {
transactionId: 'my-transaction-id',
type_: 'DEPOSIT',
originUserId: 'origin-user-id',
type: Flagright.TransactionType.Deposit,
timestamp: 1676392009,
timestamp: 1692624734000,
},
});

console.log('Received response from Flagright!', response);
```

## Beta status

This SDK is in beta, and there may be breaking changes between versions without a major version update. Therefore, we recommend pinning the package version to a specific version in your package.json file. This way, you can install the same version each time without breaking changes unless you are intentionally looking for the latest version.

## Contributing

While we value open-source contributions to this SDK, this library is generated programmatically. Additions made directly to this library would have to be moved over to our generation code, otherwise they would be overwritten upon the next generated release. Feel free to open a PR as a proof of concept, but know that we will not be able to merge it as-is. We suggest opening an issue first to discuss with us!
})

On the other hand, contributions to the README are always very welcome!
console.log('Received response from Flagright:', response);
```

0 comments on commit a87da7d

Please sign in to comment.