updateRepoExtensionFile
Move an extension file to another path, rewrite it or name another attachment blob for its bytes, or both.
PATCH
/repos/{repo_id}/branches/{branch}/extensions/{name}/files/{file_id}Path parameters
Request body JSON required
Returns
200
ExtensionFile
JSON
- formatted_contentrequired
The file formatted with Prettier for reading, when that differs from
content. Forge formats a file shortly after it's written, so this is null until then, and stays null when the file is already formatted, isn't TypeScript, JavaScript or JSON, is over 256 KiB, or doesn't parse. Writes never take it, and builds read onlycontent, so edit fromcontent.
400
InvalidRequest | RequestBodyTooDeep
JSON
One of the following:
- InvalidRequestEncoded
- RequestBodyTooDeepEncoded
403
Forbidden | ForbiddenOrigin | RequiresPersonalSession | RunBranchRequired
JSON
One of the following:
- ForbiddenEncoded
- ForbiddenOriginEncoded
- RequiresPersonalSessionEncoded
- RunBranchRequiredEncoded
404
BranchNotFound | ExtensionFileNotFound | ExtensionNotFound | RepoNotFound
JSON
One of the following:
- BranchNotFoundEncoded
- ExtensionFileNotFoundEncoded
- ExtensionNotFoundEncoded
- RepoNotFoundEncoded
409
ExtensionFileBlobNotUploaded | RepoArchived
JSON
One of the following:
- ExtensionFileBlobNotUploadedEncoded
- RepoArchivedEncoded
413
ExtensionFileTooLarge | WriteTooLarge | RequestBodyTooLarge
JSON
One of the following:
- ExtensionFileTooLargeEncoded
- WriteTooLargeEncoded
- RequestBodyTooLargeEncoded
503
AttachmentStorageUnavailable | RepoBusy | SessionUnavailable | RateLimitUnavailable
JSON
One of the following:
- AttachmentStorageUnavailableEncoded
- RepoBusyEncoded
- SessionUnavailableEncoded
- RateLimitUnavailableEncoded