API sys - RapturePlatform/Rapture GitHub Wiki

Sys API

The sys api is used to modify System config at the low level, bypassing the normal api calls. To be used with great care as incorrect usage can disable an environment.

retrieveSystemConfig

HttpSysApi sysApi = new HttpSysApi(loginApi);
String retVal = sysApi.retrieveSystemConfig(area, path);
retVal = baseAPI.doSys_RetrieveSystemConfig(area, path);

Entitlement: /admin/root

Retrieve a system config

Function Parameters

Parameter Type Description
area String
path String

Return value

Type Description
String

writeSystemConfig

HttpSysApi sysApi = new HttpSysApi(loginApi);
String retVal = sysApi.writeSystemConfig(area, path, content);
retVal = baseAPI.doSys_WriteSystemConfig(area, path, content);

Entitlement: /admin/root

Write a system config

Function Parameters

Parameter Type Description
area String
path String
content String

Return value

Type Description
String

removeSystemConfig

HttpSysApi sysApi = new HttpSysApi(loginApi);
void retVal = sysApi.removeSystemConfig(area, path);
retVal = baseAPI.doSys_RemoveSystemConfig(area, path);

Entitlement: /admin/root

Remove a system document

Function Parameters

Parameter Type Description
area String
path String

Return value

Type Description
void

getSystemFolders

HttpSysApi sysApi = new HttpSysApi(loginApi);
List<RaptureFolderInfo> retVal = sysApi.getSystemFolders(area, path);
retVal = baseAPI.doSys_GetSystemFolders(area, path);

Entitlement: /admin/root

Gets the hiearchy (the documents below this point, like with user.getChildren)

Function Parameters

Parameter Type Description
area String
path String

Return value

Type Description
List

getAllTopLevelRepos

HttpSysApi sysApi = new HttpSysApi(loginApi);
List<String> retVal = sysApi.getAllTopLevelRepos();
retVal = baseAPI.doSys_GetAllTopLevelRepos();

Entitlement: /repo/read

Retrieve all top level repos

Function Parameters

This function takes no parameters.

Return value

Type Description
List

listByUriPrefix

HttpSysApi sysApi = new HttpSysApi(loginApi);
ChildrenTransferObject retVal = sysApi.listByUriPrefix(raptureURI, marker, depth, maximum, refresh);
retVal = baseAPI.doSys_ListByUriPrefix(raptureURI, marker, depth, maximum, refresh);

Entitlement: /repo/read

Get children from the specified point.URI Cannot be null, but it can be the IndexMark from the ChildrenTransferObject returned by a previous call.depth indicates the number of levels to retrieve data for.If maximum > 0 then cap the number of entries returnedif refresh is false and there are more results than the defined maximum then store the remainder in the cache for quick access next time If refresh is true and there are more results than the defined maximum then keep track of the values that have been returned. On the next call re-read the tree and return only new entries. This is much slower than without refresh because the tree is re-read each time.

Function Parameters

Parameter Type Description
raptureURI String
marker String
depth int
maximum Long
refresh boolean

Return value

Type Description
ChildrenTransferObject
Types used in this function

ChildrenTransferObject

Transfer Object to pass back children of URI.

Field Type
parentURI String
children Map<String,RaptureFolderInfo>
deleted Map<String,RaptureFolderInfo>
indexMark String
remainder Long

getChildren

HttpSysApi sysApi = new HttpSysApi(loginApi);
ChildrenTransferObject retVal = sysApi.getChildren(raptureURI);
retVal = baseAPI.doSys_GetChildren(raptureURI);

Entitlement: /repo/read

Retrieve all the immediate children of a URI

Function Parameters

Parameter Type Description
raptureURI String

Return value

Type Description
ChildrenTransferObject
Types used in this function

ChildrenTransferObject

Transfer Object to pass back children of URI.

Field Type
parentURI String
children Map<String,RaptureFolderInfo>
deleted Map<String,RaptureFolderInfo>
indexMark String
remainder Long

getAllChildren

HttpSysApi sysApi = new HttpSysApi(loginApi);
ChildrenTransferObject retVal = sysApi.getAllChildren(raptureURI, marker, maximum, refresh);
retVal = baseAPI.doSys_GetAllChildren(raptureURI, marker, maximum, refresh);

Entitlement: /repo/read

Retrieve all the children of a URI, spanning multiple levels. The page size must be specified. If refresh is false and there are more results than the defined page size then store the remainder in the cache for quick access next time If refresh is true and there are more results than the defined maximum then keep track of the values that have been returned. On the next call re-read the tree and return only new entries. This is slower than without refresh because the tree is re-read each time.

Function Parameters

Parameter Type Description
raptureURI String
marker String
maximum Long
refresh boolean

Return value

Type Description
ChildrenTransferObject
Types used in this function

ChildrenTransferObject

Transfer Object to pass back children of URI.

Field Type
parentURI String
children Map<String,RaptureFolderInfo>
deleted Map<String,RaptureFolderInfo>
indexMark String
remainder Long

getFolderInfo

HttpSysApi sysApi = new HttpSysApi(loginApi);
NodeEnum retVal = sysApi.getFolderInfo(raptureURI);
retVal = baseAPI.doSys_GetFolderInfo(raptureURI);

Entitlement: /repo/read

Determine whether the URI references an object, a folder, both or neither

Function Parameters

Parameter Type Description
raptureURI String

Return value

Type Description
NodeEnum
⚠️ **GitHub.com Fallback** ⚠️