lib/client/devops/docs/DatabaseApi.md

273 lines
7.1 KiB
Markdown
Raw Permalink Normal View History

2022-09-03 21:10:56 +00:00
# Devops.DatabaseApi
All URIs are relative to *http://devops.vernonkeenan.com:8080/v1*
Method | HTTP request | Description
------------- | ------------- | -------------
[**getDatabase**](DatabaseApi.md#getDatabase) | **GET** /databases/{databaseIdPath} | Get a single Database object
[**getDatabases**](DatabaseApi.md#getDatabases) | **GET** /databases | Get a list Databases
[**getDatabasesObservable**](DatabaseApi.md#getDatabasesObservable) | **GET** /databases/observable | Get Databases in an observable array
[**postDatabases**](DatabaseApi.md#postDatabases) | **POST** /databases | Create new Databases
[**putDatabases**](DatabaseApi.md#putDatabases) | **PUT** /databases | Update Databases
## getDatabase
> Database getDatabase(databaseIdPath)
Get a single Database object
Return a single Database object from datastore as a Singleton
### Example
```javascript
import Devops from 'devops';
let defaultClient = Devops.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
let apiInstance = new Devops.DatabaseApi();
let databaseIdPath = "databaseIdPath_example"; // String | Taxnexus Record Id of a Database
apiInstance.getDatabase(databaseIdPath, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**databaseIdPath** | **String**| Taxnexus Record Id of a Database |
### Return type
[**Database**](Database.md)
### Authorization
[ApiKeyAuth](../README.md#ApiKeyAuth)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
## getDatabases
> DatabaseResponse getDatabases(opts)
Get a list Databases
Return a list of Database records from the datastore
### Example
```javascript
import Devops from 'devops';
let defaultClient = Devops.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
let apiInstance = new Devops.DatabaseApi();
let opts = {
'databaseId': "databaseId_example", // String | Taxnexus Record Id of a Database
'companyId': "companyId_example", // String | Taxnexus Record Id of a Company
'limit': 789, // Number | How many objects to return at one time
'offset': 789 // Number | How many objects to skip? (default 0)
};
apiInstance.getDatabases(opts, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**databaseId** | **String**| Taxnexus Record Id of a Database | [optional]
**companyId** | **String**| Taxnexus Record Id of a Company | [optional]
**limit** | **Number**| How many objects to return at one time | [optional]
**offset** | **Number**| How many objects to skip? (default 0) | [optional]
### Return type
[**DatabaseResponse**](DatabaseResponse.md)
### Authorization
[ApiKeyAuth](../README.md#ApiKeyAuth)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
## getDatabasesObservable
> [Database] getDatabasesObservable()
Get Databases in an observable array
Returns a Database retrieval in a observable array
### Example
```javascript
import Devops from 'devops';
let defaultClient = Devops.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
let apiInstance = new Devops.DatabaseApi();
apiInstance.getDatabasesObservable((error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
```
### Parameters
This endpoint does not need any parameter.
### Return type
[**[Database]**](Database.md)
### Authorization
[ApiKeyAuth](../README.md#ApiKeyAuth)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
## postDatabases
> DatabaseResponse postDatabases(databaseRequest)
Create new Databases
Create Databases in Taxnexus
### Example
```javascript
import Devops from 'devops';
let defaultClient = Devops.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
let apiInstance = new Devops.DatabaseApi();
let databaseRequest = new Devops.DatabaseRequest(); // DatabaseRequest | An array of Database records
apiInstance.postDatabases(databaseRequest, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**databaseRequest** | [**DatabaseRequest**](DatabaseRequest.md)| An array of Database records |
### Return type
[**DatabaseResponse**](DatabaseResponse.md)
### Authorization
[ApiKeyAuth](../README.md#ApiKeyAuth)
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: application/json
## putDatabases
> DatabaseResponse putDatabases(databaseRequest)
Update Databases
Update Database in Taxnexus
### Example
```javascript
import Devops from 'devops';
let defaultClient = Devops.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
let apiInstance = new Devops.DatabaseApi();
let databaseRequest = new Devops.DatabaseRequest(); // DatabaseRequest | An array of Database records
apiInstance.putDatabases(databaseRequest, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**databaseRequest** | [**DatabaseRequest**](DatabaseRequest.md)| An array of Database records |
### Return type
[**DatabaseResponse**](DatabaseResponse.md)
### Authorization
[ApiKeyAuth](../README.md#ApiKeyAuth)
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: application/json