All URIs are relative to https://api.evermind.ai
| Method | HTTP request | Description |
|---|---|---|
| sign_objects | POST /api/v2/object/sign | Get multimodal upload URLs |
SignEnvelope sign_objects(sign_request)
Get multimodal upload URLs
Presign a direct-to-storage upload for multimodal data. POST the file to the returned URL yourself, then reference the returned object key as a message's content uri (/api/v2/memory/add) or as a document's content uri (.../documents). Uploading first and passing the key is the only path that gets a non-text item parsed — see base64 on the content object. The Python SDK's upload() does both steps in one call.
- Bearer Authentication (BearerAuth):
import everos_cloud
from everos_cloud.models.sign_envelope import SignEnvelope
from everos_cloud.models.sign_request import SignRequest
from everos_cloud.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to https://api.evermind.ai
# See configuration.py for a list of all supported configuration parameters.
configuration = everos_cloud.Configuration(
host = "https://api.evermind.ai"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure Bearer authorization: BearerAuth
configuration = everos_cloud.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with everos_cloud.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = everos_cloud.StorageApi(api_client)
sign_request = everos_cloud.SignRequest() # SignRequest |
try:
# Get multimodal upload URLs
api_response = api_instance.sign_objects(sign_request)
print("The response of StorageApi->sign_objects:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling StorageApi->sign_objects: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| sign_request | SignRequest |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | Envelope response (MMS returns HTTP 200 for every business outcome; only unmatched routes return 404). `status: 0` means success and `result.data` is a SignResponse. Non-zero `status` values seen on this endpoint: - `20003` — request body bind failure (malformed JSON). - `2018` — parameter validation failed (e.g. missing `objectList`, `fileId`, `fileName`, or `fileType`); `result.data` is the validator error string. - `1012` — `mms-token` missing, invalid, expired, or revoked (emitted by the auth middleware before the handler runs). - `1013` — token lacks the required `object:sign` scope. - `1007` — `objectList` exceeds the per-request limit of 50. - `1002` — `fileType` not one of image/video/file. - `1009` — duplicate `fileId` within the request. - `1004` — S3 operation failed (bucket unavailable). - `1005` — presigned POST generation failed. - `2015` — object metadata persistence failed. - `20001` — unhandled internal server error. | - |
| 401 | Missing or invalid bearer token. | - |
| 403 | Authenticated but not permitted — either rejected by the auth service, or the account's memory API version does not match the interface version implied by the path (a v1 account calling an /api/v2 route). | - |
| 429 | Rate limit or quota exceeded. | - |
| 503 | The gateway could not reach the authentication service. Transient — retry with backoff. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]