All URIs are relative to https://raw.githubusercontent.com/api
Method | HTTP request | Description |
---|---|---|
addStub | POST /stubs | Add a new stub to the store |
batchStubsDelete | POST /stubs/batchDelete | Deletes a pack by IDs |
deleteStubByID | DELETE /stubs/{uuid} | Deletes stub by ID |
findByID | GET /stubs/{uuid} | Get Stub by ID |
listStubs | GET /stubs | Getting a list of stubs |
listUnusedStubs | GET /stubs/unused | Getting a list of unused stubs |
listUsedStubs | GET /stubs/used | Getting a list of used stubs |
purgeStubs | DELETE /stubs | Remove all stubs |
searchStubs | POST /stubs/search | Stub storage search |
AddStub200Response addStub(addStubRequest)
Add a new stub to the store
Add a new stub to the store
import GripmockSdk from '@bavix/gripmock-sdk';
let apiInstance = new GripmockSdk.StubsApi();
let addStubRequest = new GripmockSdk.AddStubRequest(); // AddStubRequest | Create a new pet in the store
apiInstance.addStub(addStubRequest).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
addStubRequest | AddStubRequest | Create a new pet in the store |
No authorization required
- Content-Type: application/json
- Accept: application/json
batchStubsDelete(requestBody)
Deletes a pack by IDs
Takes IDs as input and deletes them
import GripmockSdk from '@bavix/gripmock-sdk';
let apiInstance = new GripmockSdk.StubsApi();
let requestBody = ["51c50050-ec27-4dae-a583-a32ca71a1dd5"]; // [String] | Create a new pet in the store
apiInstance.batchStubsDelete(requestBody).then(() => {
console.log('API called successfully.');
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
requestBody | [String] | Create a new pet in the store |
null (empty response body)
No authorization required
- Content-Type: application/json
- Accept: Not defined
deleteStubByID(uuid)
Deletes stub by ID
The method removes the stub by ID
import GripmockSdk from '@bavix/gripmock-sdk';
let apiInstance = new GripmockSdk.StubsApi();
let uuid = "uuid_example"; // String | ID of stub
apiInstance.deleteStubByID(uuid).then(() => {
console.log('API called successfully.');
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
uuid | String | ID of stub |
null (empty response body)
No authorization required
- Content-Type: Not defined
- Accept: Not defined
Stub findByID(uuid)
Get Stub by ID
Searches for Stub by ID
import GripmockSdk from '@bavix/gripmock-sdk';
let apiInstance = new GripmockSdk.StubsApi();
let uuid = "uuid_example"; // String | ID of stub
apiInstance.findByID(uuid).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
uuid | String | ID of stub |
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Stub] listStubs()
Getting a list of stubs
The list of stubs is required to view all added stubs
import GripmockSdk from '@bavix/gripmock-sdk';
let apiInstance = new GripmockSdk.StubsApi();
apiInstance.listStubs().then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
This endpoint does not need any parameter.
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Stub] listUnusedStubs()
Getting a list of unused stubs
The list is needed to quickly find unused stubs
import GripmockSdk from '@bavix/gripmock-sdk';
let apiInstance = new GripmockSdk.StubsApi();
apiInstance.listUnusedStubs().then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
This endpoint does not need any parameter.
No authorization required
- Content-Type: Not defined
- Accept: application/json
[Stub] listUsedStubs()
Getting a list of used stubs
The list is needed to quickly find used stubs
import GripmockSdk from '@bavix/gripmock-sdk';
let apiInstance = new GripmockSdk.StubsApi();
apiInstance.listUsedStubs().then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
This endpoint does not need any parameter.
No authorization required
- Content-Type: Not defined
- Accept: application/json
purgeStubs()
Remove all stubs
Completely clears the stub storage
import GripmockSdk from '@bavix/gripmock-sdk';
let apiInstance = new GripmockSdk.StubsApi();
apiInstance.purgeStubs().then(() => {
console.log('API called successfully.');
}, (error) => {
console.error(error);
});
This endpoint does not need any parameter.
null (empty response body)
No authorization required
- Content-Type: Not defined
- Accept: Not defined
SearchResponse searchStubs(searchRequest)
Stub storage search
Performs a search for a stub by the given conditions
import GripmockSdk from '@bavix/gripmock-sdk';
let apiInstance = new GripmockSdk.StubsApi();
let searchRequest = new GripmockSdk.SearchRequest(); // SearchRequest | Description of filtering
apiInstance.searchStubs(searchRequest).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
searchRequest | SearchRequest | Description of filtering |
No authorization required
- Content-Type: application/json
- Accept: application/json