Upload callback
Baidu AI Cloud Object Storage (BOS) supports callbacks to application servers upon file (object) upload completion. To enable callbacks, you only need to include the appropriate callback parameters in your requests to BOS.
Application scenarios
One common use case for upload callbacks is to combine them with authorized third-party uploads. Leveraging the upload callback mechanism can significantly reduce the client’s logical complexity and network consumption.
Limitations
Currently, only regular uploads (PutObject) and complete multipart uploads (CompleteMultipartUpload) are supported.
Upload callback process flow

- When a user uploads a file (object) to BOS using the client, they specify the callback parameters for the server side;
- After the file is uploaded successfully, the BOS server will send an HTTP request to the specified application server for callback. The request can include system-defined parameters (such as bucket name, object name, etc.) and custom callback parameters (e.g., the ID of the user who initiated the request);
- The application server can receive the upload completion notification in a timely manner, then complete operations such as database modification, and return the upload callback result to BOS;
Once the callback request receives a response from the server side, the BOS server sends the status back to the original client.
Call methods
Use API
If your program has high custom requirements, you can directly initiate a REST API request. Initiating a REST API request directly requires manually writing code to calculate the signature. For more information, please refer to Callback.
