API "Get cached Export"

Hello,

I use the backend API to export a file from our ShapeDiver file

When it’s working, I get the URL of the exported file in {ID_export} > content > href

Because of response time, the export file can failed at the first run.
So I need to run the same API call 2 or 3 times to get the file.
The problem is that, the API do not return the href
But I can see in the “Actions” : “title”:“Get cached export”

How to run again the samed API call without having the cache
Or
How to get the URL of the cached export file?

Example of return :

{"version":"2.11.1","actions":[{"name":"default","title":"Default model","href":"https://sdr7euc1-nocdn.eu-central-1.shapediver.com/api/v2/session/c70e9de2-3e5b-4740-a791-f0bc51da7f87/default","method":"GET"},{"name":"close","title":"Close session","href":"https://sdr7euc1-nocdn.eu-central-1.shapediver.com/api/v2/session/c70e9de2-3e5b-4740-a791-f0bc51da7f87/close","method":"POST"},{"name":"export-cache","title":"Get cached export","href":"https://sdr7euc1-nocdn.eu-central-1.shapediver.com/api/v2/session/c70e9de2-3e5b-4740-a791-f0bc51da7f87/export/cache","template":"export-cache-request","method":"PUT"}],"exports":{"836fbd6cf9934dda83c65fb4a89fa911":{"id":"836fbd6cf9934dda83c65fb4a89fa911","name":"exp_2d_dxf","type":"download","uid":"bfba8e53b6d379a1cc1fda5b86dde63d","dependency":["781867f9-787e-4f99-a2a4-4a3de1abcd0e","964c140b-b468-4b0b-845a-e417fc24c4fa","84add694-6430-4c26-b56e-769384a713dd","af8e1171-d86b-485d-8ccc-927e95aa7e11","69130869-5308-4e6e-b3ee-6c44d25cee94","e4d9fefc-bcac-4e1c-b37e-e4e0c2fac3a7","40be53d7-11ef-4ed3-bdec-44c8fc5e03db","5c030e7b-a0fc-4f67-a363-2432e6827fec","a8db75db-0d64-4336-8453-15d3c6df5837","88bf7b4b-3568-46d0-bc66-14def3bfc0ae","42c2dbb8-1eb6-4a0e-befc-731f00971304","33c9534f-ce52-4784-a29a-f7e06dfc694e","afefe2b4-7712-4b72-ae29-57c94e56a7c7","8a2a1208-80d8-4627-9c00-4c193534958b","fff4fbbb-d91e-48c3-9e31-d66a06a48097","4599e8ad-4395-447b-bd0a-1213af287b8a","343f82c8-12da-4fed-b502-ec524e296fcb","2f73a4b1-85bc-4011-aa71-880a398583e7","5e26890a-d7df-4a0f-813a-a90637637079","f642b00e-2864-4900-b62b-aed4900b3e0f","42b3648c-d88b-452a-82d8-0295b9aeb423","eb8a262e-686e-4d88-8c39-2629ced92aaa","9289df8e-b345-49a8-a3a3-818a94525794","f7fdaf20-b488-43db-a57d-e49e26632307","1aabcd59-4d3c-457a-9839-e8d38b8e631e","8a1c8345-3bc2-41e3-b91e-96fd362aa495","cc0b79f9-b2dd-409c-909a-2cdaf8b60535","824c6d36-2afa-43ab-b85b-65c57a8f97f9","d9477baf-e5d7-4862-8c26-0c87ba9ae70a","02c41cd9-a494-4a48-abe4-f3bdfc842390","7ca57a66-45a9-46b4-acda-91fb63df743d","2194ae93-6012-4be9-90d8-f83f37f8db05","876210b5-aef2-470a-9744-90a498e305cd","2bbf22e3-b10e-4a57-9951-28dff93217a9","82451530-c2ae-4954-a62a-dc4f4feb9930","ba20e3de-3a0a-4665-9bb4-4fbb74c7357a","61d5ad2e-6d90-4d62-a237-ea2fc34c8c64","1a54385d-d8d6-425e-92c7-da9fa69f8fde","aaa234fa-8ae3-42ce-b287-ca309c09d0d6","57a790fc-b7bf-477e-a6c9-3dd63d7e7114","975f307b-c361-443b-a288-678dcf70a2de","82fe8fc0-a712-4412-8136-7b7286000514","05861aad-4d19-4da4-af26-9e7eeb90c3ed","ba9d634e-5af2-43b9-a36e-f48b035e873c","4916e043-a92e-4a58-8322-c2fdf9899449","e83eaee5-60dd-480d-bb4c-11f1ced8d072","06fd8537-46ab-460f-93a6-8155c694683f","77dc225f-66fd-4d4a-a5c3-3df233412601","e9460769-4859-4261-9111-c901cbcf78ca","f6226886-0ce3-46a0-80b0-6592ad22f3d6","24b6da0b-6c55-4b74-ba1a-92866265017b","f5930de8-a30f-4dee-a202-02ef02c7bca6","81a1de93-9510-4dea-ade1-bca5505a135c","02e5cb3d-a39e-4f43-99b2-5a8ef87dd346","fe8511d8-7eda-49cb-8861-c88cafa7b48c","c5959daa-37f0-4f51-bba8-600d8de92f0c","04073776-ed5c-489b-8ba9-8a57212b1c5d","dc2c2fae-c946-439f-8724-9a333213769e","a974b018-8306-4837-8c2e-c14fc3deec37","fc909447-b518-4ee0-a591-bf8c6a6c2f5b","37f9a924-7ac0-4295-87bb-deefd40c1953","65e3c484-a70a-4437-9626-6be3fc1278df","0f2c46de-d747-448f-bd04-0900df3e6863","bc33f8cd-1dd6-4428-8922-d6ce88557c27","b2fc102a-9eb3-448f-8ca7-563b87a3a2a7","21714de9-65d5-40de-988b-69907214433e","63d254f9-c5d5-4b9a-ae68-503568dd53d8"],"group":{"id":"8e24822f-c027-4e66-b032-cb74ab145577","name":"export_2d_dxf"},"version":"0046d9bc4a1d2a7815dd545f6a4af80f","order":0,"tooltip":"","displayname":"","hidden":false,"delay":5292}},"templates":[{"name":"export-cache-request","title":"Template for export-cache action","data":{"836fbd6cf9934dda83c65fb4a89fa911":"0046d9bc4a1d2a7815dd545f6a4af80f"}}]}	

@olivia3 are you using our Geometry Backend SDK to make the request? If so, please provide details about the call you are using. Note that the SDK handles the cache requests for you (should they be necessary), and therefore simplifies implementation on your end.

In case you are calling the API directly, please provide more details on the API call you are making:

  • request URL
  • request body

When calling the API directly, make sure you specify the max_wait_time parameter in the request body. However, please be aware that even when using a high value for max_wait_time there is no guarantee that you won’t have to use an export cache request. As an example, this can happen if the export request has to wait a bit before being processed. As mentioned above, using the SDK simplifies this.

Thanks !

I managed to get the request from cache thanks to
[ShapeDiver Geometry Backend API v2](https://export cache request)