@@ -122,6 +122,21 @@ export class StringComments extends CrowdinApi {
122122 const url = `${ this . url } /projects/${ projectId } /comments` ;
123123 return this . patch ( url , request , this . defaultConfig ( ) ) ;
124124 }
125+
126+ /**
127+ * @param projectId project identifier
128+ * @param stringCommentId string comment identifier
129+ * @param attachmentId attachment identifier
130+ * @see https://developer.crowdin.com/api/v2/#operation/api.projects.comments.attachments.delete
131+ */
132+ deleteStringCommentAttachment (
133+ projectId : number ,
134+ stringCommentId : number ,
135+ attachmentId : number ,
136+ ) : Promise < ResponseObject < StringCommentsModel . StringComment > > {
137+ const url = `${ this . url } /projects/${ projectId } /comments/${ stringCommentId } /attachments/${ attachmentId } ` ;
138+ return this . delete ( url , this . defaultConfig ( ) ) ;
139+ }
125140}
126141
127142export namespace StringCommentsModel {
@@ -159,6 +174,18 @@ export namespace StringCommentsModel {
159174 resolver : User ;
160175 resolvedAt : string ;
161176 createdAt : string ;
177+ attachments ?: Attachment [ ] ;
178+ }
179+
180+ export interface Attachment {
181+ id : number ;
182+ name : string ;
183+ mime : string ;
184+ size : number ;
185+ category : string ;
186+ thumbnailUrl : string | null ;
187+ url : string ;
188+ downloadUrl : string ;
162189 }
163190
164191 export interface User {
@@ -185,6 +212,11 @@ export namespace StringCommentsModel {
185212 type : Type ;
186213 isShared ?: boolean ;
187214 issueType ?: IssueType ;
215+ attachments ?: AttachmentRequest [ ] ;
216+ }
217+
218+ export interface AttachmentRequest {
219+ id : number ;
188220 }
189221
190222 export type Type = 'comment' | 'issue' ;
0 commit comments