Skip to content

Latest commit

 

History

History
215 lines (166 loc) · 7.33 KB

DocumentSharesApi.md

File metadata and controls

215 lines (166 loc) · 7.33 KB

DocumentSharesApi

All URIs are relative to http://localhost

Method HTTP request Description
addFolderShare POST /shares/folders/{indexKey} Add folder share
deleteShare DELETE /shares/{shareKey} Delete folder share
getUserShares GET /shares Get user shared folders

addFolderShare

AddFolderShareResponse addFolderShare(indexKey, addFolderShareRequest, siteId)

Add folder share

Creates a new folder share; ONLY available with FormKiQ Enterprise

Example

// Import classes:
import com.formkiq.client.invoker.ApiClient;
import com.formkiq.client.invoker.ApiException;
import com.formkiq.client.invoker.Configuration;
import com.formkiq.client.invoker.auth.*;
import com.formkiq.client.invoker.models.*;
import com.formkiq.client.api.DocumentSharesApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    // Configure AWS Signature V4 authorization
    defaultClient.setAWS4Configuration("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY", "REGION", "SERVICE")
    
    DocumentSharesApi apiInstance = new DocumentSharesApi(defaultClient);
    String indexKey = "indexKey_example"; // String | Index Key Identifier
    AddFolderShareRequest addFolderShareRequest = new AddFolderShareRequest(); // AddFolderShareRequest | 
    String siteId = "siteId_example"; // String | Site Identifier
    try {
      AddFolderShareResponse result = apiInstance.addFolderShare(indexKey, addFolderShareRequest, siteId);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling DocumentSharesApi#addFolderShare");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
indexKey String Index Key Identifier
addFolderShareRequest AddFolderShareRequest
siteId String Site Identifier [optional]

Return type

AddFolderShareResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
201 201 CREATED * Access-Control-Allow-Origin -
* Access-Control-Allow-Methods -
* Access-Control-Allow-Headers -
400 400 OK -

deleteShare

DeleteShareResponse deleteShare(shareKey)

Delete folder share

Delete a specific document share; ONLY available with FormKiQ Enterprise

Example

// Import classes:
import com.formkiq.client.invoker.ApiClient;
import com.formkiq.client.invoker.ApiException;
import com.formkiq.client.invoker.Configuration;
import com.formkiq.client.invoker.auth.*;
import com.formkiq.client.invoker.models.*;
import com.formkiq.client.api.DocumentSharesApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    // Configure AWS Signature V4 authorization
    defaultClient.setAWS4Configuration("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY", "REGION", "SERVICE")
    
    DocumentSharesApi apiInstance = new DocumentSharesApi(defaultClient);
    String shareKey = "shareKey_example"; // String | Share Identifier
    try {
      DeleteShareResponse result = apiInstance.deleteShare(shareKey);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling DocumentSharesApi#deleteShare");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
shareKey String Share Identifier

Return type

DeleteShareResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 200 OK * Access-Control-Allow-Origin -
* Access-Control-Allow-Methods -
* Access-Control-Allow-Headers -

getUserShares

GetUserSharesResponse getUserShares(group, limit, next)

Get user shared folders

Get a listing of user folder/document shares; ONLY available with FormKiQ Enterprise

Example

// Import classes:
import com.formkiq.client.invoker.ApiClient;
import com.formkiq.client.invoker.ApiException;
import com.formkiq.client.invoker.Configuration;
import com.formkiq.client.invoker.auth.*;
import com.formkiq.client.invoker.models.*;
import com.formkiq.client.api.DocumentSharesApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    // Configure AWS Signature V4 authorization
    defaultClient.setAWS4Configuration("YOUR_ACCESS_KEY", "YOUR_SECRET_KEY", "REGION", "SERVICE")
    
    DocumentSharesApi apiInstance = new DocumentSharesApi(defaultClient);
    String group = "group_example"; // String | Group Identifier
    String limit = "10"; // String | Limit Results
    String next = "next_example"; // String | Next page of results token
    try {
      GetUserSharesResponse result = apiInstance.getUserShares(group, limit, next);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling DocumentSharesApi#getUserShares");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
group String Group Identifier [optional]
limit String Limit Results [optional] [default to 10]
next String Next page of results token [optional]

Return type

GetUserSharesResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 200 OK * Access-Control-Allow-Origin -
* Access-Control-Allow-Methods -
* Access-Control-Allow-Headers -