graphql

Modify a custom resolver

Changed on

Modify an existing custom resolver configuration.

put/groups/{groupId}/apps/{appId}/graphql/custom_resolvers/{customResolverId}

Request

  • Base URL
    https://services.cloud.mongodb.com/api/admin/v3.0
  • URL
    https://services.cloud.mongodb.com/api/admin/v3.0/groups/{groupId}/apps/{appId}/graphql/custom_resolvers/{customResolverId}
  • Auth
    HTTP bearer

Request body

on_typestring required

The name of the resolver's parent type. This can be "Query", "Mutation", or the name of a generated type if this is a computed property.

field_namestring required

The name of the custom resolver field that appears in the GraphQL schema.

input_type_format'scalar' | 'scalar-list' | 'generated' | 'generated-list' | 'custom'

The kind of input type the custom resolver uses. This value must agree with the value of input_type:

  • A scalar input type must use "scalar" or "scalar-list"
  • A generated input type must use "generated" or "generated-list"
  • A custom input type must use "custom"

If undefined, the resolver does not accept an input.

payload_type_format'scalar' | 'scalar-list' | 'generated' | 'generated-list' | 'custom'

The kind of payload type the custom resolver uses. This value must agree with the value of payload_type:

  • A scalar payload type must use "scalar" or "scalar-list"
  • A generated payload type must use "generated" or "generated-list"
  • A custom payload type must use "custom"

If undefined, the resolver returns a DefaultPayload object.

_idstring required

The custom resolver's unique ID.

function_idstring required

The resolver function's unique ID.

Response

Updated

Changes

    • breaking

      added subschema #2 to the request body allOf list

    • breaking

      the request's body type changed from object to no type

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property