Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(api): update via SDK Studio #17

Merged
merged 1 commit into from
Jun 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/publish-npm.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This workflow is triggered when a GitHub release is created.
# It can also be run manually to re-publish to NPM in case it failed for some reason.
# You can run this workflow by navigating to https://www.github.com/OneBusAway/js-sdk/actions/workflows/publish-npm.yml
# You can run this workflow by navigating to https://www.github.com/onebusaway/js-sdk/actions/workflows/publish-npm.yml
name: Publish NPM
on:
workflow_dispatch:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-doctor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
release_doctor:
name: release doctor
runs-on: ubuntu-latest
if: github.repository == 'OneBusAway/js-sdk' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || startsWith(github.head_ref, 'release-please') || github.head_ref == 'next')
if: github.repository == 'onebusaway/js-sdk' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || startsWith(github.head_ref, 'release-please') || github.head_ref == 'next')

steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 6
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/open-transit%2Fopen-transit-e2d8fe6ddeac1c6c1069b561d47fb0a2a5c821fe2840c734238e050d73fe211b.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/open-transit%2Foba-e2d8fe6ddeac1c6c1069b561d47fb0a2a5c821fe2840c734238e050d73fe211b.yml
6 changes: 3 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@ If you’d like to use the repository from source, you can either install from g
To install via git:

```bash
npm install git+ssh://[email protected]:OneBusAway/js-sdk.git
npm install git+ssh://[email protected]:onebusaway/js-sdk.git
```

Alternatively, to link a local copy of the repo:

```bash
# Clone
git clone https://www.github.com/OneBusAway/js-sdk
git clone https://www.github.com/onebusaway/js-sdk
cd js-sdk

# With yarn
Expand Down Expand Up @@ -99,7 +99,7 @@ the changes aren't made through the automated pipeline, you may want to make rel

### Publish with a GitHub workflow

You can release to package managers by using [the `Publish NPM` GitHub action](https://www.github.com/OneBusAway/js-sdk/actions/workflows/publish-npm.yml). This requires a setup organization or repository secret to be set up.
You can release to package managers by using [the `Publish NPM` GitHub action](https://www.github.com/onebusaway/js-sdk/actions/workflows/publish-npm.yml). This requires a setup organization or repository secret to be set up.

### Publish manually

Expand Down
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,12 @@ It is generated with [Stainless](https://www.stainlessapi.com/).
## Installation

```sh
npm install onebusaway-sdk
npm install git+ssh://[email protected]:onebusaway/js-sdk.git
```

> [!NOTE]
> Once this package is [published to npm](https://app.stainlessapi.com/docs/guides/publish), this will become: `npm install onebusaway-sdk`

## Usage

The full API of this library can be found in [api.md](api.md).
Expand Down Expand Up @@ -216,7 +219,7 @@ import OnebusawaySDK from 'onebusaway-sdk';
```

To do the inverse, add `import "onebusaway-sdk/shims/node"` (which does import polyfills).
This can also be useful if you are getting the wrong TypeScript types for `Response` ([more details](https://github.com/OneBusAway/js-sdk/tree/main/src/_shims#readme)).
This can also be useful if you are getting the wrong TypeScript types for `Response` ([more details](https://github.com/onebusaway/js-sdk/tree/main/src/_shims#readme)).

### Logging and middleware

Expand Down Expand Up @@ -272,7 +275,7 @@ This package generally follows [SemVer](https://semver.org/spec/v2.0.0.html) con

We take backwards-compatibility seriously and work hard to ensure you can rely on a smooth upgrade experience.

We are keen for your feedback; please open an [issue](https://www.github.com/OneBusAway/js-sdk/issues) with questions, bugs, or suggestions.
We are keen for your feedback; please open an [issue](https://www.github.com/onebusaway/js-sdk/issues) with questions, bugs, or suggestions.

## Requirements

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"types": "dist/index.d.ts",
"main": "dist/index.js",
"type": "commonjs",
"repository": "github:OneBusAway/js-sdk",
"repository": "github:onebusaway/js-sdk",
"license": "Apache-2.0",
"packageManager": "[email protected]",
"files": [
Expand Down
2 changes: 1 addition & 1 deletion src/_shims/index-deno.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ export function getDefaultAgent(url: string) {
}
export function fileFromPath() {
throw new Error(
'The `fileFromPath` function is only supported in Node. See the README for more details: https://www.github.com/OneBusAway/js-sdk#file-uploads',
'The `fileFromPath` function is only supported in Node. See the README for more details: https://www.github.com/onebusaway/js-sdk#file-uploads',
);
}

Expand Down
2 changes: 1 addition & 1 deletion src/_shims/web-runtime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ export function getRuntime({ manuallyImported }: { manuallyImported?: boolean }
getDefaultAgent: (url: string) => undefined,
fileFromPath: () => {
throw new Error(
'The `fileFromPath` function is only supported in Node. See the README for more details: https://www.github.com/OneBusAway/js-sdk#file-uploads',
'The `fileFromPath` function is only supported in Node. See the README for more details: https://www.github.com/onebusaway/js-sdk#file-uploads',
);
},
isFsReadStream: (value: any) => false,
Expand Down