Skip to content

Fix misc #10

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

Merged
merged 3 commits into from
Mar 26, 2025
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 package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "lightdash-client-typescript-fetch",
"version": "0.0.3",
"version": "0.0.4",
"description": "TypeScript client for Lightdash API generated using openapi-fetch",
"type": "module",
"main": "./dist/index.js",
Expand Down
2 changes: 1 addition & 1 deletion scripts/generate-client.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
mkdir -p src

# Download the OpenAPI specification
curl -o src/swagger.json https://raw.githubusercontent.com/lightdash/lightdash/main/packages/backend/src/generated/swagger.json
curl -f -o src/swagger.json https://raw.githubusercontent.com/lightdash/lightdash/main/packages/backend/src/generated/swagger.json

# Generate TypeScript types from OpenAPI spec
npx openapi-typescript src/swagger.json -o src/api.ts
2 changes: 0 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ import type { paths } from './api.js';
export type { paths } from './api.js';

export const createLightdashClient = (baseUrl: string, options?: RequestInit) => {
console.log('initializing lightdash client...');
console.log('baseUrl', baseUrl);
return createClient<paths>({ baseUrl, ...options });
};

Expand Down