Report this

What is the reason for this report?

Where can i find slug identifier for size while creating droplet by API

Posted on January 25, 2022

I found php script to create droplet by API but it only creates shared type of droplet… i need to dynamically change slug identifier in API. But i didn’t find any explanation for “Size slug identifier” in API documentation mentioned at https://docs.digitalocean.com/reference/api/api-reference/#operation/create_droplet Anyone please know how can i pass Size value to create cpu and memory optimized droplet.



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hello @jotjpn ,

The slugs for different Droplet plans can be found here https://slugs.do-api.dev/

You can also check the available sizes with the following API https://docs.digitalocean.com/reference/api/api-reference/#operation/list_all_sizes

The desired size can be provided in the ‘size’ field when creating a new Droplet. https://docs.digitalocean.com/reference/api/api-reference/#operation/create_droplet

Hope this helps!

Cheers, Lalitha

To list all of available Droplet sizes, send a GET request to /v2/sizes.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.