Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApplyOptions ¶
type ApplyReport ¶
type ApplyReport struct {
Results []ApplyResult
Failed int
}
type ApplyResult ¶
type ApplyResult struct {
Resource string `json:"resource"`
Realm string `json:"realm,omitempty"`
Name string `json:"name"`
Action string `json:"action"`
Status int `json:"status"`
Error string `json:"error,omitempty"`
CreatedID string `json:"createdId,omitempty"`
// contains filtered or unexported fields
}
type Config ¶
type Config struct {
BaseURL string
SpecPath string
Timeout time.Duration
// Auth optionally injects a custom auth.Service. When nil, admin.New
// falls back to auth.New() (the password-grant default), preserving
// backward compatibility. The syncengine migration injects a
// client_credentials provider here.
Auth auth.Service
}
type FetchFailure ¶
FetchFailure describes a single resource that could not be fetched.
NotFound is true when the underlying error was an HTTP 404, meaning an optional resource is simply absent rather than genuinely broken — for example authorization resources/scopes on a client that does not have authorization services enabled, or organizations on a realm where the feature is disabled. The command layer aggregates these separately from real failures so the output distinguishes "absent" from "broken".
Resource is the resource type (e.g. "scope", "organization") and is used as the aggregation key. Detail carries additional context such as the parent identifier or realm.
func (FetchFailure) String ¶
func (f FetchFailure) String() string
type FetchQuery ¶
type FetchReport ¶
type FetchReport struct {
Resources []manifest.Resource
Relationships []manifest.RelationshipOperation
Failures []FetchFailure
}
type Service ¶
type Service interface {
Spec() *catalog.Spec
Fetch(ctx context.Context, query FetchQuery) (FetchReport, error)
Apply(ctx context.Context, resources []manifest.Resource, relationships []manifest.RelationshipOperation, options ApplyOptions) (ApplyReport, error)
}
Service is the public admin API used by command handlers.