Finds one item and retrieves the connection details that fabricQueryR can use. This is convenient when you know the item's name and do not need a collection of every item in the workspace.
Usage
fabric_item(
workspace,
item,
type = NULL,
personal_workspace_tenant_id = NULL,
personal_workspace_owner = NULL,
tenant_id = Sys.getenv("FABRICQUERYR_TENANT_ID"),
client_id = Sys.getenv("FABRICQUERYR_CLIENT_ID", unset =
"04b07795-8ddb-461a-bbee-02f9e1bf7b46"),
token = NULL,
auth_args = list(),
api_base = .fabric_api_base,
allow_custom_endpoint = FALSE
)Arguments
- workspace
Workspace GUID, exact display name, or a workspace record returned by
fabric_workspaces(). A record avoids an extra lookup and, if it containsapiEndpoint, routes workspace calls through that endpoint. A name is often easier for interactive use.- item
Item GUID, exact display name, or an item record returned by a discovery function. A display name must identify exactly one item of the requested
type; use a GUID or discovered record when names are duplicated.- type
Optional Fabric API item type, for example
"Lakehouse","Warehouse","SemanticModel", or"Notebook". Matching is done by Fabric, so use the API spelling. LeaveNULLto list all item types.- personal_workspace_tenant_id
Optional Microsoft Entra tenant ID used to build the XMLA endpoint for a Personal workspace.
- personal_workspace_owner
Optional owner UPN or Entra object ID used to build the XMLA endpoint for a Personal workspace. Microsoft Fabric's workspace API does not return either personal-workspace identifier, so supply this together with
personal_workspace_tenant_idwhen adax_connection_stringis needed for a semantic model in My Workspace.- tenant_id
Microsoft Entra tenant ID. Defaults to
FABRICQUERYR_TENANT_ID.- client_id
Microsoft Entra application/client ID. Defaults to
FABRICQUERYR_CLIENT_ID, then the Azure CLI application ID.- token
Preferred token input: an
AzureAuth::AzureTokenobject, bearer-token string, or token-provider function. WithNULL(the default),AzureAuthreuses a matching cached token or starts its normal interactive login flow when a new token is required.- auth_args
Named list of additional arguments passed to
AzureAuth::get_azure_token()when no token source is supplied. Discovery uses thehttps://api.fabric.microsoft.com/.defaultaudience and requiresWorkspace.Read.AllorWorkspace.ReadWrite.All.- api_base
Fabric REST API base URL. When
workspaceis a record containingapiEndpoint, that workspace-specific endpoint is used unlessapi_baseis supplied explicitly.- allow_custom_endpoint
Logical. Set to
TRUEonly whenapi_baseis a non-Microsoft HTTPS origin that you trust to receive a Fabric token.
Value
A fabric_item list. It contains common fields such as id,
displayName, type, and workspaceId, the nested workload
properties, and applicable connection targets. SQLDatabase records use
sql_connection_string; Lakehouse, Warehouse, and WarehouseSnapshot
records use sql_server and sql_database. Other workloads can include
livy_url, dax_connection_string, or query_service_uri.