or run

npx @tessl/cli init
Log in

Version

Tile

Overview

Evals

Files

Files

docs

aggregated-cost.mdbudget-management.mdclient-management.mdcost-analysis.mdcredits-billing.mdindex.mdoperations.mdreservation-management.mdtags-operations.mdusage-analytics.md

operations.mddocs/

0

# API Operations

1

2

List all available consumption REST API operations for service discovery and capability exploration. This provides metadata about all supported operations in the Azure Consumption Management API.

3

4

## Capabilities

5

6

### Operations Listing

7

8

Retrieve all available consumption REST API operations to understand service capabilities and available endpoints.

9

10

```python { .api }

11

def list(**kwargs) -> Iterable[OperationListResult]:

12

"""

13

Lists all of the available consumption REST API operations.

14

15

Returns:

16

Iterable[OperationListResult]: Collection of available API operations with metadata

17

"""

18

```

19

20

## Usage Examples

21

22

```python

23

from azure.identity import DefaultAzureCredential

24

from azure.mgmt.consumption import ConsumptionManagementClient

25

26

# Authenticate and create client

27

credential = DefaultAzureCredential()

28

subscription_id = "your-subscription-id"

29

client = ConsumptionManagementClient(credential, subscription_id)

30

31

# List all available operations

32

operations = client.operations.list()

33

34

print("Available Azure Consumption Management API Operations:")

35

for operation in operations:

36

print(f"- {operation.name}: {operation.display.description}")

37

print(f" Provider: {operation.display.provider}")

38

print(f" Resource: {operation.display.resource}")

39

print(f" Operation: {operation.display.operation}")

40

print()

41

42

# Filter operations by name pattern

43

budget_operations = [

44

op for op in client.operations.list()

45

if 'budgets' in op.name.lower()

46

]

47

48

print("Budget-related operations:")

49

for op in budget_operations:

50

print(f"- {op.name}")

51

```

52

53

## Types

54

55

```python { .api }

56

class OperationListResult:

57

value: List[Operation]

58

next_link: str

59

60

class Operation:

61

id: str

62

name: str

63

type: str

64

display: OperationDisplay

65

66

class OperationDisplay:

67

provider: str

68

resource: str

69

operation: str

70

description: str

71

```