Questions tagged [hasura]

Hasura is an open-source tool that provides instant realtime GraphQL APIs and webhook event triggers on Postgres.

Hasura

Hasura provides a scalable and performant GraphQL API out of the box. It can run up to 1mio concurrent subscriptions, scaling vertically & horizontally seamlessly. It comes with a comprehensive permission system that allows you to enforce fine-grained access control. Authentication can be integrated using webhooks or JWT. Hasura also allows you to extend your GraphQL API with business logic through remote schemas (other GraphQL servers), actions (REST APIs) or even custom functions in Postgres. Event triggers make it possible to trigger business logic that is running in serverless functions.

Hasura runs in a Docker container and can be deployed to any cloud provider that runs Docker, or it can be run locally. Use Hasura migrations to migrate from your development environment to production, as well as for version control.

Tech stack

  • The Hasura server which serves the GraphQL API is written in #Haskell. It takes declarative configuration.
  • The Hasura console allows you to configure the Hasura server, manage your Postgres database and test your APIs. It's built with #React.
  • The Hasura CLI that is used for the CI/CD and migration workflows is written in #Go.

Useful links

Initial release

3rd July 2018.

729 questions
6
votes
1 answer

Run Hasura without Docker

I'm looking for the way to run Hasura without Docker, but can't find any way to do that - is there any option to achieve that? Have a negative experience with Prisma in Docker, would like to try Hasura, but no, please, no Docker. Any help would be…
6
votes
3 answers

AAD B2C: Output a nested JSON object in a JWT for Hasura

We are using Hasura to provide our GraphQL API to consumers. Currently we use Auth0 to authenticate users, but we would like to migrate to Azure AD B2C. A requirement of JWT security with Hasura is using the "https://hasura.io/jwt/claims" namespace…
Dave
  • 63
  • 1
  • 7
6
votes
0 answers

Is there any way to return SETOF without table name in Hasura graphql custom sql function

I have created custom sql function in hasura and tracked it. But need to write table name in "RETURNS SETOF " (Refer: https://docs.hasura.io/1.0/graphql/manual/schema/custom-functions.html). Here I cannot create new table having schema…
Shivprsad Sammbhare
  • 410
  • 3
  • 7
  • 20
6
votes
3 answers

How to customize the type for a graphql-code-generator produced field when consuming a Hasura graphql schema

I would like to override a the jsonb type for a speficic field in a graphql schema produced by Hasura and run through graphql-code-generator. I have a customList field of type jsonb. Ths is used to contain an array of json objects. When using…
arhnee
  • 1,044
  • 9
  • 24
6
votes
2 answers

Hasura GraphQL Endpoint behind Apollo Federated Gateway

Has anyone successfully placed a Hasura GraphQL endpoint, behind an Apollo Federated Gateway? I know Hasura wants to act as the point of federation but I would rather not do that...current thought is to create an apollo server with a remote schema…
T.Davidson
  • 89
  • 7
6
votes
1 answer

Graphql - Is there a way how to insert two tables at the same time, but the second table is dependent on the return of from the first table?

i am new to graphql and i am having this issue and don't know how to solve it. for example i have two tables: book and book_author; book has book_id and name book_author has book_author_id, book_id, author_name that two tables needs to be inserted…
rosiejaneenomar
  • 882
  • 1
  • 10
  • 17
6
votes
2 answers

Get max and min value using GraphQL query

I have been working on a GraphQL and firing queries to get the JSON response into react app. But I need to fire a query which will return me the max and min value from the column. I have gone through the document of GraphQL but nowhere I found the…
Vishal Shetty
  • 1,618
  • 1
  • 27
  • 40
6
votes
3 answers

How do I import a .csv file into my Hasura PostgreSQL database?

I have data in a .csv file that I want to import into my Hasura cluster's PostgreSQL database instance. What's the best way to do this?
Kartikey
  • 63
  • 1
  • 7
5
votes
1 answer

Duplicate active queries in Apollo Client Devtools

I’m using React with Apollo Client 3 and Hasura as a GraphQL server. The component ProductList use the get_products query once. Then two exact copies of this query are memorized in the Apollo Cache as shown in the Apollo DevTools. My question is -…
5
votes
2 answers

Is there a way to get a structure of a Strapi CMS Content Type?

A content-type "Product" having the following fields: string title int qty string description double price Is there an API endpoint to retrieve the structure or schema of the "Product" content-type as opposed to getting the values? For example: On…
junerockwell
  • 838
  • 1
  • 9
  • 29
5
votes
0 answers

Edit multi select input in react-admin for one-to-many or many-to-many relationship?

What is the current "out-of-the-box" way for editing many-to-many relationships in react-admin? More specifically, is there any way to SelectArrayInput or AutoCompleteArrayInput over a referenced table? My first table is stream stream table My…
Amit Kumar
  • 169
  • 1
  • 10
5
votes
1 answer

Can someone forge a request to Hasura GraphQL Engine by setting x-hasura-role?

If i understand correctly, to authorize a query or mutation in hasura using JWT, there are a few requirements that needs to be fulfilled in the request itself, which is: The JWT itself, presented in the request header Authorization: Bearer
5
votes
2 answers

Use hasura with Google Cloud Run and Google Cloud SQL

The docs describe that hasura needs the postgres connection string with the HASURA_GRAPHQL_DATABASE_URL env var. Example: docker run -d -p 8080:8080 \ -e HASURA_GRAPHQL_DATABASE_URL=postgres://username:password@hostname:port/dbname \ …
wiesson
  • 6,544
  • 5
  • 40
  • 68
5
votes
1 answer

How to filter GraphQL nested array on field returning in same query's response? Or how to create GraphQL relationship on more than one field?

So I'm using GraphQL with Hasura and Apollo in my Android application. The application is related to sports, it stores multiple score sets of each player in multiple segments of a match. My Postgres database has following tables (with concerned…
4
votes
0 answers

How to consume Trino data with GraphQL

We have a dataplatform built around Trino and Privacera and it is working well. It is possible to query data from dozens of sources through trino and authorization with Privacera works like a charm. Then we have a new requirement stating that they…
Bagaboo
  • 343
  • 3
  • 17
1
2
3
48 49