ServiceProvider
ServiceProvider.Rd
Provides access to all services provided through the web API.
Details
This class allows interaction with the PetroVisor API by providing access to various services such as logging, repository, data, and tag entries.
Super class
Myrconn.PetroVisor.Client::ApiRequests
-> ServiceProvider
Public fields
url
Full URL to the PetroVisor API (either with or without token).
data_url
The base URL for data services.
workspace
The currently used workspace.
user
The current user.
client_token
Access token for the API (optional, used if URL is provided).
workspace_data_url
The URL for the workspace-specific data services.
logs
Instance of class
LoggingService
wrapping all logging-related functionalities.items
Instance of class
RepositoryService
wrapping all functionality related to PetroVisor items (entities, signals, units, etc.).data
Instance of class
DataServices
wrapping all functionality related to data.tag_entries
Instance of class
TagEntriesService
wrapping all functionality related to tag entries.files
Instance of class
FileService
wrapping all functionality related to files.
Methods
Method new()
Create a new ServiceProvider instance.
Usage
ServiceProvider$new(
url = NULL,
workspace = NULL,
user = NULL,
password = NULL,
client_token = NULL
)
Method parse_signal()
Parse the mapped signal received from PetroVisor to a list containing the name and unit of the mapped signal.
Examples
if (FALSE) { # \dontrun{
# Create a new instance of the service provider using token
sp <- ServiceProvider$new(
url = "https://identity.us1.petrovisor.com/PetroVisor/API/WorkspaceA/",
client_token = "your_token_here"
)
# Create a new instance of the service provider using username and password
sp <- ServiceProvider$new(
url = "https://identity.us1.petrovisor.com",
workspace = "WorkspaceA",
user = "your_username",
password = "your_password"
)
} # }