Mutation
mutation SaveProtocolComment($input: SaveProtocolCommentInput!) {
saveProtocolComment(input: $input) {
active
author {
allowedLocations {
children {
__typename
}
id
isSite
location
parentId
tags
}
avatarUrl
department
email
firstName
groups {
createdAt
id
name
users {
__typename
}
}
}
id
replies {
__typename
}
section
text
}
}Variables
{
"input": {
"text": "string"
}
}Response
{
"data": {
"saveProtocolComment": {
"active": true,
"author": {
"allowedLocations": [
{
"children": [
{
"__typename": "Location"
}
],
"id": 1,
"isSite": true,
"location": "string",
"parentId": 1,
"tags": [
"string"
]
}
],
"avatarUrl": "string",
"department": "string",
"email": "string",
"firstName": "string",
"groups": [
{
"createdAt": "value",
"id": "string",
"name": "string",
"users": [
{
"__typename": "User"
}
]
}
]
},
"id": "string",
"replies": [
{
"__typename": "ProtocolComment"
}
],
"section": "string",
"text": "string"
}
}
}Mutations
saveProtocolComment
Adds a comment to a protocol version, replies to a comment or edits the text of one, and returns the comment.
MUTATION
saveProtocolComment(input: SaveProtocolCommentInput!): ProtocolComment!Arguments
input
required
The comment to add, the reply to post or the edit to apply.
Returns
active
Boolean!
True while the thread the comment belongs to is open, false once it has been resolved.
author
User!
The user who wrote the comment.
id
String!
Id of the comment.
replies
[ProtocolComment!]!
Replies to the comment. Empty if there are no replies.
section
String!
The part of the protocol the comment is on: one of 'OVERVIEW' (Overview), 'MATERIALS' (Materials) or 'SAFETY' (Safety), or 'STEP:' followed by the id of a procedure step.
text
String!
Text of the comment.
updatedAt
DateTime!
When the comment was last changed.
Mutation
mutation SaveProtocolComment($input: SaveProtocolCommentInput!) {
saveProtocolComment(input: $input) {
active
author {
allowedLocations {
children {
__typename
}
id
isSite
location
parentId
tags
}
avatarUrl
department
email
firstName
groups {
createdAt
id
name
users {
__typename
}
}
}
id
replies {
__typename
}
section
text
}
}Variables
{
"input": {
"text": "string"
}
}Response
{
"data": {
"saveProtocolComment": {
"active": true,
"author": {
"allowedLocations": [
{
"children": [
{
"__typename": "Location"
}
],
"id": 1,
"isSite": true,
"location": "string",
"parentId": 1,
"tags": [
"string"
]
}
],
"avatarUrl": "string",
"department": "string",
"email": "string",
"firstName": "string",
"groups": [
{
"createdAt": "value",
"id": "string",
"name": "string",
"users": [
{
"__typename": "User"
}
]
}
]
},
"id": "string",
"replies": [
{
"__typename": "ProtocolComment"
}
],
"section": "string",
"text": "string"
}
}
}