Migrating to Hasura configuration tool v2
Pre-2.0.0@subsquid/hasura-configuration used a fixed naming schema for relation fields:
- Forward relation fields were always named after the type they referred to. Type names were
snake_cased. For example, any field referring to an entity calledBurnTestwas calledburn_test. - Inverse relation fields names were also determined by the relation type:
- In one-to-one relation their names were
to_snake_case(typeName), wheretypeNameis the name of the entity that the inverse field is typed with. - In one-to-many inverse relations they were named
$\{to_snake_case(typeName)\}s.
- In one-to-one relation their names were
@subsquid/[email protected] introduces full support for in-schema field names. Now the fields will be called exactly as they are in the schema file. If these field names are different from what’s described above, your API will have a breaking change. If you’d like to avoid it, please make sure that the fields in your schema.graphql are named exactly as described above.
To update the tool and your Hasura config:

