Is it possible to intercept mutation similar way custom query can be created.
I need to create calculated fields.
For instance if I have Post type I would like to be able to calculate some fields before adding new object with a mutation.
Similar to this example which add custom fields on read but on add .
Lets say I have type User with fields first_name, second_name, full_name, creation_date, and I want to pass only
first_name and second_name and calculate full_name as concatenation creation_date replace with currentDate and maybe save some data from jwt token.
GitHub’s repository type
type Repository @remote { … }
Dgraph user type
type User {
# local user name = GitHub id
username: String! @id# join local data with remote repositories: [Repository] @custom(http: { url: "https://api.github.com/users/$username/repos", method: GET })
}