Documentation
¶
Index ¶
- Constants
- func AddTagsToAsset(ctx context.Context, client *http.Client, assetID string, tags []string) error
- func AskDad(ctx context.Context, collibraHttpClient *http.Client, question string) (string, error)
- func AskGlossary(ctx context.Context, collibraHttpClient *http.Client, question string) (string, error)
- func CreateAddFromManifestRequest(req PushDataContractManifestRequest) (*bytes.Buffer, string, error)
- func DeleteAttribute(ctx context.Context, client *http.Client, attributeID string) error
- func DeleteRelation(ctx context.Context, client *http.Client, relationID string) error
- func FetchDescription(ctx context.Context, client *http.Client, assetID string) string
- func GetUserGroupName(ctx context.Context, collibraHttpClient *http.Client, groupID string) (string, error)
- func GetUserName(ctx context.Context, collibraHttpClient *http.Client, userID string) (string, error)
- func PullActiveDataContractManifest(ctx context.Context, collibraHttpClient *http.Client, dataContractID string) ([]byte, error)
- func RemoveDataClassificationMatch(ctx context.Context, httpClient *http.Client, classificationMatchID string) error
- type AddDataClassRequest
- type AddDataClassificationMatchRequest
- type Asset
- type AssetQueryData
- type AssetType
- type AssetTypeDetails
- type AssetTypePagedResponse
- type AssetTypesQueryParams
- type AttributeResult
- type AttributeType
- type AttributesQueryParams
- type AttributesResponse
- type BooleanAttribute
- type ChatContext
- type ConnectedAsset
- type CreateAssetDomainRef
- type CreateAssetRequest
- type CreateAssetResponse
- type CreateAssetStatusRef
- type CreateAssetTypeRef
- type CreateAttributeAssetRef
- type CreateAttributeRequest
- type CreateAttributeResponse
- type CreateAttributeTypeRef
- type DataClass
- type DataClassQueryParams
- type DataClassesResponse
- type DataClassification
- type DataClassificationMatch
- type DataClassificationMatchQueryParams
- type DataContract
- type DataContractListPaginated
- type DataContractsQueryParams
- type DateAttribute
- type Domain
- type EditAssetAddTagsRequest
- type EditAssetAssignment
- type EditAssetAssignmentAttributeType
- type EditAssetAssignmentConstraints
- type EditAssetAssignmentRelationType
- type EditAssetAttributeAssetRef
- type EditAssetAttributeInstance
- func BulkCreateAttributes(ctx context.Context, client *http.Client, items []CreateAttributeRequest) ([]EditAssetAttributeInstance, error)
- func BulkPatchAttributes(ctx context.Context, client *http.Client, ...) ([]EditAssetAttributeInstance, error)
- func CreateAttributeOnAsset(ctx context.Context, client *http.Client, assetID, attrTypeID, value string) (*EditAssetAttributeInstance, error)
- func ListAttributesForAsset(ctx context.Context, client *http.Client, assetID string) ([]EditAssetAttributeInstance, error)
- func PatchAttributeValue(ctx context.Context, client *http.Client, attributeID, value string) (*EditAssetAttributeInstance, error)
- type EditAssetAttributeTypeRef
- type EditAssetBulkPatchAttributeItem
- type EditAssetCore
- type EditAssetCreateRelationRequest
- type EditAssetCreateResponsibilityRequest
- type EditAssetDomainDetails
- type EditAssetDomainRef
- type EditAssetDomainTypeRef
- type EditAssetPatchAttributeRequest
- type EditAssetPatchRequest
- type EditAssetRelation
- type EditAssetResponsibility
- type EditAssetRole
- type EditAssetStatus
- type EditAssetStatusRef
- type EditAssetTypeRef
- type EditAssetUser
- type Error
- type GetLineageDirectionalOutput
- type GetLineageEntityOutput
- type GetLineageTransformationOutput
- type IncomingRelation
- type LineageDirection
- type LineageEntity
- type LineagePagination
- type LineageRelation
- type LineageResponseWarning
- type LineageTransformation
- type NamedResourceReference
- type NumericAttribute
- type OutgoingRelation
- type PagedResponseDataClassificationMatch
- type PrepareCreateAllowedDomainType
- type PrepareCreateAssetResult
- type PrepareCreateAssetSearchResponse
- type PrepareCreateAssetStatus
- type PrepareCreateAssetType
- func GetAssetTypeByID(ctx context.Context, client *http.Client, id string) (*PrepareCreateAssetType, error)
- func GetAssetTypeByPublicID(ctx context.Context, client *http.Client, publicID string) (*PrepareCreateAssetType, error)
- func GetAvailableAssetTypesForDomain(ctx context.Context, client *http.Client, domainID string) ([]PrepareCreateAssetType, error)
- func ListAssetTypesForPrepare(ctx context.Context, client *http.Client, limit int) ([]PrepareCreateAssetType, int, error)
- func SearchAssetTypesByName(ctx context.Context, client *http.Client, name string, limit int) ([]PrepareCreateAssetType, int, error)
- type PrepareCreateAssetTypeListResponse
- type PrepareCreateAttributeType
- type PrepareCreateAttributeTypeFull
- type PrepareCreateConstraints
- type PrepareCreateDomain
- func GetDomainByID(ctx context.Context, client *http.Client, domainID string) (*PrepareCreateDomain, error)
- func ListDomainsForPrepare(ctx context.Context, client *http.Client, limit int) ([]PrepareCreateDomain, int, error)
- func SearchDomainsByName(ctx context.Context, client *http.Client, name string, limit int) ([]PrepareCreateDomain, int, error)
- type PrepareCreateDomainListResponse
- type PrepareCreateDomainType
- type PrepareCreateScopedAssignment
- type PrepareCreateScopedAttribute
- type PrepareCreateScopedRelation
- type PrepareCreateStatus
- type PrepareCreateStatusListResponse
- type PushDataContractManifestRequest
- type PushDataContractManifestResponse
- type RelatedAsset
- type Relation
- type RelationAsset
- type RelationType
- type RelationsQueryParams
- type RelationsResponse
- type Request
- type ResourceRef
- type ResourceRole
- type Response
- type Responsibility
- type ResponsibilityPagedResponse
- type ResponsibilityQueryParams
- type SearchAggregation
- type SearchAggregationValue
- type SearchField
- type SearchFilter
- type SearchHighlight
- type SearchLineageEntitiesOutput
- type SearchLineageTransformationsOutput
- type SearchRequest
- type SearchResource
- type SearchResponse
- type SearchResult
- type Status
- type StringAttribute
- type ToolContent
- type ToolMessage
- type ToolRequest
- type ToolResponse
- type TransformationSummary
- type UserGroupResponse
- type UserResponse
Constants ¶
const ( AttributesLimit = 100 RelationsLimit = 50 )
const ( DefinitionAttributeTypeID = "00000000-0000-0000-0000-000000000202" MeasureIsCalculatedUsingDataElementRelID = "00000000-0000-0000-0000-000000007200" BusinessAssetRepresentsDataAssetRelID = "00000000-0000-0000-0000-000000007038" ColumnIsPartOfTableRelID = "00000000-0000-0000-0000-000000007042" DataAttributeRepresentsColumnRelID = "00000000-0000-0000-0000-000000007094" ColumnIsSourceForDataAttributeRelID = "00000000-0000-0000-0000-120000000011" )
Well-known Collibra UUIDs for relation and attribute types.
Variables ¶
This section is empty.
Functions ¶
func AddTagsToAsset ¶ added in v0.0.32
AddTagsToAsset appends one or more tags to an asset without replacing existing tags (incremental, matching the "prefer incremental" AC).
func AskGlossary ¶
func CreateAddFromManifestRequest ¶
func CreateAddFromManifestRequest(req PushDataContractManifestRequest) (*bytes.Buffer, string, error)
func DeleteAttribute ¶ added in v0.0.32
DeleteAttribute removes a single attribute instance via DELETE /rest/2.0/attributes/{id}.
func DeleteRelation ¶ added in v0.0.32
DeleteRelation removes a relation via DELETE /rest/2.0/relations/{id}.
func FetchDescription ¶ added in v0.0.26
FetchDescription retrieves the definition/description attribute for an asset.
func GetUserGroupName ¶ added in v0.0.28
func GetUserGroupName(ctx context.Context, collibraHttpClient *http.Client, groupID string) (string, error)
GetUserGroupName fetches the name for a user group by ID.
func GetUserName ¶ added in v0.0.28
func GetUserName(ctx context.Context, collibraHttpClient *http.Client, userID string) (string, error)
GetUserName fetches the display name for a user by ID.
Types ¶
type AddDataClassRequest ¶
type AddDataClassRequest struct {
Name string `json:"name"`
Description string `json:"description,omitempty"`
Status string `json:"status,omitempty"`
ColumnNameFilters []string `json:"columnNameFilters,omitempty"`
ColumnTypeFilters []string `json:"columnTypeFilters,omitempty"`
AllowNullValues *bool `json:"allowNullValues,omitempty"`
AllowEmptyValues *bool `json:"allowEmptyValues,omitempty"`
ConfidenceThreshold *int `json:"confidenceThreshold,omitempty"`
Examples []string `json:"examples,omitempty"`
}
type Asset ¶
type Asset struct {
ID string `json:"id"`
DisplayName string `json:"displayName"`
Type *AssetType `json:"type,omitempty"`
Domain *Domain `json:"domain,omitempty"`
Status *Status `json:"status,omitempty"`
StringAttributes []StringAttribute `json:"stringAttributes,omitempty"`
NumericAttributes []NumericAttribute `json:"numericAttributes,omitempty"`
BooleanAttributes []BooleanAttribute `json:"booleanAttributes,omitempty"`
DateAttributes []DateAttribute `json:"dateAttributes,omitempty"`
OutgoingRelations []OutgoingRelation `json:"outgoingRelations,omitempty"`
IncomingRelations []IncomingRelation `json:"incomingRelations,omitempty"`
}
func GetAssetSummary ¶
type AssetQueryData ¶
type AssetQueryData struct {
Assets []Asset `json:"assets"`
}
type AssetTypeDetails ¶
type AssetTypeDetails struct {
ID string `json:"id"`
Name string `json:"name"`
Description string `json:"description,omitempty"`
PublicId string `json:"publicId,omitempty"`
DisplayNameEnabled bool `json:"displayNameEnabled"`
RatingEnabled bool `json:"ratingEnabled"`
FinalType bool `json:"finalType"`
System bool `json:"system"`
Product string `json:"product,omitempty"`
}
type AssetTypePagedResponse ¶
type AssetTypePagedResponse struct {
Total int64 `json:"total"`
Offset int64 `json:"offset"`
Limit int64 `json:"limit"`
Results []AssetTypeDetails `json:"results"`
}
AssetTypePagedResponse represents the response from the Collibra asset types API
func ListAssetTypes ¶
func ParseAssetTypesResponse ¶
func ParseAssetTypesResponse(jsonData []byte) (*AssetTypePagedResponse, error)
type AssetTypesQueryParams ¶
type AttributeResult ¶ added in v0.0.26
type AttributeType ¶
type AttributeType struct {
Name string `json:"name"`
}
type AttributesQueryParams ¶ added in v0.0.26
type AttributesResponse ¶ added in v0.0.26
type AttributesResponse struct {
Total int `json:"total"`
Offset int `json:"offset"`
Limit int `json:"limit"`
Results []AttributeResult `json:"results"`
}
func GetAssetAttributes ¶ added in v0.0.26
func GetAssetAttributes(ctx context.Context, client *http.Client, assetID string, attrTypeID string) (*AttributesResponse, error)
GetAssetAttributes queries the Collibra attributes API for a specific asset and attribute type.
type BooleanAttribute ¶
type BooleanAttribute struct {
Value bool `json:"booleanValue"`
Type *AttributeType `json:"type,omitempty"`
}
type ChatContext ¶
type ChatContext struct {
OriginUrl string `json:"originUrl"`
}
type ConnectedAsset ¶ added in v0.0.26
type ConnectedAsset struct {
ID string `json:"id"`
Name string `json:"name"`
AssetType string `json:"assetType"`
}
func FindColumnsForDataAttribute ¶ added in v0.0.26
func FindColumnsForDataAttribute(ctx context.Context, client *http.Client, dataAttributeID string) ([]ConnectedAsset, error)
FindColumnsForDataAttribute finds assets connected via both data attribute relation types.
func FindConnectedAssets ¶ added in v0.0.26
func FindConnectedAssets(ctx context.Context, client *http.Client, assetID string, relationTypeID string) ([]ConnectedAsset, error)
FindConnectedAssets finds assets connected to assetID via relationTypeID, querying both directions.
type CreateAssetDomainRef ¶ added in v0.0.29
CreateAssetDomainRef is a reference to a domain in a create asset response.
type CreateAssetRequest ¶ added in v0.0.29
type CreateAssetRequest struct {
Name string `json:"name"`
TypeID string `json:"typeId"`
DomainID string `json:"domainId"`
DisplayName string `json:"displayName,omitempty"`
StatusID string `json:"statusId,omitempty"`
ExcludeFromAutoHyperlinking bool `json:"excludeFromAutoHyperlinking,omitempty"`
}
CreateAssetRequest is the request body for POST /rest/2.0/assets.
type CreateAssetResponse ¶ added in v0.0.29
type CreateAssetResponse struct {
ID string `json:"id"`
Name string `json:"name"`
DisplayName string `json:"displayName"`
Type CreateAssetTypeRef `json:"type"`
Domain CreateAssetDomainRef `json:"domain"`
Status *CreateAssetStatusRef `json:"status,omitempty"`
CreatedBy string `json:"createdBy"`
CreatedOn int64 `json:"createdOn"`
LastModifiedBy string `json:"lastModifiedBy"`
LastModifiedOn int64 `json:"lastModifiedOn"`
}
CreateAssetResponse is the response from POST /rest/2.0/assets.
func CreateAsset ¶ added in v0.0.29
func CreateAsset(ctx context.Context, client *http.Client, request CreateAssetRequest) (*CreateAssetResponse, error)
CreateAsset creates a new asset via POST /rest/2.0/assets.
type CreateAssetStatusRef ¶ added in v0.0.33
CreateAssetStatusRef is a reference to a status in a create asset response.
type CreateAssetTypeRef ¶ added in v0.0.29
CreateAssetTypeRef is a reference to an asset type in a create asset response.
type CreateAttributeAssetRef ¶ added in v0.0.29
type CreateAttributeAssetRef struct {
ID string `json:"id"`
}
CreateAttributeAssetRef is a reference to an asset in an attribute response.
type CreateAttributeRequest ¶ added in v0.0.29
type CreateAttributeRequest struct {
AssetID string `json:"assetId"`
TypeID string `json:"typeId"`
Value string `json:"value"`
}
CreateAttributeRequest is the request body for POST /rest/2.0/attributes.
type CreateAttributeResponse ¶ added in v0.0.29
type CreateAttributeResponse struct {
ID string `json:"id"`
Type CreateAttributeTypeRef `json:"type"`
Asset CreateAttributeAssetRef `json:"asset"`
Value string `json:"value"`
}
CreateAttributeResponse is the response from POST /rest/2.0/attributes.
func CreateAttribute ¶ added in v0.0.29
func CreateAttribute(ctx context.Context, client *http.Client, request CreateAttributeRequest) (*CreateAttributeResponse, error)
CreateAttribute creates a new attribute on an asset via POST /rest/2.0/attributes.
type CreateAttributeTypeRef ¶ added in v0.0.29
CreateAttributeTypeRef is a reference to an attribute type.
type DataClass ¶
type DataClass struct {
ID string `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
Status string `json:"status"`
ColumnNameFilters []string `json:"columnNameFilters"`
ColumnTypeFilters []string `json:"columnTypeFilters"`
AllowNullValues bool `json:"allowNullValues"`
AllowEmptyValues bool `json:"allowEmptyValues"`
ConfidenceThreshold int `json:"confidenceThreshold"`
Examples []string `json:"examples"`
CreatedBy string `json:"createdBy"`
CreatedOn int64 `json:"createdOn"`
LastModifiedBy string `json:"lastModifiedBy"`
LastModifiedOn int64 `json:"lastModifiedOn"`
Rules []json.RawMessage `json:"rules"`
}
func SearchDataClasses ¶
type DataClassQueryParams ¶
type DataClassQueryParams struct {
ContainsRules *bool `url:"containsRules,omitempty"`
CorrelationID string `url:"correlationId,omitempty"`
DataClassGroupID string `url:"dataClassGroupId,omitempty"`
Description string `url:"description,omitempty"`
Limit *int `url:"limit,omitempty"`
Name string `url:"name,omitempty"`
Offset *int `url:"offset,omitempty"`
RuleType []string `url:"ruleType,omitempty"`
Status []string `url:"status,omitempty"`
View string `url:"view,omitempty"`
}
type DataClassesResponse ¶
type DataClassification ¶
type DataClassificationMatch ¶
type DataClassificationMatch struct {
ID string `json:"id"`
CreatedBy string `json:"createdBy"`
CreatedOn int64 `json:"createdOn"`
LastModifiedBy string `json:"lastModifiedBy"`
LastModifiedOn int64 `json:"lastModifiedOn"`
System bool `json:"system"`
ResourceType string `json:"resourceType"`
Status string `json:"status"`
Confidence float64 `json:"confidence"`
Asset NamedResourceReference `json:"asset"`
Classification DataClassification `json:"classification"`
}
func AddDataClassificationMatch ¶
func AddDataClassificationMatch(ctx context.Context, httpClient *http.Client, request AddDataClassificationMatchRequest) (*DataClassificationMatch, error)
func SearchDataClassificationMatches ¶
func SearchDataClassificationMatches(ctx context.Context, httpClient *http.Client, params DataClassificationMatchQueryParams) ([]DataClassificationMatch, int64, error)
type DataClassificationMatchQueryParams ¶
type DataClassificationMatchQueryParams struct {
Offset *int `url:"offset,omitempty"`
Limit *int `url:"limit,omitempty"`
CountLimit *int `url:"countLimit,omitempty"`
AssetIDs []string `url:"assetIds,omitempty"`
Statuses []string `url:"statuses,omitempty"`
ClassificationIDs []string `url:"classificationIds,omitempty"`
AssetTypeIDs []string `url:"assetTypeIds,omitempty"`
}
type DataContract ¶
type DataContract struct {
ID string `json:"id"`
DomainID string `json:"domainId"`
ManifestID string `json:"manifestId"`
}
DataContract represents metadata attributes of a data contract
type DataContractListPaginated ¶
type DataContractListPaginated struct {
Items []DataContract `json:"items"`
Limit int `json:"limit"`
NextCursor string `json:"nextCursor,omitempty"`
Total int `json:"total,omitempty"`
}
DataContractListPaginated represents the paginated response from the data contracts API
func ListDataContracts ¶
func ParseDataContractsResponse ¶
func ParseDataContractsResponse(jsonData []byte) (*DataContractListPaginated, error)
type DateAttribute ¶
type DateAttribute struct {
Value string `json:"dateValue"`
Type *AttributeType `json:"type,omitempty"`
}
type EditAssetAddTagsRequest ¶ added in v0.0.32
type EditAssetAddTagsRequest struct {
TagNames []string `json:"tagNames"`
}
EditAssetAddTagsRequest is the body for POST /rest/2.0/assets/{id}/tags. Collibra expects the field to be named "tagNames" — sending "tags" is silently ignored by the API and yields a "tagNames may not be null" 400.
type EditAssetAssignment ¶ added in v0.0.32
type EditAssetAssignment struct {
AssetType EditAssetTypeRef `json:"assetType"`
DomainType *EditAssetDomainTypeRef `json:"domainType,omitempty"`
AttributeTypes []EditAssetAssignmentAttributeType `json:"attributeTypes"`
RelationTypes []EditAssetAssignmentRelationType `json:"relationTypes,omitempty"`
}
EditAssetAssignment is the scoped assignment for a (asset type, domain type) pair — lists which attribute and relation types are valid for assets of this shape. This is the public shape the edit_asset tool consumes; it is built up from Collibra's raw assignment response by GetAssignmentForAssetType.
func GetAssignmentForAssetType ¶ added in v0.0.32
func GetAssignmentForAssetType(ctx context.Context, client *http.Client, assetTypeID, domainTypeID string) (*EditAssetAssignment, error)
GetAssignmentForAssetType returns the scoped assignment for an (asset type, domain type) pair, listing valid attribute and relation types. Collibra's endpoint returns an array — typically one entry per matching scope. We merge attribute and relation types across the returned entries; if a domainTypeID was supplied, we filter to entries that match it (when present on the entry), otherwise we use everything returned.
type EditAssetAssignmentAttributeType ¶ added in v0.0.32
type EditAssetAssignmentAttributeType struct {
ID string `json:"id"`
Name string `json:"name"`
Kind string `json:"kind,omitempty"`
Required bool `json:"required,omitempty"`
Constraints *EditAssetAssignmentConstraints `json:"constraints,omitempty"`
}
EditAssetAssignmentAttributeType is an attribute type allowed by a scoped assignment, with its full name and (optional) constraints.
type EditAssetAssignmentConstraints ¶ added in v0.0.32
type EditAssetAssignmentConstraints struct {
MinLength *int `json:"minLength,omitempty"`
MaxLength *int `json:"maxLength,omitempty"`
Min *float64 `json:"min,omitempty"`
Max *float64 `json:"max,omitempty"`
}
EditAssetAssignmentConstraints captures attribute type constraints used to validate operation values before any writes.
type EditAssetAssignmentRelationType ¶ added in v0.0.32
type EditAssetAssignmentRelationType struct {
ID string `json:"id"`
Role string `json:"role"`
CoRole string `json:"coRole,omitempty"`
SourceType *EditAssetTypeRef `json:"sourceType,omitempty"`
TargetType *EditAssetTypeRef `json:"targetType,omitempty"`
}
EditAssetAssignmentRelationType is a relation type allowed by a scoped assignment, in the direction where the edited asset is the source (head). Role is the forward name (e.g. "synonym"); CoRole is the reverse name.
type EditAssetAttributeAssetRef ¶ added in v0.0.32
type EditAssetAttributeAssetRef struct {
ID string `json:"id"`
}
EditAssetAttributeAssetRef is a reference to the owning asset.
type EditAssetAttributeInstance ¶ added in v0.0.32
type EditAssetAttributeInstance struct {
ID string `json:"id"`
Type EditAssetAttributeTypeRef `json:"type"`
Asset EditAssetAttributeAssetRef `json:"asset"`
Value string `json:"value"`
}
EditAssetAttributeInstance is a single attribute value on an asset, returned by GET /rest/2.0/attributes?assetId=....
func BulkCreateAttributes ¶ added in v0.0.32
func BulkCreateAttributes(ctx context.Context, client *http.Client, items []CreateAttributeRequest) ([]EditAssetAttributeInstance, error)
BulkCreateAttributes creates multiple attribute instances in one round trip via POST /rest/2.0/attributes/bulk. Treated as all-or-nothing: if the whole batch fails, the caller marks every affected op as failed with the batch error. Partial-row failures from Collibra aren't parsed individually.
func BulkPatchAttributes ¶ added in v0.0.32
func BulkPatchAttributes(ctx context.Context, client *http.Client, items []EditAssetBulkPatchAttributeItem) ([]EditAssetAttributeInstance, error)
BulkPatchAttributes updates multiple attribute instances in one round trip via PATCH /rest/2.0/attributes/bulk. All-or-nothing, same rationale as BulkCreateAttributes.
func CreateAttributeOnAsset ¶ added in v0.0.32
func CreateAttributeOnAsset(ctx context.Context, client *http.Client, assetID, attrTypeID, value string) (*EditAssetAttributeInstance, error)
CreateAttributeOnAsset adds a single attribute instance via POST /rest/2.0/attributes. It mirrors CreateAttribute in create_asset_client.go but returns the richer EditAssetAttributeInstance shape for diff tracking.
func ListAttributesForAsset ¶ added in v0.0.32
func ListAttributesForAsset(ctx context.Context, client *http.Client, assetID string) ([]EditAssetAttributeInstance, error)
ListAttributesForAsset fetches all attribute instances on an asset. Pages are followed transparently so the caller gets the full list.
func PatchAttributeValue ¶ added in v0.0.32
func PatchAttributeValue(ctx context.Context, client *http.Client, attributeID, value string) (*EditAssetAttributeInstance, error)
PatchAttributeValue updates a single attribute instance's value via PATCH /rest/2.0/attributes/{id}.
func (*EditAssetAttributeInstance) UnmarshalJSON ¶ added in v0.0.32
func (a *EditAssetAttributeInstance) UnmarshalJSON(data []byte) error
UnmarshalJSON tolerates `value` fields returned as JSON numbers, booleans, or null. Collibra emits the field with whatever underlying type the attribute kind dictates (NumericAttributeType -> number, BooleanAttributeType -> bool, etc.), so a strict string decode fails when an asset has any non-string attribute. We stringify any scalar and treat null as the empty string; consumers only need a printable representation for diffs and error messages.
type EditAssetAttributeTypeRef ¶ added in v0.0.32
EditAssetAttributeTypeRef is a reference to an attribute type on an instance.
type EditAssetBulkPatchAttributeItem ¶ added in v0.0.32
EditAssetBulkPatchAttributeItem is one row of PATCH /rest/2.0/attributes/bulk.
type EditAssetCore ¶ added in v0.0.32
type EditAssetCore struct {
ID string `json:"id"`
Name string `json:"name"`
DisplayName string `json:"displayName,omitempty"`
Type EditAssetTypeRef `json:"type"`
Domain EditAssetDomainRef `json:"domain"`
Status *EditAssetStatusRef `json:"status,omitempty"`
}
EditAssetCore is the slim view of an asset returned by GET /rest/2.0/assets/{id} that the edit_asset tool needs for validation and dispatch.
func GetAssetCore ¶ added in v0.0.32
GetAssetCore fetches the core asset shape needed by the edit_asset tool.
func PatchAsset ¶ added in v0.0.32
func PatchAsset(ctx context.Context, client *http.Client, assetID string, payload EditAssetPatchRequest) (*EditAssetCore, error)
PatchAsset updates the whitelisted core fields (name, displayName, statusId) on an asset via PATCH /rest/2.0/assets/{id}.
type EditAssetCreateRelationRequest ¶ added in v0.0.32
type EditAssetCreateRelationRequest struct {
SourceID string `json:"sourceId"`
TargetID string `json:"targetId"`
TypeID string `json:"typeId"`
}
EditAssetCreateRelationRequest is the body for POST /rest/2.0/relations.
type EditAssetCreateResponsibilityRequest ¶ added in v0.0.32
type EditAssetCreateResponsibilityRequest struct {
RoleID string `json:"roleId"`
OwnerID string `json:"ownerId"`
ResourceID string `json:"resourceId"`
}
EditAssetCreateResponsibilityRequest is the body for POST /rest/2.0/responsibilities.
type EditAssetDomainDetails ¶ added in v0.0.32
type EditAssetDomainDetails struct {
ID string `json:"id"`
Name string `json:"name"`
Type *EditAssetDomainTypeRef `json:"type,omitempty"`
}
EditAssetDomainDetails is the view of a domain that exposes its domain type, returned by GET /rest/2.0/domains/{id}. Needed to scope the assignment.
func GetDomainDetails ¶ added in v0.0.32
func GetDomainDetails(ctx context.Context, client *http.Client, domainID string) (*EditAssetDomainDetails, error)
GetDomainDetails fetches a domain including its domain type reference, used to scope the assignment lookup.
type EditAssetDomainRef ¶ added in v0.0.32
EditAssetDomainRef is a reference to a domain on an asset.
type EditAssetDomainTypeRef ¶ added in v0.0.32
EditAssetDomainTypeRef is a reference to a domain type.
type EditAssetPatchAttributeRequest ¶ added in v0.0.32
type EditAssetPatchAttributeRequest struct {
Value string `json:"value"`
}
EditAssetPatchAttributeRequest is the body for PATCH /rest/2.0/attributes/{id}.
type EditAssetPatchRequest ¶ added in v0.0.32
type EditAssetPatchRequest struct {
Name *string `json:"name,omitempty"`
DisplayName *string `json:"displayName,omitempty"`
StatusID *string `json:"statusId,omitempty"`
}
EditAssetPatchRequest is the body for PATCH /rest/2.0/assets/{id} — only the fields allowed by update_property (name, displayName, statusId).
type EditAssetRelation ¶ added in v0.0.32
type EditAssetRelation struct {
ID string `json:"id"`
Type EditAssetTypeRef `json:"type"`
Source EditAssetAttributeAssetRef `json:"source"`
Target EditAssetAttributeAssetRef `json:"target"`
}
EditAssetRelation is a relation instance between two assets.
func BulkCreateRelations ¶ added in v0.0.32
func BulkCreateRelations(ctx context.Context, client *http.Client, items []EditAssetCreateRelationRequest) ([]EditAssetRelation, error)
BulkCreateRelations creates multiple relations in one round trip via POST /rest/2.0/relations/bulk.
func CreateRelation ¶ added in v0.0.32
func CreateRelation(ctx context.Context, client *http.Client, payload EditAssetCreateRelationRequest) (*EditAssetRelation, error)
CreateRelation posts a new relation via POST /rest/2.0/relations. The source asset is the head; target is the tail.
type EditAssetResponsibility ¶ added in v0.0.32
type EditAssetResponsibility struct {
ID string `json:"id"`
RoleID string `json:"roleId,omitempty"`
OwnerID string `json:"ownerId,omitempty"`
ResourceID string `json:"resourceId,omitempty"`
}
EditAssetResponsibility is a responsibility instance linking a role, an owner (user or group), and an asset.
func CreateResponsibility ¶ added in v0.0.32
func CreateResponsibility(ctx context.Context, client *http.Client, payload EditAssetCreateResponsibilityRequest) (*EditAssetResponsibility, error)
CreateResponsibility assigns a role to an owner for an asset via POST /rest/2.0/responsibilities. This is incremental — it doesn't replace other responsibilities on the asset.
type EditAssetRole ¶ added in v0.0.32
EditAssetRole is a resource role (e.g. Steward, Owner) that can be assigned to an asset via responsibilities.
type EditAssetStatus ¶ added in v0.0.32
EditAssetStatus is a status (e.g. Candidate, Accepted, Obsolete) that can be assigned to an asset via update_property statusId.
func ListStatuses ¶ added in v0.0.32
ListStatuses returns all asset statuses defined in Collibra. Used to resolve a status name (e.g. "Candidate") to its UUID before patching an asset.
type EditAssetStatusRef ¶ added in v0.0.32
EditAssetStatusRef is a reference to the asset's status.
type EditAssetTypeRef ¶ added in v0.0.32
EditAssetTypeRef is a reference to an asset type.
type EditAssetUser ¶ added in v0.0.32
type EditAssetUser struct {
ID string `json:"id"`
UserName string `json:"userName,omitempty"`
EmailAddress string `json:"emailAddress,omitempty"`
FirstName string `json:"firstName,omitempty"`
LastName string `json:"lastName,omitempty"`
}
EditAssetUser is a Collibra user, used to resolve a username or email to the user's UUID before assigning responsibilities.
func FindUserByEmail ¶ added in v0.0.32
func FindUserByEmail(ctx context.Context, client *http.Client, email string) (*EditAssetUser, error)
FindUserByEmail returns the first user matching an email address, or nil if none exists.
func FindUserByUsername ¶ added in v0.0.32
func FindUserByUsername(ctx context.Context, client *http.Client, username string) (*EditAssetUser, error)
FindUserByUsername returns the first user matching a username, or nil if none exists. Used by set_responsibility to resolve "jane.smith" to a UUID.
type Error ¶
type Error struct {
Message string `json:"message"`
Path []interface{} `json:"path,omitempty"`
}
type GetLineageDirectionalOutput ¶ added in v0.0.27
type GetLineageDirectionalOutput struct {
EntityId string `json:"entityId"`
Direction LineageDirection `json:"direction"`
Relations []LineageRelation `json:"relations"`
Pagination *LineagePagination `json:"pagination,omitempty"`
Warnings []LineageResponseWarning `json:"warnings,omitempty"`
Error string `json:"error,omitempty"`
}
func GetLineageDownstream ¶ added in v0.0.27
type GetLineageEntityOutput ¶ added in v0.0.27
type GetLineageEntityOutput struct {
Entity *LineageEntity `json:"entity,omitempty"`
Error string `json:"error,omitempty"`
Found bool `json:"found"`
}
func GetLineageEntity ¶ added in v0.0.27
type GetLineageTransformationOutput ¶ added in v0.0.27
type GetLineageTransformationOutput struct {
Transformation *LineageTransformation `json:"transformation,omitempty"`
Error string `json:"error,omitempty"`
Found bool `json:"found"`
}
func GetLineageTransformation ¶ added in v0.0.27
type IncomingRelation ¶
type IncomingRelation struct {
Type *RelationType `json:"type,omitempty"`
Source *RelatedAsset `json:"source,omitempty"`
}
type LineageDirection ¶ added in v0.0.27
type LineageDirection string
const ( LineageDirectionUpstream LineageDirection = "upstream" LineageDirectionDownstream LineageDirection = "downstream" )
type LineageEntity ¶ added in v0.0.27
type LineageEntity struct {
Id string `json:"id"`
Name string `json:"name"`
Type string `json:"type"`
SourceIds []string `json:"sourceIds,omitempty"`
DgcId string `json:"dgcId,omitempty"`
ParentId string `json:"parentId,omitempty"`
}
func (*LineageEntity) UnmarshalJSON ¶ added in v0.0.27
func (e *LineageEntity) UnmarshalJSON(data []byte) error
UnmarshalJSON handles both plain string values and JsonNullable-wrapped objects for the DgcId and ParentId fields. The server may serialize JsonNullable<T> as {"present": false, "undefined": true} when JsonNullableModule is not on the classpath.
type LineagePagination ¶ added in v0.0.27
type LineagePagination struct {
NextCursor string `json:"nextCursor,omitempty"`
}
type LineageRelation ¶ added in v0.0.27
type LineageResponseWarning ¶ added in v0.0.27
type LineageTransformation ¶ added in v0.0.27
type NamedResourceReference ¶
type NumericAttribute ¶
type NumericAttribute struct {
Value float64 `json:"numericValue"`
Type *AttributeType `json:"type,omitempty"`
}
type OutgoingRelation ¶
type OutgoingRelation struct {
Type *RelationType `json:"type,omitempty"`
Target *RelatedAsset `json:"target,omitempty"`
}
type PagedResponseDataClassificationMatch ¶
type PagedResponseDataClassificationMatch struct {
Total int64 `json:"total"`
Offset int64 `json:"offset"`
Limit int64 `json:"limit"`
Results []DataClassificationMatch `json:"results"`
}
type PrepareCreateAllowedDomainType ¶ added in v0.0.33
PrepareCreateAllowedDomainType is one domain type an asset type can be created in. The set is deduped across all of an asset type's assignments (an asset type may be allowed in multiple domain types).
func ListAllowedDomainTypesForAssetType ¶ added in v0.0.33
func ListAllowedDomainTypesForAssetType(ctx context.Context, client *http.Client, assetTypeID string) ([]PrepareCreateAllowedDomainType, error)
ListAllowedDomainTypesForAssetType returns the deduped list of domain type IDs the asset type can be created in, walking the parent chain when needed. Subtypes whose own assignments have empty domainTypes (inherit-sentinel) inherit their parent's allowed types — e.g. Acronym → Business Term → Glossary, Business Asset Domain.
type PrepareCreateAssetResult ¶ added in v0.0.29
PrepareCreateAssetResult represents an existing asset found during duplicate check.
type PrepareCreateAssetSearchResponse ¶ added in v0.0.29
type PrepareCreateAssetSearchResponse struct {
Results []PrepareCreateAssetResult `json:"results"`
Total int `json:"total"`
}
PrepareCreateAssetSearchResponse is the response from searching assets.
type PrepareCreateAssetStatus ¶ added in v0.0.29
type PrepareCreateAssetStatus string
PrepareCreateAssetStatus represents the status of asset creation readiness.
const ( StatusReady PrepareCreateAssetStatus = "ready" StatusIncomplete PrepareCreateAssetStatus = "incomplete" StatusNeedsClarification PrepareCreateAssetStatus = "needs_clarification" StatusDuplicateFound PrepareCreateAssetStatus = "duplicate_found" )
type PrepareCreateAssetType ¶ added in v0.0.29
type PrepareCreateAssetType struct {
ID string `json:"id"`
PublicID string `json:"publicId"`
Name string `json:"name"`
Parent *PrepareCreateAssetType `json:"parent,omitempty"`
}
PrepareCreateAssetType represents an asset type from the API. Parent is populated by /assetTypes/{id} for subtypes (e.g. Acronym → Business Term) and is the key for walking the inheritance chain when the subtype's own scoped-assignment record has empty domainTypes (which Collibra uses as the "inherit from parent" sentinel).
func GetAssetTypeByID ¶ added in v0.0.33
func GetAssetTypeByID(ctx context.Context, client *http.Client, id string) (*PrepareCreateAssetType, error)
GetAssetTypeByID resolves an asset type by its UUID. Used as the first resolution strategy in the consolidated create_asset, before falling back to publicId or name search.
func GetAssetTypeByPublicID ¶ added in v0.0.29
func GetAssetTypeByPublicID(ctx context.Context, client *http.Client, publicID string) (*PrepareCreateAssetType, error)
GetAssetTypeByPublicID resolves an asset type by its publicId.
func GetAvailableAssetTypesForDomain ¶ added in v0.0.29
func GetAvailableAssetTypesForDomain(ctx context.Context, client *http.Client, domainID string) ([]PrepareCreateAssetType, error)
GetAvailableAssetTypesForDomain returns the asset types allowed in a given domain.
func ListAssetTypesForPrepare ¶ added in v0.0.29
func ListAssetTypesForPrepare(ctx context.Context, client *http.Client, limit int) ([]PrepareCreateAssetType, int, error)
ListAssetTypesForPrepare lists asset types, limited to the given count.
func SearchAssetTypesByName ¶ added in v0.0.33
func SearchAssetTypesByName(ctx context.Context, client *http.Client, name string, limit int) ([]PrepareCreateAssetType, int, error)
SearchAssetTypesByName queries /assetTypes?name=… and returns the matches up to the given limit. Collibra performs a case-insensitive substring match server-side, so callers should still verify exact equality if they only want exact matches.
type PrepareCreateAssetTypeListResponse ¶ added in v0.0.29
type PrepareCreateAssetTypeListResponse struct {
Results []PrepareCreateAssetType `json:"results"`
Total int `json:"total"`
}
PrepareCreateAssetTypeListResponse is the response from listing asset types.
type PrepareCreateAttributeType ¶ added in v0.0.29
type PrepareCreateAttributeType struct {
ID string `json:"id"`
Name string `json:"name"`
Kind string `json:"kind"`
Required bool `json:"required"`
Constraints *PrepareCreateConstraints `json:"constraints,omitempty"`
AllowedValues []string `json:"allowedValues,omitempty"`
Direction string `json:"direction,omitempty"`
TargetAssetType *PrepareCreateAssetType `json:"targetAssetType,omitempty"`
}
PrepareCreateAttributeType represents an attribute type with full schema.
func GetAttributeTypeByID ¶ added in v0.0.29
func GetAttributeTypeByID(ctx context.Context, client *http.Client, attrTypeID string) (*PrepareCreateAttributeType, error)
GetAttributeTypeByID gets the full attribute type schema by ID.
type PrepareCreateAttributeTypeFull ¶ added in v0.0.33
type PrepareCreateAttributeTypeFull struct {
ID string `json:"id"`
Name string `json:"name"`
PublicID string `json:"publicId"`
Kind string `json:"attributeTypeDiscriminator"`
StringType string `json:"stringType,omitempty"`
Description string `json:"description,omitempty"`
AllowedValues []string `json:"allowedValues,omitempty"`
}
PrepareCreateAttributeTypeFull is the full /attributeTypes/{id} response — includes StringType ("RICH_TEXT", "PLAIN_TEXT", etc.) which write tools use to decide whether to convert Markdown to HTML before submission.
func GetAttributeTypeFull ¶ added in v0.0.33
func GetAttributeTypeFull(ctx context.Context, client *http.Client, id string) (*PrepareCreateAttributeTypeFull, error)
GetAttributeTypeFull fetches /attributeTypes/{id} and decodes the full shape including stringType — needed for create_asset / edit_asset to gate Markdown→HTML conversion on RICH_TEXT attributes.
type PrepareCreateConstraints ¶ added in v0.0.29
type PrepareCreateConstraints struct {
MinLength *int `json:"minLength,omitempty"`
MaxLength *int `json:"maxLength,omitempty"`
Min *float64 `json:"min,omitempty"`
Max *float64 `json:"max,omitempty"`
}
PrepareCreateConstraints represents attribute validation constraints.
type PrepareCreateDomain ¶ added in v0.0.29
type PrepareCreateDomain struct {
ID string `json:"id"`
Name string `json:"name"`
Type *PrepareCreateDomainType `json:"type,omitempty"`
}
PrepareCreateDomain represents a domain from the API. Type is populated by the list and detail endpoints, but not by older callers that only decoded {id, name}; tolerate a missing type field there.
func GetDomainByID ¶ added in v0.0.29
func GetDomainByID(ctx context.Context, client *http.Client, domainID string) (*PrepareCreateDomain, error)
GetDomainByID gets a specific domain by its ID.
func ListDomainsForPrepare ¶ added in v0.0.29
func ListDomainsForPrepare(ctx context.Context, client *http.Client, limit int) ([]PrepareCreateDomain, int, error)
ListDomainsForPrepare lists domains, limited to the given count.
func SearchDomainsByName ¶ added in v0.0.33
func SearchDomainsByName(ctx context.Context, client *http.Client, name string, limit int) ([]PrepareCreateDomain, int, error)
SearchDomainsByName queries /domains?name=… and returns the matches up to the given limit. The list endpoint already includes the domain Type in each result, so callers that need to look up a scoped assignment can keep working from the result without an extra GET /domains/{id}.
type PrepareCreateDomainListResponse ¶ added in v0.0.29
type PrepareCreateDomainListResponse struct {
Results []PrepareCreateDomain `json:"results"`
Total int `json:"total"`
}
PrepareCreateDomainListResponse is the response from listing domains.
type PrepareCreateDomainType ¶ added in v0.0.33
PrepareCreateDomainType is a reference to a Collibra domain type — the scoped-assignment lookup keys off this ID to find the effective assignment for an asset type in a given domain.
type PrepareCreateScopedAssignment ¶ added in v0.0.33
type PrepareCreateScopedAssignment struct {
AssignmentID string
Attributes []PrepareCreateScopedAttribute
Relations []PrepareCreateScopedRelation
}
PrepareCreateScopedAssignment is the effective assignment for a given (assetType, domainType) pair: the union of the assignment's attribute slots and the relation slots that apply to assets of this type when created in domains of this type.
func GetScopedAssignment ¶ added in v0.0.33
func GetScopedAssignment(ctx context.Context, client *http.Client, assetTypeID, domainTypeID string) (*PrepareCreateScopedAssignment, error)
GetScopedAssignment returns the effective scoped assignment for an (assetType, domainType) pair, walking the asset type's parent chain when needed. Collibra's data model lets a subtype omit domainTypes on its own assignment (signalling "inherit from parent") and contribute its own characteristics on top — see Acronym → Business Term in OOTB glossary. The result here is the union of all chain levels' applicable characteristics, where applicable means the assignment either explicitly lists the target domainTypeID or has empty domainTypes (the inherit-sentinel). At least one level in the chain must explicitly include the target domain type, otherwise we return "not allowed" — empty-domainTypes-everywhere is not the same as "creatable everywhere".
type PrepareCreateScopedAttribute ¶ added in v0.0.33
type PrepareCreateScopedAttribute struct {
AttributeTypeID string
AttributeTypeName string
AttributeTypePublicID string
Kind string
Required bool
Min int
// Max is nil when there is no upper bound (i.e. unbounded).
Max *int
}
PrepareCreateScopedAttribute is one attribute slot in a scoped assignment: what attribute type it refers to, whether it's required, and how many instances are allowed. Kind comes from the assignment's resourceDiscriminator (e.g. "StringAttributeType") so it's never empty for valid responses.
type PrepareCreateScopedRelation ¶ added in v0.0.33
type PrepareCreateScopedRelation struct {
RelationTypeID string
Role string
CoRole string
// Direction is "SOURCE_TO_TARGET" or "TARGET_TO_SOURCE" — describing
// which side of the relation the asset being created sits on.
Direction string
// TargetType is the asset type on the other side of the relation.
TargetType *PrepareCreateAssetType
}
PrepareCreateScopedRelation is one relation slot in a scoped assignment.
type PrepareCreateStatus ¶ added in v0.0.33
PrepareCreateStatus is one Collibra status value (e.g. "Candidate").
func ListStatusesAll ¶ added in v0.0.33
ListStatusesAll fetches every status value defined in the instance. Status counts are small (~30) and fit comfortably in a single page; the limit guard is just defensive.
type PrepareCreateStatusListResponse ¶ added in v0.0.33
type PrepareCreateStatusListResponse struct {
Results []PrepareCreateStatus `json:"results"`
Total int `json:"total"`
}
PrepareCreateStatusListResponse is the paged response for /statuses.
type PushDataContractManifestRequest ¶
type PushDataContractManifestRequest struct {
Manifest string
ManifestID string
Version string
Force bool
Active bool
}
PushDataContractManifestRequest represents the request parameters for pushing a data contract manifest
type PushDataContractManifestResponse ¶
type PushDataContractManifestResponse struct {
ID string `json:"id"`
DomainID string `json:"domainId"`
ManifestID string `json:"manifestId"`
}
PushDataContractManifestResponse represents the response from pushing a data contract manifest
func ParseAddFromManifestResponse ¶
func ParseAddFromManifestResponse(jsonData []byte) (*PushDataContractManifestResponse, error)
func PushDataContractManifest ¶
func PushDataContractManifest(ctx context.Context, collibraHttpClient *http.Client, reqParams PushDataContractManifestRequest) (*PushDataContractManifestResponse, error)
type RelatedAsset ¶
type Relation ¶ added in v0.0.26
type Relation struct {
ID string `json:"id"`
Source RelationAsset `json:"source"`
Target RelationAsset `json:"target"`
}
type RelationAsset ¶ added in v0.0.26
type RelationType ¶
type RelationsQueryParams ¶ added in v0.0.26
type RelationsResponse ¶ added in v0.0.26
type RelationsResponse struct {
Total int `json:"total"`
Offset int `json:"offset"`
Limit int `json:"limit"`
Results []Relation `json:"results"`
}
func GetRelations ¶ added in v0.0.26
func GetRelations(ctx context.Context, client *http.Client, params RelationsQueryParams) (*RelationsResponse, error)
GetRelations queries the Collibra relations API.
type Request ¶
type ResourceRef ¶ added in v0.0.28
type ResourceRef struct {
ID string `json:"id"`
ResourceDiscriminator string `json:"resourceDiscriminator"`
}
ResourceRef represents a reference to a resource (user, group, community, etc.) in the API.
type ResourceRole ¶ added in v0.0.28
ResourceRole represents the role in a responsibility (e.g., Owner, Steward).
type Response ¶
type Response struct {
Data *AssetQueryData `json:"data,omitempty"`
Errors []Error `json:"errors,omitempty"`
}
type Responsibility ¶ added in v0.0.28
type Responsibility struct {
ID string `json:"id"`
Role *ResourceRole `json:"role,omitempty"`
Owner *ResourceRef `json:"owner,omitempty"`
BaseResource *ResourceRef `json:"baseResource,omitempty"`
System bool `json:"system"`
}
Responsibility represents a single responsibility assignment for an asset.
func GetResponsibilities ¶ added in v0.0.28
func GetResponsibilities(ctx context.Context, collibraHttpClient *http.Client, assetID string) ([]Responsibility, error)
GetResponsibilities fetches all responsibilities for the given asset ID, including inherited ones.
type ResponsibilityPagedResponse ¶ added in v0.0.28
type ResponsibilityPagedResponse struct {
Total int64 `json:"total"`
Offset int64 `json:"offset"`
Limit int64 `json:"limit"`
Results []Responsibility `json:"results"`
}
ResponsibilityPagedResponse represents the paginated response from the responsibilities API.
type ResponsibilityQueryParams ¶ added in v0.0.28
type ResponsibilityQueryParams struct {
ResourceIDs string `url:"resourceIds,omitempty"`
IncludeInherited bool `url:"includeInherited,omitempty"`
Limit int `url:"limit,omitempty"`
Offset int `url:"offset,omitempty"`
}
ResponsibilityQueryParams defines the query parameters for the responsibilities API.
type SearchAggregation ¶
type SearchAggregation struct {
Field string `json:"field"`
Values []SearchAggregationValue `json:"values"`
}
type SearchAggregationValue ¶
type SearchAggregationValue struct {
}
type SearchField ¶
type SearchFilter ¶
type SearchHighlight ¶
type SearchHighlight struct {
}
type SearchLineageEntitiesOutput ¶ added in v0.0.27
type SearchLineageEntitiesOutput struct {
Results []LineageEntity `json:"results"`
Pagination *LineagePagination `json:"pagination,omitempty"`
Warnings []LineageResponseWarning `json:"warnings,omitempty"`
}
type SearchLineageTransformationsOutput ¶ added in v0.0.27
type SearchLineageTransformationsOutput struct {
Results []TransformationSummary `json:"results"`
Pagination *LineagePagination `json:"pagination,omitempty"`
Warnings []LineageResponseWarning `json:"warnings,omitempty"`
}
type SearchRequest ¶
type SearchRequest struct {
Keywords string `json:"keywords"`
SearchInFields []SearchField `json:"searchInFields,omitempty"`
Filters []SearchFilter `json:"filters,omitempty"`
Limit int `json:"limit"`
Offset int `json:"offset"`
}
SearchRequest represents the request payload for the Collibra search API
func CreateSearchRequest ¶
func CreateSearchRequest(question string, resourceTypes []string, filters []SearchFilter, limit int, offset int) SearchRequest
type SearchResource ¶
type SearchResponse ¶
type SearchResponse struct {
Total int `json:"total"`
Results []SearchResult `json:"results"`
Aggregations []SearchAggregation `json:"aggregations"`
}
SearchResponse represents the response from the Collibra search API
func ParseSearchResponse ¶
func ParseSearchResponse(jsonData []byte) (*SearchResponse, error)
func SearchKeyword ¶
type SearchResult ¶
type SearchResult struct {
Resource SearchResource `json:"resource"`
Highlights []SearchHighlight `json:"highlights"`
}
type StringAttribute ¶
type StringAttribute struct {
Value string `json:"stringValue"`
Type *AttributeType `json:"type,omitempty"`
}
type ToolContent ¶
type ToolMessage ¶
type ToolMessage struct {
MessagerRole string `json:"messagerRole"`
Content ToolContent `json:"content"`
Context ChatContext `json:"context"`
}
type ToolRequest ¶
type ToolRequest struct {
Message ToolMessage `json:"message"`
History []ToolMessage `json:"history"`
}
type ToolResponse ¶
type ToolResponse struct {
Content []ToolContent `json:"content"`
}
type TransformationSummary ¶ added in v0.0.27
type UserGroupResponse ¶ added in v0.0.28
UserGroupResponse represents the response from the /rest/2.0/userGroups/{groupId} endpoint.
Source Files
¶
- copilot_client.go
- create_asset_client.go
- dgc_classification_client.go
- dgc_classification_match_client.go
- dgc_client.go
- dgc_core_client.go
- dgc_datacontract_client.go
- dgc_gql_client.go
- dgc_relation_client.go
- dgc_responsibility_client.go
- dgc_search_client.go
- edit_asset_client.go
- lineage_client.go
- prepare_create_asset_client.go