How to configure dot notation pattern with hey-api integration ? #1445
Replies: 3 comments 3 replies
-
|
oRPC has a The workflow is:
npx @hey-api/openapi-ts -i ./your-openapi-spec.json -o src/client
import { experimental_toORPCClient } from '@orpc/hey-api'
import * as sdk from 'src/client/sdk.gen'
export const client = experimental_toORPCClient(sdk)The conversion function recursively transforms Hey API functions, so if your Hey API client has nested structure (via For TanStack Query, oRPC provides its own query option builders: const query = useQuery(client.health.v1.queryOptions())That said, the oRPC integration doesn't directly configure Hey API's Note: This integration is marked as experimental since Hey API is still evolving. To reply, just mention @dosu. How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other |
Beta Was this translation helpful? Give feedback.
-
|
@wellington-vell Can you share your spec? |
Beta Was this translation helpful? Give feedback.
-
|
Currently, oRPC does not support the Hey API nested client. We need to expand the logic here to support it: A PR is welcome. If possible, could you also guide me on how to generate a nested client with Hey API by extending this spec: That would help me validate and add support for this feature soon. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
using orpc with a ts backend i could do this
and that would would generate a nice dot notation pattern to use
now i have a backend with another language, and want a similar behavior..
the closer i got was what @mrlubos suggest me on https://github.com/orgs/hey-api/discussions/3439
is this possible ?
Beta Was this translation helpful? Give feedback.
All reactions