Skip to content
This repository was archived by the owner on Jul 1, 2024. It is now read-only.

Commit 4a8bb1f

Browse files
ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.250.0 (#28)
Co-authored-by: speakeasybot <bot@speakeasyapi.dev>
1 parent ef6fe53 commit 4a8bb1f

File tree

10 files changed

+52
-44
lines changed

10 files changed

+52
-44
lines changed

.speakeasy/gen.lock

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ id: 2f8b2839-3001-46b4-b5e0-cec0aad583ed
33
management:
44
docChecksum: 2401c7030f847f72ab31c8f75de58a66
55
docVersion: 0.2.0
6-
speakeasyVersion: 1.245.0
7-
generationVersion: 2.301.3
8-
releaseVersion: 0.2.2
9-
configChecksum: 803675afb1d98123e2574559539201e5
6+
speakeasyVersion: 1.250.0
7+
generationVersion: 2.304.1
8+
releaseVersion: 0.2.3
9+
configChecksum: 191f7a8d3ea477752ba4f1cf7facee4b
1010
repoURL: https://github.com/StyraInc/opa-typescript.git
1111
installationURL: https://github.com/StyraInc/opa-typescript
1212
features:
@@ -20,7 +20,6 @@ features:
2020
unions: 2.85.3
2121
generatedFiles:
2222
- src/sdk/sdk.ts
23-
- .eslintrc.js
2423
- .npmignore
2524
- RUNTIMES.md
2625
- package.json
@@ -83,7 +82,7 @@ generatedFiles:
8382
- docs/models/errors/servererrorerrors.md
8483
- docs/models/errors/servererror.md
8584
- docs/models/errors/unhealthyserver.md
86-
- docs/sdks/opa/README.md
85+
- docs/sdks/opaapiclient/README.md
8786
- USAGE.md
8887
- .gitattributes
8988
- src/hooks/hooks.ts

.speakeasy/gen.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ generation:
1212
auth:
1313
oAuth2ClientCredentialsEnabled: false
1414
typescript:
15-
version: 0.2.2
15+
version: 0.2.3
1616
additionalDependencies:
1717
dependencies: {}
1818
devDependencies:
@@ -25,6 +25,7 @@ typescript:
2525
peerDependencies: {}
2626
author: Styra
2727
clientServerStatusCodesAsErrors: true
28+
enumFormat: enum
2829
flattenGlobalSecurity: true
2930
imports:
3031
option: openapi
@@ -37,6 +38,6 @@ typescript:
3738
inputModelSuffix: input
3839
maxMethodParams: 4
3940
outputModelSuffix: output
40-
packageName: "@styra/opa"
41+
packageName: '@styra/opa'
4142
responseFormat: envelope-http
4243
templateVersion: v2

README.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -201,10 +201,10 @@ console.log(allowed ? "allowed!" : "denied!");
201201
### Example
202202

203203
```typescript
204-
import { Opa } from "opa";
204+
import { OpaApiClient } from "@styra/opa";
205205

206206
async function run() {
207-
const sdk = new Opa();
207+
const sdk = new OpaApiClient();
208208

209209
const result = await sdk.executePolicyWithInput({
210210
path: "app/rbac",
@@ -230,11 +230,11 @@ run();
230230
<!-- Start Available Resources and Operations [operations] -->
231231
## Available Resources and Operations
232232

233-
### [Opa SDK](docs/sdks/opa/README.md)
233+
### [OpaApiClient SDK](docs/sdks/opaapiclient/README.md)
234234

235-
* [executePolicy](docs/sdks/opa/README.md#executepolicy) - Execute a policy
236-
* [executePolicyWithInput](docs/sdks/opa/README.md#executepolicywithinput) - Execute a policy given an input
237-
* [health](docs/sdks/opa/README.md#health) - Verify the server is operational
235+
* [executePolicy](docs/sdks/opaapiclient/README.md#executepolicy) - Execute a policy
236+
* [executePolicyWithInput](docs/sdks/opaapiclient/README.md#executepolicywithinput) - Execute a policy given an input
237+
* [health](docs/sdks/opaapiclient/README.md#health) - Verify the server is operational
238238
<!-- End Available Resources and Operations [operations] -->
239239

240240
<!-- Start Error Handling [errors] -->
@@ -252,11 +252,11 @@ Validation errors can also occur when either method arguments or data returned f
252252

253253

254254
```typescript
255-
import { Opa } from "opa";
256-
import * as errors from "opa/models/errors";
255+
import { OpaApiClient } from "@styra/opa";
256+
import * as errors from "@styra/opa/models/errors";
257257

258258
async function run() {
259-
const sdk = new Opa();
259+
const sdk = new OpaApiClient();
260260

261261
let result;
262262
try {
@@ -307,10 +307,10 @@ You can override the default server globally by passing a server index to the `s
307307
| 0 | `http://localhost:8181` | None |
308308

309309
```typescript
310-
import { Opa } from "opa";
310+
import { OpaApiClient } from "@styra/opa";
311311

312312
async function run() {
313-
const sdk = new Opa({
313+
const sdk = new OpaApiClient({
314314
serverIdx: 0,
315315
});
316316

@@ -332,10 +332,10 @@ run();
332332
The default server can also be overridden globally by passing a URL to the `serverURL` optional parameter when initializing the SDK client instance. For example:
333333

334334
```typescript
335-
import { Opa } from "opa";
335+
import { OpaApiClient } from "@styra/opa";
336336

337337
async function run() {
338-
const sdk = new Opa({
338+
const sdk = new OpaApiClient({
339339
serverURL: "http://localhost:8181",
340340
});
341341

@@ -370,8 +370,8 @@ custom header and a timeout to requests and how to use the `"requestError"` hook
370370
to log errors:
371371

372372
```typescript
373-
import { Opa } from "opa";
374-
import { HTTPClient } from "opa/lib/http";
373+
import { OpaApiClient } from "@styra/opa";
374+
import { HTTPClient } from "@styra/opa/lib/http";
375375

376376
const httpClient = new HTTPClient({
377377
// fetcher takes a function that has the same signature as native `fetch`.
@@ -397,7 +397,7 @@ httpClient.addHook("requestError", (error, request) => {
397397
console.groupEnd();
398398
});
399399

400-
const sdk = new Opa({ httpClient });
400+
const sdk = new OpaApiClient({ httpClient });
401401
```
402402
<!-- End Custom HTTP Client [http-client] -->
403403

RELEASES.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,4 +62,12 @@ Based on:
6262
- OpenAPI Doc
6363
- Speakeasy CLI 1.245.0 (2.301.3) https://github.com/speakeasy-api/speakeasy
6464
### Generated
65-
- [typescript v0.2.2] .
65+
- [typescript v0.2.2] .
66+
67+
## 2024-04-11 18:30:10
68+
### Changes
69+
Based on:
70+
- OpenAPI Doc
71+
- Speakeasy CLI 1.250.0 (2.304.1) https://github.com/speakeasy-api/speakeasy
72+
### Generated
73+
- [typescript v0.2.3] .

USAGE.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
<!-- Start SDK Example Usage [usage] -->
22
```typescript
3-
import { Opa } from "opa";
3+
import { OpaApiClient } from "@styra/opa";
44

55
async function run() {
6-
const sdk = new Opa();
6+
const sdk = new OpaApiClient();
77

88
const result = await sdk.executePolicyWithInput({
99
path: "app/rbac",

docs/sdks/opa/README.md renamed to docs/sdks/opaapiclient/README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Opa SDK
1+
# OpaApiClient SDK
22

33

44
## Overview
@@ -18,10 +18,10 @@ Execute a policy
1818
### Example Usage
1919

2020
```typescript
21-
import { Opa } from "opa";
21+
import { OpaApiClient } from "@styra/opa";
2222

2323
async function run() {
24-
const sdk = new Opa();
24+
const sdk = new OpaApiClient();
2525

2626
const result = await sdk.executePolicy({
2727
path: "app/rbac",
@@ -61,10 +61,10 @@ Execute a policy given an input
6161
### Example Usage
6262

6363
```typescript
64-
import { Opa } from "opa";
64+
import { OpaApiClient } from "@styra/opa";
6565

6666
async function run() {
67-
const sdk = new Opa();
67+
const sdk = new OpaApiClient();
6868

6969
const result = await sdk.executePolicyWithInput({
7070
path: "app/rbac",
@@ -112,10 +112,10 @@ The health API endpoint executes a simple built-in policy query to verify that t
112112
### Example Usage
113113

114114
```typescript
115-
import { Opa } from "opa";
115+
import { OpaApiClient } from "@styra/opa";
116116

117117
async function run() {
118-
const sdk = new Opa();
118+
const sdk = new OpaApiClient();
119119

120120
const bundles = false;
121121
const plugins = false;

package-lock.json

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"name": "opa",
3-
"version": "0.2.2",
2+
"name": "@styra/opa",
3+
"version": "0.2.3",
44
"author": "Styra",
55
"main": "./index.js",
66
"sideEffects": false,

src/lib/config.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
5252
export const SDK_METADATA = Object.freeze({
5353
language: "typescript",
5454
openapiDocVersion: "0.2.0",
55-
sdkVersion: "0.2.2",
56-
genVersion: "2.301.3",
57-
userAgent: "speakeasy-sdk/typescript 0.2.2 2.301.3 0.2.0 opa",
55+
sdkVersion: "0.2.3",
56+
genVersion: "2.304.1",
57+
userAgent: "speakeasy-sdk/typescript 0.2.3 2.304.1 0.2.0 @styra/opa",
5858
});

src/sdk/sdk.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import { ClientSDK, RequestOptions } from "../lib/sdks";
1111
import * as errors from "../models/errors";
1212
import * as operations from "../models/operations";
1313

14-
export class Opa extends ClientSDK {
14+
export class OpaApiClient extends ClientSDK {
1515
private readonly options$: SDKOptions & { hooks?: SDKHooks };
1616

1717
constructor(options: SDKOptions = {}) {

0 commit comments

Comments
 (0)