Documentation ¶
Index ¶
- type AADBasedSecurityPrincipal
- type CertBasedSecurityPrincipal
- type CheckNameAvailabilityReason
- type CheckNameAvailabilityRequest
- type CheckNameAvailabilityResponse
- type Client
- type ClientCheckNameAvailabilityOptions
- type ClientCheckNameAvailabilityResponse
- type ConfidentialLedger
- type CreatedByType
- type ErrorAdditionalInfo
- type ErrorDetail
- type ErrorResponse
- type LedgerClient
- func (client *LedgerClient) BeginCreate(ctx context.Context, resourceGroupName string, ledgerName string, ...) (*runtime.Poller[LedgerClientCreateResponse], error)
- func (client *LedgerClient) BeginDelete(ctx context.Context, resourceGroupName string, ledgerName string, ...) (*runtime.Poller[LedgerClientDeleteResponse], error)
- func (client *LedgerClient) BeginUpdate(ctx context.Context, resourceGroupName string, ledgerName string, ...) (*runtime.Poller[LedgerClientUpdateResponse], error)
- func (client *LedgerClient) Get(ctx context.Context, resourceGroupName string, ledgerName string, ...) (LedgerClientGetResponse, error)
- func (client *LedgerClient) NewListByResourceGroupPager(resourceGroupName string, options *LedgerClientListByResourceGroupOptions) *runtime.Pager[LedgerClientListByResourceGroupResponse]
- func (client *LedgerClient) NewListBySubscriptionPager(options *LedgerClientListBySubscriptionOptions) *runtime.Pager[LedgerClientListBySubscriptionResponse]
- type LedgerClientBeginCreateOptions
- type LedgerClientBeginDeleteOptions
- type LedgerClientBeginUpdateOptions
- type LedgerClientCreateResponse
- type LedgerClientDeleteResponse
- type LedgerClientGetOptions
- type LedgerClientGetResponse
- type LedgerClientListByResourceGroupOptions
- type LedgerClientListByResourceGroupResponse
- type LedgerClientListBySubscriptionOptions
- type LedgerClientListBySubscriptionResponse
- type LedgerClientUpdateResponse
- type LedgerProperties
- type LedgerRoleName
- type LedgerType
- type List
- type OperationsClient
- type OperationsClientListOptions
- type OperationsClientListResponse
- type ProvisioningState
- type Resource
- type ResourceLocation
- type ResourceProviderOperationDefinition
- type ResourceProviderOperationDisplay
- type ResourceProviderOperationList
- type SystemData
- type Tags
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AADBasedSecurityPrincipal ¶
type AADBasedSecurityPrincipal struct { // LedgerRole associated with the Security Principal of Ledger LedgerRoleName *LedgerRoleName `json:"ledgerRoleName,omitempty"` // UUID/GUID based Principal Id of the Security Principal PrincipalID *string `json:"principalId,omitempty"` // UUID/GUID based Tenant Id of the Security Principal TenantID *string `json:"tenantId,omitempty"` }
AADBasedSecurityPrincipal - AAD based security principal with associated Ledger RoleName
type CertBasedSecurityPrincipal ¶
type CertBasedSecurityPrincipal struct { // Public key of the user cert (.pem or .cer) Cert *string `json:"cert,omitempty"` // LedgerRole associated with the Security Principal of Ledger LedgerRoleName *LedgerRoleName `json:"ledgerRoleName,omitempty"` }
CertBasedSecurityPrincipal - Cert based security principal with Ledger RoleName
type CheckNameAvailabilityReason ¶
type CheckNameAvailabilityReason string
CheckNameAvailabilityReason - The reason why the given name is not available.
const ( CheckNameAvailabilityReasonAlreadyExists CheckNameAvailabilityReason = "AlreadyExists" CheckNameAvailabilityReasonInvalid CheckNameAvailabilityReason = "Invalid" )
func PossibleCheckNameAvailabilityReasonValues ¶
func PossibleCheckNameAvailabilityReasonValues() []CheckNameAvailabilityReason
PossibleCheckNameAvailabilityReasonValues returns the possible values for the CheckNameAvailabilityReason const type.
type CheckNameAvailabilityRequest ¶
type CheckNameAvailabilityRequest struct { // The name of the resource for which availability needs to be checked. Name *string `json:"name,omitempty"` // The resource type. Type *string `json:"type,omitempty"` }
CheckNameAvailabilityRequest - The check availability request body.
type CheckNameAvailabilityResponse ¶
type CheckNameAvailabilityResponse struct { // Detailed reason why the given name is available. Message *string `json:"message,omitempty"` // Indicates if the resource name is available. NameAvailable *bool `json:"nameAvailable,omitempty"` // The reason why the given name is not available. Reason *CheckNameAvailabilityReason `json:"reason,omitempty"` }
CheckNameAvailabilityResponse - The check availability result.
type Client ¶ added in v0.2.0
type Client struct {
// contains filtered or unexported fields
}
Client contains the methods for the ConfidentialLedger group. Don't use this type directly, use NewClient() instead.
func NewClient ¶ added in v0.2.0
func NewClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*Client, error)
NewClient creates a new instance of Client with the specified values. subscriptionID - The Azure subscription ID. This is a GUID-formatted string (e.g. 00000000-0000-0000-0000-000000000000) credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*Client) CheckNameAvailability ¶ added in v0.2.0
func (client *Client) CheckNameAvailability(ctx context.Context, nameAvailabilityRequest CheckNameAvailabilityRequest, options *ClientCheckNameAvailabilityOptions) (ClientCheckNameAvailabilityResponse, error)
CheckNameAvailability - To check whether a resource name is available. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-05-13-preview nameAvailabilityRequest - Name availability request payload. options - ClientCheckNameAvailabilityOptions contains the optional parameters for the Client.CheckNameAvailability method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/confidentialledger/resource-manager/Microsoft.ConfidentialLedger/preview/2021-05-13-preview/examples/CheckNameAvailability.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/confidentialledger/armconfidentialledger" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armconfidentialledger.NewClient("00000000-0000-0000-0000-000000000000", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := client.CheckNameAvailability(ctx, armconfidentialledger.CheckNameAvailabilityRequest{ Name: to.Ptr("sample-name"), Type: to.Ptr("Microsoft.ConfidentialLedger/ledgers"), }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // TODO: use response item _ = res }
Output:
type ClientCheckNameAvailabilityOptions ¶ added in v0.2.0
type ClientCheckNameAvailabilityOptions struct { }
ClientCheckNameAvailabilityOptions contains the optional parameters for the Client.CheckNameAvailability method.
type ClientCheckNameAvailabilityResponse ¶ added in v0.2.0
type ClientCheckNameAvailabilityResponse struct {
CheckNameAvailabilityResponse
}
ClientCheckNameAvailabilityResponse contains the response from method Client.CheckNameAvailability.
type ConfidentialLedger ¶
type ConfidentialLedger struct { // The Azure location where the Confidential Ledger is running. Location *string `json:"location,omitempty"` // Properties of Confidential Ledger Resource. Properties *LedgerProperties `json:"properties,omitempty"` // Additional tags for Confidential Ledger Tags map[string]*string `json:"tags,omitempty"` // READ-ONLY; Fully qualified resource Id for the resource. ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; Name of the Resource. Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; Metadata pertaining to creation and last modification of the resource SystemData *SystemData `json:"systemData,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. Type *string `json:"type,omitempty" azure:"ro"` }
ConfidentialLedger - Confidential Ledger. Contains the properties of Confidential Ledger Resource.
func (ConfidentialLedger) MarshalJSON ¶
func (c ConfidentialLedger) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ConfidentialLedger.
type CreatedByType ¶
type CreatedByType string
CreatedByType - The type of identity that created the resource.
const ( CreatedByTypeApplication CreatedByType = "Application" CreatedByTypeKey CreatedByType = "Key" CreatedByTypeManagedIdentity CreatedByType = "ManagedIdentity" CreatedByTypeUser CreatedByType = "User" )
func PossibleCreatedByTypeValues ¶
func PossibleCreatedByTypeValues() []CreatedByType
PossibleCreatedByTypeValues returns the possible values for the CreatedByType const type.
type ErrorAdditionalInfo ¶
type ErrorAdditionalInfo struct { // READ-ONLY; The additional info. Info interface{} `json:"info,omitempty" azure:"ro"` // READ-ONLY; The additional info type. Type *string `json:"type,omitempty" azure:"ro"` }
ErrorAdditionalInfo - The resource management error additional info.
type ErrorDetail ¶
type ErrorDetail struct { // READ-ONLY; The error additional info. AdditionalInfo []*ErrorAdditionalInfo `json:"additionalInfo,omitempty" azure:"ro"` // READ-ONLY; The error code. Code *string `json:"code,omitempty" azure:"ro"` // READ-ONLY; The error details. Details []*ErrorDetail `json:"details,omitempty" azure:"ro"` // READ-ONLY; The error message. Message *string `json:"message,omitempty" azure:"ro"` // READ-ONLY; The error target. Target *string `json:"target,omitempty" azure:"ro"` }
ErrorDetail - The error detail.
type ErrorResponse ¶
type ErrorResponse struct { // The error object. Error *ErrorDetail `json:"error,omitempty"` }
ErrorResponse - Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.).
type LedgerClient ¶
type LedgerClient struct {
// contains filtered or unexported fields
}
LedgerClient contains the methods for the Ledger group. Don't use this type directly, use NewLedgerClient() instead.
func NewLedgerClient ¶
func NewLedgerClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*LedgerClient, error)
NewLedgerClient creates a new instance of LedgerClient with the specified values. subscriptionID - The Azure subscription ID. This is a GUID-formatted string (e.g. 00000000-0000-0000-0000-000000000000) credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*LedgerClient) BeginCreate ¶
func (client *LedgerClient) BeginCreate(ctx context.Context, resourceGroupName string, ledgerName string, confidentialLedger ConfidentialLedger, options *LedgerClientBeginCreateOptions) (*runtime.Poller[LedgerClientCreateResponse], error)
BeginCreate - Creates a Confidential Ledger with the specified ledger parameters. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-05-13-preview resourceGroupName - The name of the resource group. ledgerName - Name of the Confidential Ledger confidentialLedger - Confidential Ledger Create Request Body options - LedgerClientBeginCreateOptions contains the optional parameters for the LedgerClient.BeginCreate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/confidentialledger/resource-manager/Microsoft.ConfidentialLedger/preview/2021-05-13-preview/examples/ConfidentialLedger_Create.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/confidentialledger/armconfidentialledger" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armconfidentialledger.NewLedgerClient("0000000-0000-0000-0000-000000000001", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := client.BeginCreate(ctx, "DummyResourceGroupName", "DummyLedgerName", armconfidentialledger.ConfidentialLedger{ Location: to.Ptr("EastUS"), Tags: map[string]*string{ "additionalProps1": to.Ptr("additional properties"), }, Properties: &armconfidentialledger.LedgerProperties{ AADBasedSecurityPrincipals: []*armconfidentialledger.AADBasedSecurityPrincipal{ { LedgerRoleName: to.Ptr(armconfidentialledger.LedgerRoleNameAdministrator), PrincipalID: to.Ptr("34621747-6fc8-4771-a2eb-72f31c461f2e"), TenantID: to.Ptr("bce123b9-2b7b-4975-8360-5ca0b9b1cd08"), }}, CertBasedSecurityPrincipals: []*armconfidentialledger.CertBasedSecurityPrincipal{ { Cert: to.Ptr("-----BEGIN CERTIFICATE-----MIIBsjCCATigAwIBAgIUZWIbyG79TniQLd2UxJuU74tqrKcwCgYIKoZIzj0EAwMwEDEOMAwGA1UEAwwFdXNlcjAwHhcNMjEwMzE2MTgwNjExWhcNMjIwMzE2MTgwNjExWjAQMQ4wDAYDVQQDDAV1c2VyMDB2MBAGByqGSM49AgEGBSuBBAAiA2IABBiWSo/j8EFit7aUMm5lF+lUmCu+IgfnpFD+7QMgLKtxRJ3aGSqgS/GpqcYVGddnODtSarNE/HyGKUFUolLPQ5ybHcouUk0kyfA7XMeSoUA4lBz63Wha8wmXo+NdBRo39qNTMFEwHQYDVR0OBBYEFPtuhrwgGjDFHeUUT4nGsXaZn69KMB8GA1UdIwQYMBaAFPtuhrwgGjDFHeUUT4nGsXaZn69KMA8GA1UdEwEB/wQFMAMBAf8wCgYIKoZIzj0EAwMDaAAwZQIxAOnozm2CyqRwSSQLls5r+mUHRGRyXHXwYtM4Dcst/VEZdmS9fqvHRCHbjUlO/+HNfgIwMWZ4FmsjD3wnPxONOm9YdVn/PRD7SsPRPbOjwBiE4EBGaHDsLjYAGDSGi7NJnSkA-----END CERTIFICATE-----"), LedgerRoleName: to.Ptr(armconfidentialledger.LedgerRoleNameReader), }}, LedgerType: to.Ptr(armconfidentialledger.LedgerTypePublic), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) } // TODO: use response item _ = res }
Output:
func (*LedgerClient) BeginDelete ¶
func (client *LedgerClient) BeginDelete(ctx context.Context, resourceGroupName string, ledgerName string, options *LedgerClientBeginDeleteOptions) (*runtime.Poller[LedgerClientDeleteResponse], error)
BeginDelete - Deletes an existing Confidential Ledger. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-05-13-preview resourceGroupName - The name of the resource group. ledgerName - Name of the Confidential Ledger options - LedgerClientBeginDeleteOptions contains the optional parameters for the LedgerClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/confidentialledger/resource-manager/Microsoft.ConfidentialLedger/preview/2021-05-13-preview/examples/ConfidentialLedger_Delete.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/confidentialledger/armconfidentialledger" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armconfidentialledger.NewLedgerClient("0000000-0000-0000-0000-000000000001", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := client.BeginDelete(ctx, "DummyResourceGroupName", "DummyLedgerName", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) } }
Output:
func (*LedgerClient) BeginUpdate ¶
func (client *LedgerClient) BeginUpdate(ctx context.Context, resourceGroupName string, ledgerName string, confidentialLedger ConfidentialLedger, options *LedgerClientBeginUpdateOptions) (*runtime.Poller[LedgerClientUpdateResponse], error)
BeginUpdate - Updates properties of Confidential Ledger If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-05-13-preview resourceGroupName - The name of the resource group. ledgerName - Name of the Confidential Ledger confidentialLedger - Confidential Ledger request body for Updating Ledger options - LedgerClientBeginUpdateOptions contains the optional parameters for the LedgerClient.BeginUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/confidentialledger/resource-manager/Microsoft.ConfidentialLedger/preview/2021-05-13-preview/examples/ConfidentialLedger_Update.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/confidentialledger/armconfidentialledger" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armconfidentialledger.NewLedgerClient("0000000-0000-0000-0000-000000000001", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := client.BeginUpdate(ctx, "DummyResourceGroupName", "DummyLedgerName", armconfidentialledger.ConfidentialLedger{ Location: to.Ptr("EastUS"), Tags: map[string]*string{ "additionProps2": to.Ptr("additional property value"), "additionalProps1": to.Ptr("additional properties"), }, Properties: &armconfidentialledger.LedgerProperties{ AADBasedSecurityPrincipals: []*armconfidentialledger.AADBasedSecurityPrincipal{ { LedgerRoleName: to.Ptr(armconfidentialledger.LedgerRoleNameAdministrator), PrincipalID: to.Ptr("34621747-6fc8-4771-a2eb-72f31c461f2e"), TenantID: to.Ptr("bce123b9-2b7b-4975-8360-5ca0b9b1cd08"), }}, CertBasedSecurityPrincipals: []*armconfidentialledger.CertBasedSecurityPrincipal{ { Cert: to.Ptr("-----BEGIN CERTIFICATE-----\nMIIDUjCCAjqgAwIBAgIQJ2IrDBawSkiAbkBYmiAopDANBgkqhkiG9w0BAQsFADAmMSQwIgYDVQQDExtTeW50aGV0aWNzIExlZGdlciBVc2VyIENlcnQwHhcNMjAwOTIzMjIxODQ2WhcNMjEwOTIzMjIyODQ2WjAmMSQwIgYDVQQDExtTeW50aGV0aWNzIExlZGdlciBVc2VyIENlcnQwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCX2s/Eu4q/eQ63N+Ugeg5oAciZua/YCJr41c/696szvSY7Zg1SNJlW88/nbz70+QpO55OmqlEE3QCU+T0Vl/h0Gf//n1PYcoBbTGUnYEmV+fTTHict6rFiEwrGJ62tvcpYgwapInSLyEeUzjki0zhOLJ1OfRnYd1eGnFVMpE5aVjiS8Q5dmTEUyd51EIprGE8RYAW9aeWSwTH7gjHUsRlJnHKcdhaK/v5QKJnNu5bzPFUcpC0ZBcizoMPAtroLAD4B68Jl0z3op18MgZe6lRrVoWuxfqnk5GojuB/Vu8ohAZKoFhQ6NB6r+LL2AUs+Zr7Bt26IkEdR178n9JMEA4gHAgMBAAGjfDB6MA4GA1UdDwEB/wQEAwIFoDAJBgNVHRMEAjAAMB0GA1UdJQQWMBQGCCsGAQUFBwMBBggrBgEFBQcDAjAfBgNVHSMEGDAWgBS/a7PU9iOfOKEyZCp11Oen5VSuuDAdBgNVHQ4EFgQUv2uz1PYjnzihMmQqddTnp+VUrrgwDQYJKoZIhvcNAQELBQADggEBAF5q2fDwnse8egXhfaJCqqM969E9gSacqFmASpoDJPRPEX7gqoO7v1ww7nqRtRDoRiBvo/yNk7jlSAkRN3nRRnZLZZ3MYQdmCr4FGyIqRg4Y94+nja+Du9pDD761rxRktMVPSOaAVM/E5DQvscDlPvlPYe9mkcrLCE4DXYpiMmLT8Tm55LJJq5m07dVDgzAIR1L/hmEcbK0pnLgzciMtMLxGO2udnyyW/UW9WxnjvrrD2JluTHH9mVbb+XQP1oFtlRBfH7aui1ZgWfKvxrdP4zdK9QoWSUvRux3TLsGmHRBjBMtqYDY3y5mB+aNjLelvWpeVb0m2aOSVXynrLwNCAVA=\n-----END CERTIFICATE-----"), LedgerRoleName: to.Ptr(armconfidentialledger.LedgerRoleNameReader), }}, LedgerType: to.Ptr(armconfidentialledger.LedgerTypePublic), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) } // TODO: use response item _ = res }
Output:
func (*LedgerClient) Get ¶
func (client *LedgerClient) Get(ctx context.Context, resourceGroupName string, ledgerName string, options *LedgerClientGetOptions) (LedgerClientGetResponse, error)
Get - Retrieves the properties of a Confidential Ledger. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-05-13-preview resourceGroupName - The name of the resource group. ledgerName - Name of the Confidential Ledger options - LedgerClientGetOptions contains the optional parameters for the LedgerClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/confidentialledger/resource-manager/Microsoft.ConfidentialLedger/preview/2021-05-13-preview/examples/ConfidentialLedger_Get.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/confidentialledger/armconfidentialledger" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armconfidentialledger.NewLedgerClient("0000000-0000-0000-0000-000000000001", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := client.Get(ctx, "DummyResourceGroupName", "DummyLedgerName", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // TODO: use response item _ = res }
Output:
func (*LedgerClient) NewListByResourceGroupPager ¶ added in v0.4.0
func (client *LedgerClient) NewListByResourceGroupPager(resourceGroupName string, options *LedgerClientListByResourceGroupOptions) *runtime.Pager[LedgerClientListByResourceGroupResponse]
NewListByResourceGroupPager - Retrieves the properties of all Confidential Ledgers. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-05-13-preview resourceGroupName - The name of the resource group. options - LedgerClientListByResourceGroupOptions contains the optional parameters for the LedgerClient.ListByResourceGroup method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/confidentialledger/resource-manager/Microsoft.ConfidentialLedger/preview/2021-05-13-preview/examples/ConfidentialLedger_List.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/confidentialledger/armconfidentialledger" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armconfidentialledger.NewLedgerClient("0000000-0000-0000-0000-000000000001", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := client.NewListByResourceGroupPager("DummyResourceGroupName", &armconfidentialledger.LedgerClientListByResourceGroupOptions{Filter: nil}) for pager.More() { nextResult, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range nextResult.Value { // TODO: use page item _ = v } } }
Output:
func (*LedgerClient) NewListBySubscriptionPager ¶ added in v0.4.0
func (client *LedgerClient) NewListBySubscriptionPager(options *LedgerClientListBySubscriptionOptions) *runtime.Pager[LedgerClientListBySubscriptionResponse]
NewListBySubscriptionPager - Retrieves the properties of all Confidential Ledgers. If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-05-13-preview options - LedgerClientListBySubscriptionOptions contains the optional parameters for the LedgerClient.ListBySubscription method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/confidentialledger/resource-manager/Microsoft.ConfidentialLedger/preview/2021-05-13-preview/examples/ConfidentialLedger_ListBySub.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/confidentialledger/armconfidentialledger" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armconfidentialledger.NewLedgerClient("0000000-0000-0000-0000-000000000001", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := client.NewListBySubscriptionPager(&armconfidentialledger.LedgerClientListBySubscriptionOptions{Filter: nil}) for pager.More() { nextResult, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range nextResult.Value { // TODO: use page item _ = v } } }
Output:
type LedgerClientBeginCreateOptions ¶ added in v0.2.0
type LedgerClientBeginCreateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LedgerClientBeginCreateOptions contains the optional parameters for the LedgerClient.BeginCreate method.
type LedgerClientBeginDeleteOptions ¶ added in v0.2.0
type LedgerClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LedgerClientBeginDeleteOptions contains the optional parameters for the LedgerClient.BeginDelete method.
type LedgerClientBeginUpdateOptions ¶ added in v0.2.0
type LedgerClientBeginUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LedgerClientBeginUpdateOptions contains the optional parameters for the LedgerClient.BeginUpdate method.
type LedgerClientCreateResponse ¶ added in v0.2.0
type LedgerClientCreateResponse struct {
ConfidentialLedger
}
LedgerClientCreateResponse contains the response from method LedgerClient.Create.
type LedgerClientDeleteResponse ¶ added in v0.2.0
type LedgerClientDeleteResponse struct { }
LedgerClientDeleteResponse contains the response from method LedgerClient.Delete.
type LedgerClientGetOptions ¶ added in v0.2.0
type LedgerClientGetOptions struct { }
LedgerClientGetOptions contains the optional parameters for the LedgerClient.Get method.
type LedgerClientGetResponse ¶ added in v0.2.0
type LedgerClientGetResponse struct {
ConfidentialLedger
}
LedgerClientGetResponse contains the response from method LedgerClient.Get.
type LedgerClientListByResourceGroupOptions ¶ added in v0.2.0
type LedgerClientListByResourceGroupOptions struct { // The filter to apply on the list operation. eg. $filter=ledgerType eq 'Public' Filter *string }
LedgerClientListByResourceGroupOptions contains the optional parameters for the LedgerClient.ListByResourceGroup method.
type LedgerClientListByResourceGroupResponse ¶ added in v0.2.0
type LedgerClientListByResourceGroupResponse struct {
List
}
LedgerClientListByResourceGroupResponse contains the response from method LedgerClient.ListByResourceGroup.
type LedgerClientListBySubscriptionOptions ¶ added in v0.2.0
type LedgerClientListBySubscriptionOptions struct { // The filter to apply on the list operation. eg. $filter=ledgerType eq 'Public' Filter *string }
LedgerClientListBySubscriptionOptions contains the optional parameters for the LedgerClient.ListBySubscription method.
type LedgerClientListBySubscriptionResponse ¶ added in v0.2.0
type LedgerClientListBySubscriptionResponse struct {
List
}
LedgerClientListBySubscriptionResponse contains the response from method LedgerClient.ListBySubscription.
type LedgerClientUpdateResponse ¶ added in v0.2.0
type LedgerClientUpdateResponse struct {
ConfidentialLedger
}
LedgerClientUpdateResponse contains the response from method LedgerClient.Update.
type LedgerProperties ¶
type LedgerProperties struct { // Array of all AAD based Security Principals. AADBasedSecurityPrincipals []*AADBasedSecurityPrincipal `json:"aadBasedSecurityPrincipals,omitempty"` // Array of all cert based Security Principals. CertBasedSecurityPrincipals []*CertBasedSecurityPrincipal `json:"certBasedSecurityPrincipals,omitempty"` // Type of Confidential Ledger LedgerType *LedgerType `json:"ledgerType,omitempty"` // READ-ONLY; Endpoint for accessing network identity. IdentityServiceURI *string `json:"identityServiceUri,omitempty" azure:"ro"` // READ-ONLY; Internal namespace for the Ledger LedgerInternalNamespace *string `json:"ledgerInternalNamespace,omitempty" azure:"ro"` // READ-ONLY; Unique name for the Confidential Ledger. LedgerName *string `json:"ledgerName,omitempty" azure:"ro"` // READ-ONLY; Endpoint for calling Ledger Service. LedgerURI *string `json:"ledgerUri,omitempty" azure:"ro"` // READ-ONLY; Provisioning state of Ledger Resource ProvisioningState *ProvisioningState `json:"provisioningState,omitempty" azure:"ro"` }
LedgerProperties - Additional Confidential Ledger properties.
func (LedgerProperties) MarshalJSON ¶
func (l LedgerProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LedgerProperties.
type LedgerRoleName ¶
type LedgerRoleName string
LedgerRoleName - LedgerRole associated with the Security Principal of Ledger
const ( LedgerRoleNameAdministrator LedgerRoleName = "Administrator" LedgerRoleNameContributor LedgerRoleName = "Contributor" LedgerRoleNameReader LedgerRoleName = "Reader" )
func PossibleLedgerRoleNameValues ¶
func PossibleLedgerRoleNameValues() []LedgerRoleName
PossibleLedgerRoleNameValues returns the possible values for the LedgerRoleName const type.
type LedgerType ¶
type LedgerType string
LedgerType - Type of the ledger. Private means transaction data is encrypted.
const ( LedgerTypePrivate LedgerType = "Private" LedgerTypePublic LedgerType = "Public" LedgerTypeUnknown LedgerType = "Unknown" )
func PossibleLedgerTypeValues ¶
func PossibleLedgerTypeValues() []LedgerType
PossibleLedgerTypeValues returns the possible values for the LedgerType const type.
type List ¶ added in v0.2.0
type List struct { // The URL the client should use to fetch the next page (per server side paging). NextLink *string `json:"nextLink,omitempty"` // List of Confidential Ledgers Value []*ConfidentialLedger `json:"value,omitempty"` }
List - Object that includes an array of Confidential Ledgers and a possible link for next set.
type OperationsClient ¶
type OperationsClient struct {
// contains filtered or unexported fields
}
OperationsClient contains the methods for the Operations group. Don't use this type directly, use NewOperationsClient() instead.
func NewOperationsClient ¶
func NewOperationsClient(credential azcore.TokenCredential, options *arm.ClientOptions) (*OperationsClient, error)
NewOperationsClient creates a new instance of OperationsClient with the specified values. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*OperationsClient) NewListPager ¶ added in v0.4.0
func (client *OperationsClient) NewListPager(options *OperationsClientListOptions) *runtime.Pager[OperationsClientListResponse]
NewListPager - Retrieves a list of available API operations If the operation fails it returns an *azcore.ResponseError type. Generated from API version 2021-05-13-preview options - OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/confidentialledger/resource-manager/Microsoft.ConfidentialLedger/preview/2021-05-13-preview/examples/Operations_Get.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/confidentialledger/armconfidentialledger" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client, err := armconfidentialledger.NewOperationsClient(cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := client.NewListPager(nil) for pager.More() { nextResult, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range nextResult.Value { // TODO: use page item _ = v } } }
Output:
type OperationsClientListOptions ¶ added in v0.2.0
type OperationsClientListOptions struct { }
OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.
type OperationsClientListResponse ¶ added in v0.2.0
type OperationsClientListResponse struct {
ResourceProviderOperationList
}
OperationsClientListResponse contains the response from method OperationsClient.List.
type ProvisioningState ¶
type ProvisioningState string
ProvisioningState - Object representing ProvisioningState for Confidential Ledger.
const ( ProvisioningStateCanceled ProvisioningState = "Canceled" ProvisioningStateCreating ProvisioningState = "Creating" ProvisioningStateDeleting ProvisioningState = "Deleting" ProvisioningStateFailed ProvisioningState = "Failed" ProvisioningStateSucceeded ProvisioningState = "Succeeded" ProvisioningStateUnknown ProvisioningState = "Unknown" ProvisioningStateUpdating ProvisioningState = "Updating" )
func PossibleProvisioningStateValues ¶
func PossibleProvisioningStateValues() []ProvisioningState
PossibleProvisioningStateValues returns the possible values for the ProvisioningState const type.
type Resource ¶
type Resource struct { // READ-ONLY; Fully qualified resource Id for the resource. ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; Name of the Resource. Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; Metadata pertaining to creation and last modification of the resource SystemData *SystemData `json:"systemData,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. Type *string `json:"type,omitempty" azure:"ro"` }
Resource - An Azure resource.
type ResourceLocation ¶ added in v0.3.0
type ResourceLocation struct { // The Azure location where the Confidential Ledger is running. Location *string `json:"location,omitempty"` }
ResourceLocation - Location of the ARM Resource
type ResourceProviderOperationDefinition ¶
type ResourceProviderOperationDefinition struct { // Details about the operations Display *ResourceProviderOperationDisplay `json:"display,omitempty"` // Indicates whether the operation is data action or not. IsDataAction *bool `json:"isDataAction,omitempty"` // Resource provider operation name. Name *string `json:"name,omitempty"` }
ResourceProviderOperationDefinition - Describes the Resource Provider Operation.
type ResourceProviderOperationDisplay ¶
type ResourceProviderOperationDisplay struct { // Description of the resource provider operation. Description *string `json:"description,omitempty"` // Name of the resource provider operation. Operation *string `json:"operation,omitempty"` // Name of the resource provider. Provider *string `json:"provider,omitempty"` // Name of the resource type. Resource *string `json:"resource,omitempty"` }
ResourceProviderOperationDisplay - Describes the properties of the Operation.
type ResourceProviderOperationList ¶
type ResourceProviderOperationList struct { // READ-ONLY; The URI that can be used to request the next page for list of Azure operations. NextLink *string `json:"nextLink,omitempty" azure:"ro"` // READ-ONLY; Resource provider operations list. Value []*ResourceProviderOperationDefinition `json:"value,omitempty" azure:"ro"` }
ResourceProviderOperationList - List containing this Resource Provider's available operations.
type SystemData ¶
type SystemData struct { // The timestamp of resource creation (UTC). CreatedAt *time.Time `json:"createdAt,omitempty"` // The identity that created the resource. CreatedBy *string `json:"createdBy,omitempty"` // The type of identity that created the resource. CreatedByType *CreatedByType `json:"createdByType,omitempty"` // The timestamp of resource last modification (UTC) LastModifiedAt *time.Time `json:"lastModifiedAt,omitempty"` // The identity that last modified the resource. LastModifiedBy *string `json:"lastModifiedBy,omitempty"` // The type of identity that last modified the resource. LastModifiedByType *CreatedByType `json:"lastModifiedByType,omitempty"` }
SystemData - Metadata pertaining to creation and last modification of the resource.
func (SystemData) MarshalJSON ¶
func (s SystemData) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SystemData.
func (*SystemData) UnmarshalJSON ¶
func (s *SystemData) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type SystemData.