TemplatesApi

TemplatesApi

All URIs are relative to https://api.ionos.com/databases/mongodb

Method
HTTP request
Description

GET /templates

Get Templates

templates_get

TemplateList templates_get(limit=limit, offset=offset)

Get Templates

Retrieves a list of valid templates. These templates can be used to create MongoDB clusters; they contain properties, such as number of cores, RAM, and the storage size.

Example

from __future__ import print_function
import time
import ionoscloud_dbaas_mongo
from ionoscloud_dbaas_mongo.rest import ApiException

# Defining the host is optional and defaults to https://api.ionos.com/databases/mongodb
configuration = ionoscloud_dbaas_mongo.Configuration(
    host = 'https://api.ionos.com/databases/mongodb',
)

# Example of configuring HTTP Basic Authorization
configuration.username = 'YOUR_USERNAME'
configuration.password = 'YOUR_PASSWORD'

with ionoscloud_dbaas_mongo.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = ionoscloud_dbaas_mongo.TemplatesApi(api_client)
    try:
        # Get Templates
        api_response = api_instance.templates_get()
        print(api_response)
    except ApiException as e:
        print('Exception when calling TemplatesApi.templates_get: %s\n' % e)

Parameters

Name
Type
Description
Notes

limit

int

The maximum number of elements to return. Use together with 'offset' for pagination.

[optional] [default to 100]

offset

int

The first element to return. Use together with 'limit' for pagination.

[optional] [default to 0]

Return type

TemplateList

Authorization

basicAuth, tokenAuth

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

Last updated