> This page is for NVIDIA Infra Controller.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/infra-controller/llms.txt.

# Retrieve all SpectrumX Partitions

GET https://nico-rest-api.nico.svc.cluster.local/v2/org/{org}/nico/spectrumx-partition

Retrieve all SpectrumX Partitions for the org

Org must have a Tenant entity. User must have authorization role with `TENANT_ADMIN` suffix.

Reference: https://docs.nvidia.com/infra-controller/rest-api-reference/api-reference/spectrum-x-partition/get-all-spectrumx-partition

## Authentication

- `Authorization` header (bearer token, required) — ``` export JWT_BEARER_TOKEN="<jwt-bearer-token>" # Example org name: "acme-inc export ORG_NAME=<org-name> # Use the JWT bearer token in your API request auth header: curl -v -X GET -H "Content-Type: application/json" -H "Authorization: Bearer $JWT_BEARER_TOKEN" https://nico-rest-api.nico.svc.cluster.local/v2/org/$ORG_NAME/nico/user/current ```

## Request

### Path parameters

- `org` (string, required) — Name of the Org

### Query parameters

- `siteId` (list of string, optional) — Filter Partitions by Site. Repeat the parameter to match multiple Sites.
- `status` (list of enum, optional) — Filter Partitions by Status. Repeat the parameter to match multiple Statuses.
  - Allowed values: `Pending`, `Provisioning`, `Ready`, `Error`, `Deleting`
- `query` (string, optional) — Search for matches across all SpectrumX Partitions. Input will be matched against name, description, status and labels fields
- `includeRelation` (list of enum, optional) — Related entity to expand. Repeat the parameter to specify multiple values.
  - Allowed values: `Site`, `Tenant`
- `pageNumber` (integer, optional) — Page number for pagination query
- `pageSize` (integer, optional) — Page size for pagination query
- `orderBy` (enum, optional, default: CREATED_ASC) — Ordering for pagination query. Defaults to CREATED_ASC.
  - Allowed values: `NAME_ASC`, `NAME_DESC`, `STATUS_ASC`, `STATUS_DESC`, `CREATED_ASC`, `CREATED_DESC`, `UPDATED_ASC`, `UPDATED_DESC`

## Response

### 200

OK

- `list of SpectrumXPartition`

## Errors

### 403 Forbidden Error

Error response when user is not authorized to call an endpoint or retrieve/modify objects

- `source` (string, optional) — Source of the error, taken from `api.name` in the REST API server configuration file (`/app/config.yaml` in the supplied Kubernetes deployment; default API name `nico`). This is a configurable string, for example `nico` or `carbide`
- `message` (string, optional) — Message describing the error
- `data` (NiCoApiErrorData, optional, nullable) — Additional data about the error
- `retryable` (boolean, optional) — True permits bounded retries with backoff, without guaranteeing success. False prohibits automatic retries. Omission means unclassified.

## Types

### SpectrumXPartition

SpectrumX Partitions are east-west network segments that Instances attach to over SpectrumX interfaces

- `id` (string, required) — Unique UUID v4 identifier for the SpectrumX Partition
- `name` (string, required) — Name of the SpectrumX Partition
- `siteId` (string, required) — ID of the Site the Partition belongs to
- `tenantId` (string, required) — ID of the Tenant that owns the Partition
- `status` (enum, required) — Status of the SpectrumX Partition. A Partition becomes Ready once the Site reports it in inventory
  - Allowed values: `Pending`, `Provisioning`, `Ready`, `Error`, `Deleting`
- `description` (string, optional, nullable) — Description of the SpectrumX Partition
- `site` (SiteSummary, optional) — Summary of the Site, present when requested through includeRelation
- `tenant` (TenantSummary, optional) — Summary of the Tenant, present when requested through includeRelation
- `vni` (integer, optional, nullable) — VXLAN Network Identifier for the Partition. Allocated by the Site when the create request omits it
- `labels` (map from string to string, optional) — String key-value pairs describing Partition labels. Up to 10 key-value pairs can be specified
- `statusHistory` (list of StatusDetail, optional) — Status detail records for the SpectrumX Partition over time
- `created` (datetime, optional) — ISO datetime string for when the SpectrumX Partition was created
- `updated` (datetime, optional) — ISO datetime string for when the SpectrumX Partition was last updated

### NiCoApiErrorData

Additional data about the error

### SiteSummary

SiteSummary contains a subset of data for Site object, used when nesting in other objects

- `id` (string, optional) — Unique UUID v4 identifier for the Site
- `name` (string, optional) — Name of the Site
- `infrastructureProviderId` (string, optional) — ID of the Infrastructure Provider that owns the Site
- `isSerialConsoleEnabled` (boolean, optional) — Indicates if Serial Console is enabled for the Site by the Provider
- `isOnline` (boolean, optional) — Indicates if the Site is currently reachable from Cloud
- `capabilities` (SiteCapabilities, optional) — Site capabilities used for feature availability and configuration
- `status` (enum, optional) — Status of the Site
  - Allowed values: `Pending`, `Registered`, `Error`

### TenantSummary

Summarizes a Tenant

- `org` (string, optional) — Name of the org this tenant belongs to
- `orgDisplayName` (string, optional, nullable) — Display name of the org the Tenant belongs to
- `capabilities` (TenantCapabilities, optional) — Deprecated compatibility object. The targetedInstanceCreation property is omitted; use Tenant Account siteCapabilities for the authoritative configuration.
- `deprecations` (list of Deprecation, optional) — Deprecation notices for Tenant fields

### StatusDetail

Describes the details of a status transition for a resource

- `status` (string, optional) — State of the associated entity at a particular time
- `message` (string, optional, nullable) — Description of the state and cause/remedy in case of error
- `created` (datetime, optional) — Date/time when the associated entity assumed the status
- `updated` (datetime, optional) — Date/time when the associated entity was last observed with this status

### SiteCapabilities

Boolean flags to indicate features supported by a Site

- `nativeNetworking` (boolean, optional) — Whether the Site supports native networking
- `networkSecurityGroup` (boolean, optional) — Whether the Site supports Network Security Groups
- `nvLinkPartition` (boolean, optional) — Whether the latest successfully stored Site configuration inventory reports that NVLink partitioning is enabled in the Site's Core configuration. False also represents a new Site that has not reported Site configuration inventory yet. An inventory report from an older Core that omits the setting leaves the stored value unchanged. This value is managed by Site configuration inventory and cannot be updated through the Site API.
- `flow` (boolean, optional) — Whether the Site supports Flow-based operations
- `imageBasedOperatingSystem` (boolean, optional) — Whether the Site supports image-based operating system provisioning
- `vpcSlaac` (boolean, optional) — Whether the latest successfully stored Site configuration inventory reports that Core supports VPCs with SLAAC enabled. False also represents a missing Site configuration or an inventory report that omits the capability. This value is managed by Site configuration inventory and cannot be updated through the Site API.
- `dpsPowerManagement` (boolean, optional, default: false) — Whether this Site accepts non-empty power resource groups and power profiles for DPS power management. When false, omission and explicit clearing remain allowed.

### TenantCapabilities

Deprecated tenant-wide capability summary. TargetedInstanceCreation is no longer stored on the Tenant entity; it is configured on Tenant Account `siteCapabilities` (and may be overridden per Site via Tenant Site configuration). On GET `/tenant/current`, `targetedInstanceCreation` is present and `true` only when the Tenant has at least one Ready Tenant Account, every Ready Tenant Account has the capability enabled by default, and no Tenant Site explicitly disables it. Otherwise the property is omitted. Embedded `TenantSummary.capabilities` objects in nested resources also omit the property.

- `targetedInstanceCreation` (boolean, optional, deprecated) — Deprecated in favor of TenantAccount.siteCapabilities. On GET `/tenant/current`, the property is present and true only when every Ready Tenant Account enables TargetedInstanceCreation and no Tenant Site explicitly disables it; otherwise it is omitted. It is also omitted from embedded TenantSummary objects.

### Deprecation

Details of a particular deprecation in NVIDIA Infra Controller (NICo) API

- `attribute` (string, optional, nullable) — Name of the attribute that is deprecated. Omitted if queryParam or endpoint is being deprecated.
- `queryParam` (string, optional, nullable) — Query parameter that is deprecated. Omitted if attribute or endpoint is being deprecated.
- `endpoint` (string, optional, nullable) — API endpoint that is deprecated. Omitted if attribute or queryParam is being deprecated.
- `replacedBy` (string, optional, nullable) — Name of the attribute, query parameter, or endpoint that replaces the deprecated item. Omitted if no replacement is available.
- `takeActionBy` (datetime, optional) — Date/time by which clients should migrate away from the deprecated API surface
- `notice` (string, optional) — Message describing the deprecation

## Examples

**Response**

```json
[
  {
    "id": "8e6f2a1c-9b3d-4e5f-a6b7-c8d9e0f1a2b3",
    "name": "east-west-net",
    "siteId": "60189e9c-7d12-438c-b9ca-6998d9c364b1",
    "tenantId": "f97df110-f4de-492e-8849-4a6af68026b0",
    "status": "Ready",
    "description": "SpectrumX Partition for east-west training traffic",
    "vni": 10200,
    "labels": {
      "environment": "production",
      "team": "devops"
    },
    "statusHistory": [
      {
        "status": "Ready",
        "message": "SpectrumX Partition is ready for use",
        "created": "2019-08-24T14:15:22Z",
        "updated": "2019-08-24T14:15:22Z"
      }
    ],
    "created": "2019-08-24T14:15:22Z",
    "updated": "2019-08-24T14:15:22Z"
  }
]
```

**SDK Code**

```python Example 1
import requests

url = "https://nico-rest-api.nico.svc.cluster.local/v2/org/org/nico/spectrumx-partition"

querystring = {"pageSize":"20"}

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers, params=querystring)

print(response.json())
```

```javascript Example 1
const url = 'https://nico-rest-api.nico.svc.cluster.local/v2/org/org/nico/spectrumx-partition?pageSize=20';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Example 1
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://nico-rest-api.nico.svc.cluster.local/v2/org/org/nico/spectrumx-partition?pageSize=20"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("Authorization", "Bearer <token>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Example 1
require 'uri'
require 'net/http'

url = URI("https://nico-rest-api.nico.svc.cluster.local/v2/org/org/nico/spectrumx-partition?pageSize=20")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
```

```java Example 1
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://nico-rest-api.nico.svc.cluster.local/v2/org/org/nico/spectrumx-partition?pageSize=20")
  .header("Authorization", "Bearer <token>")
  .asString();
```

```php Example 1
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://nico-rest-api.nico.svc.cluster.local/v2/org/org/nico/spectrumx-partition?pageSize=20', [
  'headers' => [
    'Authorization' => 'Bearer <token>',
  ],
]);

echo $response->getBody();
```

```csharp Example 1
using RestSharp;

var client = new RestClient("https://nico-rest-api.nico.svc.cluster.local/v2/org/org/nico/spectrumx-partition?pageSize=20");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer <token>");
IRestResponse response = client.Execute(request);
```

```swift Example 1
import Foundation

let headers = ["Authorization": "Bearer <token>"]

let request = NSMutableURLRequest(url: NSURL(string: "https://nico-rest-api.nico.svc.cluster.local/v2/org/org/nico/spectrumx-partition?pageSize=20")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```