Serverless database REST API v2 is slightly different from the legacy one.
Migrating from the legacy /base
API to the v2 REST API
The following table gives a correspondence between legacy calls and API v2 ones:
legacy API | API v2 |
---|---|
Write data |
|
curl -X PUT -H 'Content-Type: application/json' "https://io.datasync.orange.com/base/<application>/<path/of/your/data>.json" -d '<JSON data>' |
curl -X PUT -H 'Content-Type: application/json' "https://io.datasync.orange.com/datasync/v2/<application>/data/<path/of/your/data>" -d '<JSON data>' |
Read data |
|
curl –X GET "https://io.datasync.orange.com/base/<application>/<path/of/your/data>.json" |
curl –X GET "https://io.datasync.orange.com/datasync/v2/<application>/data/<path/of/your/data>" |
Delete data |
|
curl –X DELETE "https://io.datasync.orange.com/base/<application>/<path/of/your/data>.json" |
curl –X DELETE "https://io.datasync.orange.com/datasync/v2/<application>/data/<path/of/your/data>" |