Creating a database

You'll learn how to create a database using Control Panel or API.


Creating a database via Control Panel

To create a new database using the Control Panel, access the Databases section and click on Create new database. A 5-step wizard will appear.

The Step 1 is where you'll need to provide basic database information, like name, type and pricing model.

Screenshot of Step 1 of Creating a database

Field Mandatory Description
Database Name Yes The name of your database. Can be edited at any time.
Database Labels/Tabs No Possible labels/tags you might want to associate to a database, in order to organize it. Can be edited at any time.
Database Description No The description of your database. Can be edited at any time.
Cloud Provider/Region No The cloud provider and its supported region that will be used to store and query your data. Cannot be edited after creation.
Database Type Yes Can either be Test or Production. It's only possible to change a Test database to Production, not the other way around.
Pricing Model Yes The pricing model you want to use for your database. Can be changed at any time.
Insertion Load Yes The insertion throughput you want your database to have. Can be changed at any time.
Query Load Yes The query throughput you want your database to have. Can be changed at any time.

These parameters in the first step are the basic ones that you need to create a database.
Notice that in the following steps you'll be able to define other parameters such as your schema definition, IP whitelist and Custom Database Keys creation. You'll be able to define and edit these steps later, check how to do it accessing the modeling a database schema and securing a database guides.
This way you can ignore the steps 2,3 and 4 if you want by clicking on Save & Continue until completion.


Creating a database via API

To create a database using API, you'll need to send a POST request to our /database API Endpoint, like the following example.


    curl -X POST https://api.slicingdice.com/v1/database \
    -H 'Authorization: TEAM_API_KEY' \
    -H 'Content-Type: application/json' \
    -d '{
    	"database": {
      		"name": "UsersDB",
      		"description": "Database to store users data",
      		"type": "test",
      		"pricing-model": "pay-per-column",
      		"labels": ["financialdb", "technicaldb"],
      		"query-load": "normal",
      		"insertion-load": "high",
            "cloud_provider": "ovh",
            "cloud_area": "global"
    		},
    	"addresses-whitelist": ["192.168.0.1", "192.168.0.2"]
}'
    

You can check details and possible configuration about each one of these parameters accessing the database creation API reference.


Cloud providers and areas

SlicingDice can be stored in many cloud platforms. We run the instance in the cloud providers, and only selected areas that have at least 3 availability zones.
Below is a table that shows the cloud provider's and its available cloud areas.

Cloud Provider API cloud_provider API cloud_area
Alibaba Cloud alibaba-cloud cn-beijing (Beijing, China)
cn-hangzhou (Hangzhou, China)
cn-shanghai (Shanghai, China)
cn-shenzhen (Shenzhen, China)
ap-southeast-1 (Singapore)
Google Cloud google-cloud asia-east1 (Changhua, Taiwan)
asia-east2 (Hong Kong)
asia-northeast1 (Tokyo, Japan)
asia-south1 (Mumbai, India)
asia-southeast1 (Juron West, Singapore)
australia-southeast1 (Sydney, Australia)
europe-north1 (Hamina, Finland)
europe-west1 (St. Ghislain, Belgium)
europe-west2 (London, England)
europe-west3 (Frankfurt, Germany)
europe-west4 (Eemshaven, Netherlands)
northamerica-northeast1 (Montreál, Canada)
southamerica-east1 (São Paulo, Brazil)
us-central1 (Council Bluffs, Iowa, USA)
us-east1 (Moncks Corner, South Carolina, USA)
us-east4 (Ashburn, Northern Virginia, USA)
us-west1 (The Dalles, Oregon, USA)
us-west2 (Los Angeles, California, USA)
Amazon Web Services aws us-east1 (North Virginia, USA)
us-east2 (Ohio, USA)
us-west1 (North California, USA)
us-west2 (Oregon, USA)
ap-southeast-1 (Singapore)
ap-southeast-2 (Sydney, Australia)
ap-northeast-1 (Tokyo, Japan)
eu-central-1 (Frankfurt, Germany)
eu-west-1 (Ireland)
eu-west-2 (London, England)
eu-west-3 (Paris, France)
eu-north-1 (Stockholm, Sweden)
sa-east-1 (São Paulo, Brazil)
Microsoft Azure azure us-central (Iowa, USA)
us-east2 (Virginia, USA)
fr-central (Paris, France)
eu-north (Ireland)
ap-southeast-1
eu-west (Netherlands)
us-west2 (Washington, USA)
OVH ovh global (Canada, Germany, and France)