Interface IAnnotationService
Provides methods for managing annotations within a project.
Namespace: Unity.Cloud.Collaboration.Services.AnnotationService
Assembly: Unity.Cloud.Collaboration.dll
Syntax
public interface IAnnotationService
Methods
CreateAnnotationAsync(ProjectId, string, Dictionary<string, string>, string, string, Dictionary<string, object>, bool, List<ICreateAttachmentRequest>, CreateAnnotationStatus?, CancellationToken)
Create annotation matching the given target
Declaration
Task<AnnotationId> CreateAnnotationAsync(ProjectId projectId, string target, Dictionary<string, string> targetContext = null, string rootAnnotationId = null, string text = null, Dictionary<string, object> metadata = null, bool unresolveRootAnnotation = false, List<ICreateAttachmentRequest> attachments = null, CreateAnnotationStatus? status = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The ID of the project that the Annotation is to be created within. Project should match any in the target. |
| string | target | String containing a path encoding of the element (e.g. asset) to associate the Annotation with. Format: assets/projects//assets/ (required). |
| Dictionary<string, string> | targetContext | Additional metadata used to further identify the element to associate the Annotation with. Examples of fields that could be used if you are using the assets service marker are: - assetVersionId: string (ID of the Asset Version to target within the Asset Manager) - assetVersionNumber: int (Numeric value representing the Version of the Asset to target) |
| string | rootAnnotationId | null if Annotation is a Root Annotation or an Annotation ID of a root annotation if this Annotation is a Reply in a Thread The RootAnnotationId allows for a root/child relationship. These cannot be nested, allowing only for a thread design.. |
| string | text | Text for the Annotation
### Restrictions
- Must be less than 10,000 characters
- Cannot be empty or contain only whitespace characters
- Cannot start or end with whitespace characters
### Mentioning a User
To mention a User, use format |
| Dictionary<string, object> | metadata | Object for holding additional user defined metadata. This is not used within the annotations system, but can be useful for storing information useful for enhancing the annotation within a custom system. This will not be displayed on the web portal currently |
| bool | unresolveRootAnnotation | If creating a reply, set to true to unresolve the rootAnnotation. This is only applicable for annotations in a thread that has been marked as resolved. In other cases it will have no effect |
| List<ICreateAttachmentRequest> | attachments | The attachments that should be created with the annotation. ### Attachment Types These attachments can have multiple types, as defined by the OneOf schema |
| CreateAnnotationStatus? | status | status. |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<AnnotationId> | Task of Annotation ID |
Remarks
Creates a new annotation in the project with a given target.
CreateAnnotationAsync(ProjectId, AssetId, Dictionary<string, string>, string, string, Dictionary<string, object>, bool, List<ICreateAttachmentRequest>, CreateAnnotationStatus?, CancellationToken)
Create annotation matching the Asset ID
Declaration
Task<AnnotationId> CreateAnnotationAsync(ProjectId projectId, AssetId assetId, Dictionary<string, string> targetContext = null, string rootAnnotationId = null, string text = null, Dictionary<string, object> metadata = null, bool unresolveRootAnnotation = false, List<ICreateAttachmentRequest> attachments = null, CreateAnnotationStatus? status = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The ID of the project that the Annotation is to be created within. Project should match any in the target. |
| AssetId | assetId | The Asset ID. |
| Dictionary<string, string> | targetContext | Additional metadata used to further identify the element to associate the Annotation with. Examples of fields that could be used if you are using the assets service marker are: - assetVersionId: string (ID of the Asset Version to target within the Asset Manager) - assetVersionNumber: int (Numeric value representing the Version of the Asset to target) |
| string | rootAnnotationId | null if Annotation is a Root Annotation or an Annotation ID of a root annotation if this Annotation is a Reply in a Thread The RootAnnotationId allows for a root/child relationship. These cannot be nested, allowing only for a thread design.. |
| string | text | Text for the Annotation
### Restrictions
- Must be less than 10,000 characters
- Cannot be empty or contain only whitespace characters
- Cannot start or end with whitespace characters
### Mentioning a User
To mention a User, use format |
| Dictionary<string, object> | metadata | Object for holding additional user defined metadata. This is not used within the annotations system, but can be useful for storing information useful for enhancing the annotation within a custom system. This will not be displayed on the web portal currently |
| bool | unresolveRootAnnotation | If creating a reply, set to true to unresolve the rootAnnotation. This is only applicable for annotations in a thread that has been marked as resolved. In other cases it will have no effect |
| List<ICreateAttachmentRequest> | attachments | The attachments that should be created with the annotation. ### Attachment Types These attachments can have multiple types, as defined by the OneOf schema |
| CreateAnnotationStatus? | status | status. |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<AnnotationId> | Task of Annotation ID |
Remarks
Creates a new annotation in the project with a given target.
DeleteAnnotationAsync(ProjectId, AnnotationId, CancellationToken)
Delete annotation
Declaration
Task DeleteAnnotationAsync(ProjectId projectId, AnnotationId annotationId, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The id of the project where the annotation exists. |
| AnnotationId | annotationId | The id of the annotation. |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task | Task of void |
Remarks
Deletes an existing Annotation given the Project Id and Annotation Id.
ReadAllAnnotationsAsync(ProjectId, AssetId, string, int, SortOrder?, CancellationToken)
Read all annotations matching the Asset ID
Declaration
Task<ReadAnnotationsResult> ReadAllAnnotationsAsync(ProjectId projectId, AssetId assetId, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AssetId | assetId | The Asset ID. |
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAllAnnotationsByHashtagAsync(ProjectId, AssetId, List<string>, List<IncludeField>, string, int, SortOrder?, CancellationToken)
Read annotations matching the target with hashtag filtering.
Declaration
Task<ReadAnnotationsResult> ReadAllAnnotationsByHashtagAsync(ProjectId projectId, AssetId assetId, List<string> hashtags = null, List<IncludeField> includeFields = null, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AssetId | assetId | The Asset ID. |
| List<string> | hashtags | List of hashtags to filter annotations by tag. If provided, only annotations containing any of the specified hashtags will be returned. |
| List<IncludeField> | includeFields | Fields to include in the response. Allowed values: "replyUsers", "replyCount", "latestReply", "attachments" |
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAllAnnotationsByMentionAsync(ProjectId, AssetId, List<UserId>, List<IncludeField>, string, int, SortOrder?, CancellationToken)
Read all annotations matching the target with mention filtering.
Declaration
Task<ReadAnnotationsResult> ReadAllAnnotationsByMentionAsync(ProjectId projectId, AssetId assetId, List<UserId> mentions = null, List<IncludeField> includeFields = null, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AssetId | assetId | The Asset ID. |
| List<UserId> | mentions | List of UserIds to filter annotations by mention. If provided, only annotations where any of the specified users have been mentioned will be returned. |
| List<IncludeField> | includeFields | Fields to include in the response. Allowed values: "replyUsers", "replyCount", "latestReply", "attachments" |
| string | next | The pagination token given by the previous fetch (optional). |
| int | limit | The amount of Annotations per page. Default is 10 (optional). |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional). |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAllAnnotationsByProfileAsync(ProjectId, AssetId, List<BaseProfile>, List<IncludeField>, string, int, SortOrder?, CancellationToken)
Read all annotations with profile-based filtering.
Declaration
Task<ReadAnnotationsResult> ReadAllAnnotationsByProfileAsync(ProjectId projectId, AssetId assetId, List<BaseProfile> baseProfile = null, List<IncludeField> includeFields = null, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AssetId | assetId | The Asset ID. |
| List<BaseProfile> | baseProfile | Apply a profile to be used as the basis of the request. Defaults to empty query if not provided. The profiles are applied in order, with later profiles overriding earlier ones in case of conflicts Allowed values: "all", "threads", "active", "resolved", "unresolved", "draft", "sending" |
| List<IncludeField> | includeFields | Fields to include in the response. Allowed values: "replyUsers", "replyCount", "latestReply", "attachments" |
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAnnotationAsync(ProjectId, AnnotationId, CancellationToken)
Read annotation matching the Annotation ID
Declaration
Task<IAnnotation> ReadAnnotationAsync(ProjectId projectId, AnnotationId annotationId, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AnnotationId | annotationId | The Annotation ID. |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<IAnnotation> | Task of Annotation |
ReadAnnotationsAsync(ProjectId, string, string, int, SortOrder?, CancellationToken)
Read annotation matching the given target
Declaration
Task<ReadAnnotationsResult> ReadAnnotationsAsync(ProjectId projectId, string target, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| string | target | Annotations matching the Target will be returned.
Glob-like partial matching on the Target field is supported.
This supports partial matching by appending two wildcard characters (**) at the end of the target path.
For example, retrieving all annotations within a project can be done with:
|
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAnnotationsAsync(ProjectId, AssetId, string, int, SortOrder?, CancellationToken)
Read annotation matching the Asset ID
Declaration
Task<ReadAnnotationsResult> ReadAnnotationsAsync(ProjectId projectId, AssetId assetId, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AssetId | assetId | The Asset ID. |
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAnnotationsByHashtagAsync(ProjectId, string, List<string>, List<IncludeField>, string, int, SortOrder?, CancellationToken)
Read annotations matching the target with hashtag filtering.
Declaration
Task<ReadAnnotationsResult> ReadAnnotationsByHashtagAsync(ProjectId projectId, string target, List<string> hashtags = null, List<IncludeField> includeFields = null, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| string | target | Annotations matching the Target will be returned.
Glob-like partial matching on the Target field is supported.
This supports partial matching by appending two wildcard (**) at the end of the target path.
For example, retrieving all annotations within a project can be done with:
|
| List<string> | hashtags | List of hashtags to filter annotations by tag. If provided, only annotations containing any of the specified hashtags will be returned. |
| List<IncludeField> | includeFields | Fields to include in the response. Allowed values: "replyUsers", "replyCount", "latestReply", "attachments" |
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAnnotationsByHashtagAsync(ProjectId, AssetId, List<string>, List<IncludeField>, string, int, SortOrder?, CancellationToken)
Read annotations matching the target with hashtag filtering.
Declaration
Task<ReadAnnotationsResult> ReadAnnotationsByHashtagAsync(ProjectId projectId, AssetId assetId, List<string> hashtags = null, List<IncludeField> includeFields = null, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AssetId | assetId | The Asset ID. |
| List<string> | hashtags | List of hashtags to filter annotations by tag. If provided, only annotations containing any of the specified hashtags will be returned. |
| List<IncludeField> | includeFields | Fields to include in the response. Allowed values: "replyUsers", "replyCount", "latestReply", "attachments" |
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAnnotationsByMentionAsync(ProjectId, string, List<UserId>, List<IncludeField>, string, int, SortOrder?, CancellationToken)
Read annotations matching the target with mention filtering.
Declaration
Task<ReadAnnotationsResult> ReadAnnotationsByMentionAsync(ProjectId projectId, string target, List<UserId> mentions = null, List<IncludeField> includeFields = null, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| string | target | Annotations matching the Target will be returned.
Glob-like partial matching on the Target field is supported.
This supports partial matching by using two wildcard characters (**) at the end of the target path.
For example, retrieving all annotations within a project can be done with:
|
| List<UserId> | mentions | List of UserIds to filter annotations by mention. If provided, only annotations where any of the specified users have been mentioned will be returned. |
| List<IncludeField> | includeFields | Fields to include in the response. Allowed values: "replyUsers", "replyCount", "latestReply", "attachments" |
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAnnotationsByMentionAsync(ProjectId, AssetId, List<UserId>, List<IncludeField>, string, int, SortOrder?, CancellationToken)
Read annotations with mention filtering.
Declaration
Task<ReadAnnotationsResult> ReadAnnotationsByMentionAsync(ProjectId projectId, AssetId assetId, List<UserId> mentions = null, List<IncludeField> includeFields = null, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AssetId | assetId | The Asset ID. |
| List<UserId> | mentions | List of UserIds to filter annotations by mention. If provided, only annotations where any of the specified users have been mentioned will be returned. |
| List<IncludeField> | includeFields | Fields to include in the response. Allowed values: "replyUsers", "replyCount", "latestReply", "attachments" |
| string | next | The pagination token given by the previous fetch (optional). |
| int | limit | The amount of Annotations per page. Default is 10 (optional). |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional). |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAnnotationsByProfileAsync(ProjectId, string, List<BaseProfile>, List<IncludeField>, string, int, SortOrder?, CancellationToken)
Read annotations matching the target with profile-based filtering.
Declaration
Task<ReadAnnotationsResult> ReadAnnotationsByProfileAsync(ProjectId projectId, string target, List<BaseProfile> baseProfile = null, List<IncludeField> includeFields = null, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| string | target | Annotations matching the Target will be returned.
Glob-like partial matching on the Target field is supported.
This supports partial matching by appending two wildcard (**) at the end of the target path.
For example, retrieving all annotations within a project can be done with:
|
| List<BaseProfile> | baseProfile | Apply a profile to be used as the basis of the request. Defaults to empty query if not provided. The profiles are applied in order, with later profiles overriding earlier ones in case of conflicts Allowed values: "all", "threads", "active", "resolved", "unresolved", "draft", "sending" |
| List<IncludeField> | includeFields | Fields to include in the response. Allowed values: "replyUsers", "replyCount", "latestReply", "attachments" |
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadAnnotationsByProfileAsync(ProjectId, AssetId, List<BaseProfile>, List<IncludeField>, string, int, SortOrder?, CancellationToken)
Read annotations with profile-based filtering.
Declaration
Task<ReadAnnotationsResult> ReadAnnotationsByProfileAsync(ProjectId projectId, AssetId assetId, List<BaseProfile> baseProfile = null, List<IncludeField> includeFields = null, string next = null, int limit = 0, SortOrder? sortingOrder = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AssetId | assetId | The Asset ID. |
| List<BaseProfile> | baseProfile | Apply a profile to be used as the basis of the request. Defaults to empty query if not provided. The profiles are applied in order, with later profiles overriding earlier ones in case of conflicts Allowed values: "all", "threads", "active", "resolved", "unresolved", "draft", "sending" |
| List<IncludeField> | includeFields | Fields to include in the response. Allowed values: "replyUsers", "replyCount", "latestReply", "attachments" |
| string | next | The pagination token given by the previous fetch (optional) |
| int | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadAnnotationsResult> | Task of ReadAnnotationsResult |
ReadRepliesAsync(ProjectId, AnnotationId, string, int?, SortOrder?, StatusFilter?, CancellationToken)
Read annotation matching the Annotation ID
Declaration
Task<ReadRepliesResult> ReadRepliesAsync(ProjectId projectId, AnnotationId annotationId, string next = null, int? limit = null, SortOrder? sortingOrder = null, StatusFilter? statusFilter = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The Project ID. |
| AnnotationId | annotationId | The Annotation ID. |
| string | next | The pagination token given by the previous fetch (optional) |
| int? | limit | The amount of Annotations per page. Default is 10 (optional) |
| SortOrder? | sortingOrder | Sorting order for annotations in the response. Default is Ascending (optional) |
| StatusFilter? | statusFilter | Filter search results for Status of Annotations. Default is All. (optional) |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task<ReadRepliesResult> | Task of ReadRepliesResult |
RemoveFieldsFromAnnotationMetadataAsync(ProjectId, AnnotationId, List<string>, CancellationToken)
Remove one or several metadata field(s) from annotation custom metadata
Declaration
Task RemoveFieldsFromAnnotationMetadataAsync(ProjectId projectId, AnnotationId annotationId, List<string> metadataFields = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The id of the project where the annotation belongs |
| AnnotationId | annotationId | The ID of the annotation |
| List<string> | metadataFields | The metadata field name(s) to remove from custom metadata |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task | Task of void |
ResolveAnnotationAsync(ProjectId, AnnotationId, CancellationToken)
Resolve annotation.
Declaration
Task ResolveAnnotationAsync(ProjectId projectId, AnnotationId annotationId, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The project id. |
| AnnotationId | annotationId | The Id of the Annotation to resolve. |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task | Task of void |
Remarks
Resolves a thread, given a Project Id and Annotation Id for the Root Annotation.
UnresolveAnnotationAsync(ProjectId, AnnotationId, CancellationToken)
Unresolve annotation.
Declaration
Task UnresolveAnnotationAsync(ProjectId projectId, AnnotationId annotationId, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The project id. |
| AnnotationId | annotationId | The Id of the Annotation to unresolve. |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task | Task of void |
Remarks
Unresolves a thread, given a Project Id and Annotation Id for the Root Annotation.
UpdateAnnotationAsync(ProjectId, AnnotationId, string, CancellationToken)
Update annotation
Declaration
Task UpdateAnnotationAsync(ProjectId projectId, AnnotationId annotationId, string text = null, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | The id of the project where the annotation exists. |
| AnnotationId | annotationId | The id of the annotation. |
| string | text | Comment text. Restrictions: - Text cannot be empty, use null instead. - Text is limited to 10,000 characters. - Text cannot start or end with whitespace characters. This field can also be used to direct notifications, using the Mentions format detailed in the Annotation description.. |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request. |
Returns
| Type | Description |
|---|---|
| Task | Task of void |
Remarks
Updates an existing Annotation given the Project Id and Annotation Id.
UpdateAnnotationStatusAsync(ProjectId, AnnotationId, UpdateAnnotationStatus, CancellationToken)
Update annotation status
Declaration
Task UpdateAnnotationStatusAsync(ProjectId projectId, AnnotationId annotationId, UpdateAnnotationStatus targetStatus, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| ProjectId | projectId | example="e5a3ca16-13c7-4f2d-a5bb-984e349911df" The id of the project where the annotation exists |
| AnnotationId | annotationId | example="6669ea106d57178f6d028ab8" The id of the annotation |
| UpdateAnnotationStatus | targetStatus | The status controls whether the annotation is considered fully published and available to all users Possible values: "Active", "Sending", "Draft" |
| CancellationToken | cancellationToken | Cancellation Token to cancel the request |
Returns
| Type | Description |
|---|---|
| Task | Task of void |
Remarks
Updates an existing Annotation status given the Project Id and Annotation Id and Target status. The following status transitions are allowed: Draft → Sending. Draft → Active. Sending → Draft. Sending → Active.