elixir-google-api icon indicating copy to clipboard operation
elixir-google-api copied to clipboard

GoogleApi.Gmail.V1.Api.Users.gmail_users_watch complains on undefined topic

Open Preen opened this issue 5 years ago • 1 comments

I dont see any variable where I set the topic in this action,

GoogleApi.Gmail.V1.Api.Users.gmail_users_watch()

https://github.com/googleapis/elixir-google-api/blob/738d839c82d1b21cc45256f974493cd3d3d69ac2/clients/gmail/lib/google_api/gmail/v1/api/users.ex#L173

body: "{\n  \"error\": {\n    \"code\": 400,\n    \"message\": \"topicName required\",\n    \"errors\": [\n      {\n        \"message\": \"topicName required\",\n        \"domain\": \"global\",\n        \"reason\": \"invalidArgument\"\n      }\n    ],\n    \"status\": \"INVALID_ARGUMENT\"\n  }\n}\n", ```

Preen avatar Oct 29 '20 10:10 Preen

Found it.

GoogleApi.Gmail.V1.Api.Users.gmail_users_watch(connection, "[email protected]", [body: %{topicName: "your-topic-name"}])

Tell me if you want help with the readme for the Gmail Library.

Preen avatar Oct 29 '20 12:10 Preen