LoopBack 3 has reached end of life. We are no longer accepting pull requests or providing support for community users. The only exception is fixes for critical bugs and security vulnerabilities provided as part of support for IBM API Connect customers. We urge all LoopBack 3 users to migrate their applications to LoopBack 4 as soon as possible. Learn more about LoopBack's long term support policy.

Storage component REST API

Edit this page
The LoopBack storage component enables you to upload and download files to cloud storage providers and the local (server) file system. It has Node.js and REST APIs.
Page Contents

List containers

List all containers for the current storage provider.

GET /api/containers

Arguments

None.

Get container information

Get information about specified container.

GET /api/containers/<container-name>

Arguments

  • <container-name> - name of container for which to return information.

Create container

Create a new container with the current storage provider.

POST /api/containers

Arguments

Container specification in POST body.

Delete container

Delete the specified container.

DELETE /api/containers/<container-name>

Arguments

  • <container-name> - name of container to delete.

List files in container

List all files within a given container by name.

GET /api/containers/<container-name>/files

Arguments

  • <container-name> - name of container for which to list files.

Get file information

Get information for a file within a given container by name

GET /api/containers/<container-name>/files/file-name

Arguments

  • <container-name> - name of container.
  • file-name - name of file for which to get information.

Delete file

Delete specified file within specified container.

DELETE /api/containers/container-name/files/file-name

Arguments

  • <container-name> - name of container.
  • file-name - name of file to delete.

Upload files

Upload one or more files into the given container by name. The request body should use multipart/form-data which the file input type for HTML uses.

POST /api/containers/container-name/upload

Arguments

  • <container-name> - name of container to which to upload files.

Download file

Download specified file within specified container.

GET /api/containers/container-name/download/file-name

Arguments

  • <container-name> - name of container from which to download file.
  • file-name - name of file to download.

AltStyle によって変換されたページ (->オリジナル) /