# RegistriesApi

All URIs are relative to *<https://api.ionos.com/containerregistries>*

| Method                                        | HTTP request                        | Description                            |
| --------------------------------------------- | ----------------------------------- | -------------------------------------- |
| [**registriesDelete**](#registriesdelete)     | **DELETE** /registries/{registryId} | Delete registry                        |
| [**registriesFindById**](#registriesfindbyid) | **GET** /registries/{registryId}    | Get a registry                         |
| [**registriesGet**](#registriesget)           | **GET** /registries                 | List all container registries          |
| [**registriesPatch**](#registriespatch)       | **PATCH** /registries/{registryId}  | Update the properties of a registry    |
| [**registriesPost**](#registriespost)         | **POST** /registries                | Create container registry              |
| [**registriesPut**](#registriesput)           | **PUT** /registries/{registryId}    | Create or replace a container registry |

## registriesDelete

> registriesDelete(registryId)

Delete registry

### Examples

```javascript
const ionoscloud = require('@ionos-cloud/sdk-nodejs-container-registry');
// setup authorization
const config = new ionoscloud.Configuration({
    username: 'YOUR_USERNAME',
    password: 'YOUR_PASSWORD',
    apiKey: 'YOUR_API_KEY'
});
const api_instance = new ionoscloud.RegistriesApi(config);
// Delete registry
api_instance
  .registriesDelete({
    registryId: 38400000-8cf0-11bd-b23e-10b96e4ef00d
  })
  .then((response) => console.log(response.data))
  .catch((error) => console.log(error.response.data));
```

### Parameters

| Name           | Type                                                                                                             | Description                   | Notes                   |
| -------------- | ---------------------------------------------------------------------------------------------------------------- | ----------------------------- | ----------------------- |
| **registryId** | [**string**](https://github.com/ionos-cloud/sdk-nodejs-container-registry/blob/master/docs/models/.md/README.md) | The unique ID of the registry | \[default to undefined] |

### Return type

nil (empty response body)

### Authorization

basicAuth, tokenAuth

### HTTP request headers

* **Content-Type**: Not defined
* **Accept**: application/json

## registriesFindById

> registriesFindById(registryId)

Get a registry

Get all information for a specific container registry

### Examples

```javascript
const ionoscloud = require('@ionos-cloud/sdk-nodejs-container-registry');
// setup authorization
const config = new ionoscloud.Configuration({
    username: 'YOUR_USERNAME',
    password: 'YOUR_PASSWORD',
    apiKey: 'YOUR_API_KEY'
});
const api_instance = new ionoscloud.RegistriesApi(config);
// Get a registry
api_instance
  .registriesFindById({
    registryId: 38400000-8cf0-11bd-b23e-10b96e4ef00d
  })
  .then((response) => console.log(response.data))
  .catch((error) => console.log(error.response.data));
```

### Parameters

| Name           | Type                                                                                                             | Description                   | Notes                   |
| -------------- | ---------------------------------------------------------------------------------------------------------------- | ----------------------------- | ----------------------- |
| **registryId** | [**string**](https://github.com/ionos-cloud/sdk-nodejs-container-registry/blob/master/docs/models/.md/README.md) | The unique ID of the registry | \[default to undefined] |

### Return type

[**RegistryResponse**](/container-registry-sdk-nodejs/models/registryresponse.md)

### Authorization

basicAuth, tokenAuth

### HTTP request headers

* **Content-Type**: Not defined
* **Accept**: application/json

## registriesGet

> registriesGet(opts)

List all container registries

List all managed container registries for your account

### Examples

```javascript
const ionoscloud = require('@ionos-cloud/sdk-nodejs-container-registry');
// setup authorization
const config = new ionoscloud.Configuration({
    username: 'YOUR_USERNAME',
    password: 'YOUR_PASSWORD',
    apiKey: 'YOUR_API_KEY'
});
const api_instance = new ionoscloud.RegistriesApi(config);
var filterMap = new Map()
filterMap.set("<property_name>", "<property_value>")
// List all container registries
api_instance
  .registriesGet({
    filterName: my-registry,
    limit: limit_example,
    paginationToken: eyJ2IjoibWV0YS5rOHMuaW8vdjEiLCJydiI6MTYzMjQ0OTk2ODAsInN0YXJ0IjoiM2RmYTc3YjctZGIwNS00MjMwLThmMjAtOGU3NjJlOTUxOTUzXHUwMDAwIn0
    maxResults: 2,
    filters: filterMap
    options: {}
  })
  .then((response) => console.log(response.data))
  .catch((error) => console.log(error.response.data));
```

### Parameters

| Name                | Type       | Description                                                                                   | Notes                              |
| ------------------- | ---------- | --------------------------------------------------------------------------------------------- | ---------------------------------- |
| **filterName**      | **string** | The registry name to search for                                                               | \[optional]\[default to undefined] |
| **limit**           | **string** | The maximum number of elements to return (used together with pagination.token for pagination) | \[optional]\[default to '100']     |
| **paginationToken** | **string** | An opaque token used to iterate the set of results (used together with limit for pagination)  | \[optional]\[default to undefined] |

### Return type

[**RegistriesResponse**](/container-registry-sdk-nodejs/models/registriesresponse.md)

### Authorization

basicAuth, tokenAuth

### HTTP request headers

* **Content-Type**: Not defined
* **Accept**: application/json

## registriesPatch

> registriesPatch(registryId, patchRegistryInput)

Update the properties of a registry

Update the properties of a registry - "garbageCollectionSchedule" time and days of the week for runs

### Examples

```javascript
const ionoscloud = require('@ionos-cloud/sdk-nodejs-container-registry');
// setup authorization
const config = new ionoscloud.Configuration({
    username: 'YOUR_USERNAME',
    password: 'YOUR_PASSWORD',
    apiKey: 'YOUR_API_KEY'
});
const api_instance = new ionoscloud.RegistriesApi(config);
// Update the properties of a registry
api_instance
  .registriesPatch({
    registryId: 38400000-8cf0-11bd-b23e-10b96e4ef00d,
    patchRegistryInput: patchRegistryInput_example
  })
  .then((response) => console.log(response.data))
  .catch((error) => console.log(error.response.data));
```

### Parameters

| Name                   | Type                                                                                                             | Description                   | Notes                   |
| ---------------------- | ---------------------------------------------------------------------------------------------------------------- | ----------------------------- | ----------------------- |
| **registryId**         | [**string**](https://github.com/ionos-cloud/sdk-nodejs-container-registry/blob/master/docs/models/.md/README.md) | The unique ID of the registry | \[default to undefined] |
| **patchRegistryInput** | [**PatchRegistryInput**](/container-registry-sdk-nodejs/models/patchregistryinput.md)                            |                               |                         |

### Return type

[**RegistryResponse**](/container-registry-sdk-nodejs/models/registryresponse.md)

### Authorization

basicAuth, tokenAuth

### HTTP request headers

* **Content-Type**: application/json
* **Accept**: application/json

## registriesPost

> registriesPost(postRegistryInput)

Create container registry

Create a registry to hold container images or OCI compliant artifacts - "name" must have passed validation - "location" must be one of the available location IDs - "garbageCollectionSchedule" time and days of the week for runs - "features": "vulnerabilityScanning" default is enabled

### Examples

```javascript
const ionoscloud = require('@ionos-cloud/sdk-nodejs-container-registry');
// setup authorization
const config = new ionoscloud.Configuration({
    username: 'YOUR_USERNAME',
    password: 'YOUR_PASSWORD',
    apiKey: 'YOUR_API_KEY'
});
const api_instance = new ionoscloud.RegistriesApi(config);
// Create container registry
api_instance
  .registriesPost({
    postRegistryInput: postRegistryInput_example
  })
  .then((response) => console.log(response.data))
  .catch((error) => console.log(error.response.data));
```

### Parameters

| Name                  | Type                                                                                | Description | Notes |
| --------------------- | ----------------------------------------------------------------------------------- | ----------- | ----- |
| **postRegistryInput** | [**PostRegistryInput**](/container-registry-sdk-nodejs/models/postregistryinput.md) |             |       |

### Return type

[**PostRegistryOutput**](/container-registry-sdk-nodejs/models/postregistryoutput.md)

### Authorization

basicAuth, tokenAuth

### HTTP request headers

* **Content-Type**: application/json
* **Accept**: application/json

## registriesPut

> registriesPut(registryId, putRegistryInput)

Create or replace a container registry

Create/replace a registry to hold container images or OCI compliant artifacts **On create** - "name" must have passed validation - "location" must be one of the available location IDs **On update** - "name" cannot be changed - "location" cannot be changed **On create or update** - "garbageCollectionSchedule": time and days of the week for runs

### Examples

```javascript
const ionoscloud = require('@ionos-cloud/sdk-nodejs-container-registry');
// setup authorization
const config = new ionoscloud.Configuration({
    username: 'YOUR_USERNAME',
    password: 'YOUR_PASSWORD',
    apiKey: 'YOUR_API_KEY'
});
const api_instance = new ionoscloud.RegistriesApi(config);
// Create or replace a container registry
api_instance
  .registriesPut({
    registryId: 38400000-8cf0-11bd-b23e-10b96e4ef00d,
    putRegistryInput: putRegistryInput_example
  })
  .then((response) => console.log(response.data))
  .catch((error) => console.log(error.response.data));
```

### Parameters

| Name                 | Type                                                                                                             | Description                   | Notes                   |
| -------------------- | ---------------------------------------------------------------------------------------------------------------- | ----------------------------- | ----------------------- |
| **registryId**       | [**string**](https://github.com/ionos-cloud/sdk-nodejs-container-registry/blob/master/docs/models/.md/README.md) | The unique ID of the registry | \[default to undefined] |
| **putRegistryInput** | [**PutRegistryInput**](/container-registry-sdk-nodejs/models/putregistryinput.md)                                |                               |                         |

### Return type

[**PutRegistryOutput**](/container-registry-sdk-nodejs/models/putregistryoutput.md)

### Authorization

basicAuth, tokenAuth

### HTTP request headers

* **Content-Type**: application/json
* **Accept**: application/json


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ionos.com/container-registry-sdk-nodejs/api/registriesapi.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
