Skip to content

Commit

Permalink
Merge pull request #31 from unkeyed/speakeasy-sdk-regen-1721253905
Browse files Browse the repository at this point in the history
chore: 🐝 Update SDK - Generate
  • Loading branch information
chronark authored Jul 17, 2024
2 parents c205a19 + bca21a4 commit 0630f42
Show file tree
Hide file tree
Showing 48 changed files with 2,749 additions and 48 deletions.
42 changes: 36 additions & 6 deletions .speakeasy/gen.lock
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
lockVersion: 2.0.0
id: 4fc4737a-135f-4840-8e6d-42a2b2a2884b
management:
docChecksum: 1adbad72708fe75ac7626a1e7e1dfc13
docChecksum: 75f7e089853056de07ee9bd3d0b1678d
docVersion: 1.0.0
speakeasyVersion: 1.335.2
generationVersion: 2.372.3
releaseVersion: 0.7.0
configChecksum: c299315b1cde1ca427dc047689fa60ff
speakeasyVersion: 1.340.0
generationVersion: 2.375.5
releaseVersion: 0.8.0
configChecksum: f7715aaf0773d3aaeefa9a127727517d
repoURL: https://github.com/unkeyed/unkey-go.git
installationURL: https://github.com/unkeyed/unkey-go
features:
go:
additionalDependencies: 0.1.0
constsAndDefaults: 0.1.4
core: 3.4.15
core: 3.5.0
defaultEnabledRetries: 0.2.0
deprecations: 2.81.1
envVarSecurityUsage: 0.2.0
Expand All @@ -24,6 +24,7 @@ features:
ignores: 2.81.1
intellisenseMarkdownSupport: 0.1.0
nullables: 0.1.0
pagination: 2.82.1
responseFormat: 0.1.2
retries: 2.83.0
sdkHooks: 0.1.0
Expand All @@ -35,6 +36,7 @@ generatedFiles:
- ratelimits.go
- migrations.go
- permissions.go
- identities.go
- unkey.go
- go.mod
- models/sdkerrors/sdkerror.go
Expand All @@ -56,6 +58,8 @@ generatedFiles:
- internal/utils/utils.go
- /models/operations/createapi.go
- /models/operations/deleteapi.go
- /models/operations/createidentity.go
- /models/operations/deleteeidentity.go
- /models/operations/v1liveness.go
- /models/operations/getkey.go
- /models/operations/deletekey.go
Expand Down Expand Up @@ -84,6 +88,9 @@ generatedFiles:
- /models/operations/deleterole.go
- /models/operations/getrole.go
- /models/operations/listroles.go
- /models/operations/getidentity.go
- /models/operations/listidentities.go
- /models/operations/updateidentity.go
- /models/components/httpmetadata.go
- /models/components/key.go
- /models/components/v1keysverifykeyresponse.go
Expand All @@ -103,6 +110,13 @@ generatedFiles:
- docs/models/operations/deleteapirequestbody.md
- docs/models/operations/deleteapiresponsebody.md
- docs/models/operations/deleteapiresponse.md
- docs/models/operations/ratelimits.md
- docs/models/operations/createidentityrequestbody.md
- docs/models/operations/createidentityresponsebody.md
- docs/models/operations/createidentityresponse.md
- docs/models/operations/deleteeidentityrequestbody.md
- docs/models/operations/deleteeidentityresponsebody.md
- docs/models/operations/deleteeidentityresponse.md
- docs/models/operations/services.md
- docs/models/operations/v1livenessresponsebody.md
- docs/models/operations/v1livenessresponse.md
Expand Down Expand Up @@ -215,6 +229,19 @@ generatedFiles:
- docs/models/operations/getroleresponse.md
- docs/models/operations/listrolesresponsebody.md
- docs/models/operations/listrolesresponse.md
- docs/models/operations/getidentityrequest.md
- docs/models/operations/getidentityratelimits.md
- docs/models/operations/getidentityresponsebody.md
- docs/models/operations/getidentityresponse.md
- docs/models/operations/listidentitiesrequest.md
- docs/models/operations/listidentitiesratelimits.md
- docs/models/operations/identities.md
- docs/models/operations/listidentitiesresponsebody.md
- docs/models/operations/listidentitiesresponse.md
- docs/models/operations/updateidentityratelimits.md
- docs/models/operations/updateidentityrequestbody.md
- docs/models/operations/updateidentityresponsebody.md
- docs/models/operations/updateidentityresponse.md
- docs/models/components/httpmetadata.md
- docs/models/components/interval.md
- docs/models/components/refill.md
Expand All @@ -223,6 +250,7 @@ generatedFiles:
- docs/models/components/key.md
- docs/models/components/v1keysverifykeyresponseratelimit.md
- docs/models/components/code.md
- docs/models/components/identity.md
- docs/models/components/v1keysverifykeyresponse.md
- docs/models/components/authorization.md
- docs/models/components/v1keysverifykeyrequestratelimit.md
Expand Down Expand Up @@ -261,7 +289,9 @@ generatedFiles:
- docs/sdks/ratelimits/README.md
- docs/sdks/migrations/README.md
- docs/sdks/permissions/README.md
- docs/sdks/identities/README.md
- USAGE.md
- models/operations/options.go
- .gitattributes
- internal/hooks/hooks.go
- CONTRIBUTING.md
2 changes: 1 addition & 1 deletion .speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ generation:
auth:
oAuth2ClientCredentialsEnabled: true
go:
version: 0.7.0
version: 0.8.0
additionalDependencies: {}
allowUnknownFieldsInWeakUnions: false
clientServerStatusCodesAsErrors: true
Expand Down
10 changes: 5 additions & 5 deletions .speakeasy/workflow.lock
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
speakeasyVersion: 1.335.2
speakeasyVersion: 1.340.0
sources:
openapi.json:
sourceNamespace: openapi-json
sourceRevisionDigest: sha256:5754c6125ef1a2d0690dd2ba633bc841608de7594320804124517ded211f4f1a
sourceBlobDigest: sha256:f0439adffd2a8e451bd3b624609ededd5e1b0eb06fc998eafa5e2ee5df6613d4
sourceRevisionDigest: sha256:8692dc0ff51ce0350cb69b2465bc3289d63a4986945e5574285cd187a05248c1
sourceBlobDigest: sha256:249aa19308afcc8b58771b1b2833cd720293edea20e33016faa4e23aef204656
tags:
- latest
- main
targets:
go:
source: openapi.json
sourceNamespace: openapi-json
sourceRevisionDigest: sha256:5754c6125ef1a2d0690dd2ba633bc841608de7594320804124517ded211f4f1a
sourceBlobDigest: sha256:f0439adffd2a8e451bd3b624609ededd5e1b0eb06fc998eafa5e2ee5df6613d4
sourceRevisionDigest: sha256:8692dc0ff51ce0350cb69b2465bc3289d63a4986945e5574285cd187a05248c1
sourceBlobDigest: sha256:249aa19308afcc8b58771b1b2833cd720293edea20e33016faa4e23aef204656
outLocation: /github/workspace/repo
workflow:
workflowVersion: 1.0.0
Expand Down
26 changes: 26 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Contributing to This Repository

Thank you for your interest in contributing to this repository. Please note that this repository contains generated code. As such, we do not accept direct changes or pull requests. Instead, we encourage you to follow the guidelines below to report issues and suggest improvements.

## How to Report Issues

If you encounter any bugs or have suggestions for improvements, please open an issue on GitHub. When reporting an issue, please provide as much detail as possible to help us reproduce the problem. This includes:

- A clear and descriptive title
- Steps to reproduce the issue
- Expected and actual behavior
- Any relevant logs, screenshots, or error messages
- Information about your environment (e.g., operating system, software versions)
- For example can be collected using the `npx envinfo` command from your terminal if you have Node.js installed

## Issue Triage and Upstream Fixes

We will review and triage issues as quickly as possible. Our goal is to address bugs and incorporate improvements in the upstream source code. Fixes will be included in the next generation of the generated code.

## Contact

If you have any questions or need further assistance, please feel free to reach out by opening an issue.

Thank you for your understanding and cooperation!

The Maintainers
60 changes: 60 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ func main() {

* [CreateAPI](docs/sdks/unkey/README.md#createapi)
* [DeleteAPI](docs/sdks/unkey/README.md#deleteapi)
* [CreateIdentity](docs/sdks/unkey/README.md#createidentity)
* [DeleteeIdentity](docs/sdks/unkey/README.md#deleteeidentity)

### [Liveness](docs/sdks/liveness/README.md)

Expand Down Expand Up @@ -102,6 +104,12 @@ func main() {
* [DeleteRole](docs/sdks/permissions/README.md#deleterole)
* [GetRole](docs/sdks/permissions/README.md#getrole)
* [ListRoles](docs/sdks/permissions/README.md#listroles)

### [Identities](docs/sdks/identities/README.md)

* [GetIdentity](docs/sdks/identities/README.md#getidentity)
* [ListIdentities](docs/sdks/identities/README.md#listidentities)
* [UpdateIdentity](docs/sdks/identities/README.md#updateidentity)
<!-- End Available Resources and Operations [operations] -->

<!-- Start Error Handling [errors] -->
Expand Down Expand Up @@ -449,6 +457,58 @@ func main() {
```
<!-- End Retries [retries] -->

<!-- Start Pagination [pagination] -->
## Pagination

Some of the endpoints in this SDK support pagination. To use pagination, you make your SDK calls as usual, but the
returned response object will have a `Next` method that can be called to pull down the next group of results. If the
return value of `Next` is `nil`, then there are no more pages to be fetched.

Here's an example of one such pagination call:
```go
package main

import (
"context"
unkeygo "github.com/unkeyed/unkey-go"
"github.com/unkeyed/unkey-go/models/operations"
"log"
"os"
)

func main() {
s := unkeygo.New(
unkeygo.WithSecurity(os.Getenv("BEARER_AUTH")),
)
request := operations.ListIdentitiesRequest{
Limit: unkeygo.Int64(100),
}
ctx := context.Background()
res, err := s.Identities.ListIdentities(ctx, request)
if err != nil {
log.Fatal(err)
}
if res.Object != nil {
for {
// handle items

res, err = res.Next()

if err != nil {
// handle error
}

if res == nil {
break
}
}

}
}

```
<!-- End Pagination [pagination] -->

<!-- Placeholder for Future Speakeasy SDK Sections -->

# Development
Expand Down
12 changes: 11 additions & 1 deletion RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,4 +128,14 @@ Based on:
### Generated
- [go v0.7.0] .
### Releases
- [Go v0.7.0] https://github.com/unkeyed/unkey-go/releases/tag/v0.7.0 - .
- [Go v0.7.0] https://github.com/unkeyed/unkey-go/releases/tag/v0.7.0 - .

## 2024-07-17 22:05:01
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.340.0 (2.375.5) https://github.com/speakeasy-api/speakeasy
### Generated
- [go v0.8.0] .
### Releases
- [Go v0.8.0] https://github.com/unkeyed/unkey-go/releases/tag/v0.8.0 - .
12 changes: 12 additions & 0 deletions docs/models/components/identity.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Identity

The associated identity of this key.


## Fields

| Field | Type | Required | Description |
| ------------------ | ------------------ | ------------------ | ------------------ |
| `ID` | *string* | :heavy_check_mark: | N/A |
| `ExternalID` | *string* | :heavy_check_mark: | N/A |
| `Meta` | map[string]*any* | :heavy_check_mark: | N/A |
3 changes: 1 addition & 2 deletions docs/models/components/ratelimits.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@

| Field | Type | Required | Description | Example |
| ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ |
| `Name` | *string* | :heavy_check_mark: | The name of the ratelimit | tokens |
| `Name` | *string* | :heavy_check_mark: | The name of the ratelimit. | tokens |
| `Cost` | **int64* | :heavy_minus_sign: | Optionally override how expensive this operation is and how many tokens are deducted from the current limit. | |
| `Identifier` | **string* | :heavy_minus_sign: | The identifier used for ratelimiting. If omitted, we use the key's id. | |
| `Limit` | **float64* | :heavy_minus_sign: | Optionally override the limit. | |
| `Duration` | **float64* | :heavy_minus_sign: | Optionally override the ratelimit window duration. | |
Loading

0 comments on commit 0630f42

Please sign in to comment.