Is there a way to set conditions when interacting with data through https://docs.amplify.aws/react/build-a-backend/data/mutate-data/#update-an-item. If you generate graphql code you can set them with client.graphql({ query: updateTodo, variables: { condition: { /* condition */}, input: {id: 'todo_id', content: 'new_content'}}.
#✅ - Conditions when interacting with data
3 messages · Page 1 of 1 (latest)
Hi @subtle kettle Sorry for the delay. the default generated mutation can't support applying coditions . However, you can implement this use case by creating custom mutations. Please refer to this section for more info :https://docs.amplify.aws/react/build-a-backend/data/custom-business-logic/
✅ - Conditions when interacting with data