@@ -133,16 +133,38 @@ public class UserOperations : IUserOperations
133133 public Task < UserEntity > ActivateUserAsync ( ActivateUserEntity entity , CancellationToken cancellationToken = default ( CancellationToken ) ) {
134134 return _client . RequestJsonSerializedAsync < ActivateUserEntity , UserEntity > ( HttpMethod . Post , "user/activate" , entity , cancellationToken ) ;
135135 }
136+
137+ /// <summary>
138+ /// Adds an endpoint entity.
139+ /// </summary>
140+ /// <param name="entity">The endpoint add entity.</param>
141+ /// <param name="cancellationToken">The cancellation token.</param>
142+ /// <remarks>This operation is internal and won't work with normal API keys. Nor is it stable.</remarks>
143+ /// <returns>The endpoint entity.</returns>
144+ public Task < EndpointEntity > AddEndpointAsync ( EndpointAddEntity entity , CancellationToken cancellationToken = default ( CancellationToken ) ) {
145+ return _client . RequestJsonSerializedAsync < EndpointAddEntity , EndpointEntity > ( HttpMethod . Post , "user/endpoint/add" , entity , cancellationToken ) ;
146+ }
136147
137148 /// <summary>
138- /// Adds a user notification token to the current user .
149+ /// Gets an endpoint entity .
139150 /// </summary>
140- /// <param name="entity">The entity.</param>
151+ /// <param name="endpointUuid">The endpoint UUID.</param>
152+ /// <param name="cancellationToken">The cancellation token.</param>
153+ /// <returns>The endpoint entity.</returns>
154+ public Task < EndpointEntity > GetEndpointAsync ( Guid endpointUuid , CancellationToken cancellationToken = default ( CancellationToken ) ) {
155+ return _client . RequestJsonSerializedAsync < EndpointEntity > ( HttpMethod . Get , $ "user/endpoint/{ endpointUuid } ", cancellationToken ) ;
156+ }
157+
158+ /// <summary>
159+ /// Edits an endpoints notification token.
160+ /// </summary>
161+ /// <param name="endpointUuid">The endpoint UUID.</param>
162+ /// <param name="entity">The endpoint add notification entity.</param>
141163 /// <param name="cancellationToken">The cancellation token.</param>
142164 /// <remarks>This operation is internal and won't work with normal API keys. Nor is it stable.</remarks>
143165 /// <returns></returns>
144- public Task AddUserNotificationAsync ( UserNotificationAddEntity entity , CancellationToken cancellationToken = default ( CancellationToken ) ) {
145- return _client . RequestJsonSerializedAsync ( HttpMethod . Post , "user/notification/add " , entity , cancellationToken ) ;
166+ public Task EditEndpointNotificationAsync ( Guid endpointUuid , EndpointEditNotificationEntity entity , CancellationToken cancellationToken = default ( CancellationToken ) ) {
167+ return _client . RequestJsonSerializedAsync ( HttpMethod . Post , $ "user/endpoint/ { endpointUuid } /push_notification ", entity , cancellationToken ) ;
146168 }
147169
148170 /// <summary>
0 commit comments