diff options
author | 2024-08-02 13:41:46 +0200 | |
---|---|---|
committer | 2024-08-02 12:41:46 +0100 | |
commit | 7b5917d6ae48f83c92f92d7277960cfa6ae8ec56 (patch) | |
tree | 93ee6999195060714f41f9b9476d4d76ad50520c /docs/api | |
parent | [chore] Take account of rotation data when calculating full size image dimens... (diff) | |
download | gotosocial-7b5917d6ae48f83c92f92d7277960cfa6ae8ec56.tar.xz |
[feature] Allow import of following and blocks via CSV (#3150)
* [feature] Import follows + blocks via settings panel
* test import follows
Diffstat (limited to 'docs/api')
-rw-r--r-- | docs/api/swagger.yaml | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/docs/api/swagger.yaml b/docs/api/swagger.yaml index 1d5b80ed1..9c21a0a31 100644 --- a/docs/api/swagger.yaml +++ b/docs/api/swagger.yaml @@ -7128,6 +7128,55 @@ paths: summary: Get an array of all hashtags that you currently follow. tags: - tags + /api/v1/import: + post: + consumes: + - multipart/form-data + description: |- + This can be used to migrate data from a Mastodon-compatible CSV file to a GoToSocial account. + + Uploaded data will be processed asynchronously, and not all entries may be processed depending + on domain blocks, user-level blocks, network availability of referenced accounts and statuses, etc. + operationId: importData + parameters: + - description: The CSV data file to upload. + in: formData + name: data + required: true + type: file + - description: |- + Type of entries contained in the data file: + - `following` - accounts to follow. - `blocks` - accounts to block. + in: formData + name: type + required: true + type: string + - default: merge + description: |- + Mode to use when creating entries from the data file: + - `merge` to merge entries in file with existing entries. - `overwrite` to replace existing entries with entries in file. + in: formData + name: mode + type: string + produces: + - application/json + responses: + "202": + description: Upload accepted. + "400": + description: bad request + "401": + description: unauthorized + "406": + description: not acceptable + "500": + description: internal server error + security: + - OAuth2 Bearer: + - write:accounts + summary: Upload some CSV-formatted data to your account. + tags: + - import-export /api/v1/instance: get: operationId: instanceGetV1 |