Skip to content

Latest commit

 

History

History
759 lines (562 loc) · 24 KB

File metadata and controls

759 lines (562 loc) · 24 KB

GuidsApi

All URIs are relative to https://backend.id4i.de

Method HTTP request Description
addGuidAlias POST /api/v1/id4ns/{id4n}/alias/{aliasType} Add alias for GUID or Collection
createGuid POST /api/v1/guids Create GUID(s)
deleteProperties DELETE /api/v1/id4ns/{id4n}/properties Delete ID4n properties
getCollections GET /api/v1/id4ns/{id4n}/collections Retrieve collections of an ID
getGuid GET /api/v1/guids/{id4n} Retrieve GUID information
getGuidAliases GET /api/v1/id4ns/{id4n}/alias Get all aliases for the given GUID or Collection.
getGuidsWithoutCollection GET /api/v1/guids/withoutCollection Retrieve GUIDs not in any collection
getId4n GET /api/v1/id4ns/{id4n} Retrieve ID4n information
getProperties GET /api/v1/id4ns/{id4n}/properties Retrieve ID4n properties
importGS1Codes POST /api/v1/import/gs1 Import GS1/MAPP codes
patchProperties PATCH /api/v1/id4ns/{id4n}/properties Patch ID4n properties
removeGuidAlias DELETE /api/v1/id4ns/{id4n}/alias/{aliasType} Remove aliases from GUID or Collection
updateGuid PATCH /api/v1/guids/{id4n} Change GUID information.

addGuidAlias

addGuidAlias(id4n, aliasType, alias)

Add alias for GUID or Collection

Adds or replaces aliases for single ID4ns (alias type item and mapp) or groups of ID4ns (alias types gtin, ean and article)

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The GUID or Collection to operate on
String aliasType = "aliasType_example"; // String | Alias type, see the corresponding API model
GuidAlias alias = new GuidAlias(); // GuidAlias | The alias to add or update
try {
    apiInstance.addGuidAlias(id4n, aliasType, alias);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#addGuidAlias");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The GUID or Collection to operate on
aliasType String Alias type, see the corresponding API model [enum: gtin, article, mapp, item, rfid, tracking, eclass, unspsc, product, material, reference]
alias GuidAlias The alias to add or update

Return type

null (empty response body)

Authorization

Authorization

HTTP request headers

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

createGuid

ListOfId4ns createGuid(createGUIDInfo)

Create GUID(s)

Creating one or more GUIDs with a specified length.

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
CreateGuidRequest createGUIDInfo = new CreateGuidRequest(); // CreateGuidRequest | GUID creation model
try {
    ListOfId4ns result = apiInstance.createGuid(createGUIDInfo);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#createGuid");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
createGUIDInfo CreateGuidRequest GUID creation model

Return type

ListOfId4ns

Authorization

Authorization

HTTP request headers

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

deleteProperties

deleteProperties(id4n, organizationId, properties)

Delete ID4n properties

Partial deletion of id4n properties. If the property does not exist, it will be ignored.

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The id4n
String organizationId = "organizationId_example"; // String | The organization namespace to work on while deleting the properties.
List<String> properties = Arrays.asList(new List<String>()); // List<String> | A set of property keys to delete.
try {
    apiInstance.deleteProperties(id4n, organizationId, properties);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#deleteProperties");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The id4n
organizationId String The organization namespace to work on while deleting the properties.
properties List<String> A set of property keys to delete.

Return type

null (empty response body)

Authorization

Authorization

HTTP request headers

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

getCollections

PaginatedResponseOfGuidCollection getCollections(id4n, organizationId, offset, limit)

Retrieve collections of an ID

Retrieving all owned or holding collections the specified id4n is assigned to.

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The ID which the collections should contain
String organizationId = "organizationId_example"; // String | The organization holding the collections.
Integer offset = 56; // Integer | Start with the n-th element
Integer limit = 56; // Integer | The maximum count of returned elements
try {
    PaginatedResponseOfGuidCollection result = apiInstance.getCollections(id4n, organizationId, offset, limit);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#getCollections");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The ID which the collections should contain
organizationId String The organization holding the collections. [optional]
offset Integer Start with the n-th element [optional]
limit Integer The maximum count of returned elements [optional]

Return type

PaginatedResponseOfGuidCollection

Authorization

Authorization

HTTP request headers

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

getGuid

Guid getGuid(id4n, organizationId)

Retrieve GUID information

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The GUID number
String organizationId = "organizationId_example"; // String | The organization namespace to resolve.
try {
    Guid result = apiInstance.getGuid(id4n, organizationId);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#getGuid");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The GUID number
organizationId String The organization namespace to resolve. [optional]

Return type

Guid

Authorization

Authorization

HTTP request headers

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

getGuidAliases

Map<String, String> getGuidAliases(id4n)

Get all aliases for the given GUID or Collection.

Looks up the alias for each alias type (group and single) and returns a map of all aliases found.

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The GUID or Collection to operate on
try {
    Map<String, String> result = apiInstance.getGuidAliases(id4n);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#getGuidAliases");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The GUID or Collection to operate on

Return type

Map<String, String>

Authorization

Authorization

HTTP request headers

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

getGuidsWithoutCollection

PaginatedResponseOfGuid getGuidsWithoutCollection(organizationId, offset, limit)

Retrieve GUIDs not in any collection

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String organizationId = "organizationId_example"; // String | The namespace of the organization to search GUIDs for
Integer offset = 56; // Integer | Start with the n-th element
Integer limit = 56; // Integer | The maximum count of returned elements
try {
    PaginatedResponseOfGuid result = apiInstance.getGuidsWithoutCollection(organizationId, offset, limit);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#getGuidsWithoutCollection");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
organizationId String The namespace of the organization to search GUIDs for
offset Integer Start with the n-th element [optional]
limit Integer The maximum count of returned elements [optional]

Return type

PaginatedResponseOfGuid

Authorization

Authorization

HTTP request headers

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

getId4n

Id4nPresentation getId4n(id4n, organizationId)

Retrieve ID4n information

Retrieving basic information about an ID like the type and the creation time.

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The ID to resolve to
String organizationId = "organizationId_example"; // String | The organization namespace to resolve.
try {
    Id4nPresentation result = apiInstance.getId4n(id4n, organizationId);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#getId4n");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The ID to resolve to
organizationId String The organization namespace to resolve. [optional]

Return type

Id4nPresentation

Authorization

Authorization

HTTP request headers

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

getProperties

Map<String, String> getProperties(id4n, organizationId)

Retrieve ID4n properties

List all properties of an id4n.

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The id4n
String organizationId = "organizationId_example"; // String | The organization namespace.
try {
    Map<String, String> result = apiInstance.getProperties(id4n, organizationId);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#getProperties");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The id4n
organizationId String The organization namespace. [optional]

Return type

Map<String, String>

Authorization

Authorization

HTTP request headers

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

importGS1Codes

importGS1Codes(importGS1CodesRequest)

Import GS1/MAPP codes

Importing GS1/MAPP codes that contain unique components.

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
ImportGS1CodesRequest importGS1CodesRequest = new ImportGS1CodesRequest(); // ImportGS1CodesRequest | The information how the MAPP codes should be imported and the list of MAPP codes
try {
    apiInstance.importGS1Codes(importGS1CodesRequest);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#importGS1Codes");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
importGS1CodesRequest ImportGS1CodesRequest The information how the MAPP codes should be imported and the list of MAPP codes

Return type

null (empty response body)

Authorization

Authorization

HTTP request headers

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

patchProperties

patchProperties(id4n, organizationId, properties)

Patch ID4n properties

Partial updating of id4n properties. If a property contains a null value the property will be deleted other values will be saved and overwritten if they already exist.

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The id4n
String organizationId = "organizationId_example"; // String | The organization namespace to work on while patching the properties.
Object properties = null; // Object | The properties to update.
try {
    apiInstance.patchProperties(id4n, organizationId, properties);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#patchProperties");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The id4n
organizationId String The organization namespace to work on while patching the properties.
properties Object The properties to update.

Return type

null (empty response body)

Authorization

Authorization

HTTP request headers

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

removeGuidAlias

removeGuidAlias(id4n, aliasType)

Remove aliases from GUID or Collection

Remove the alias of the given type

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The GUID or Collection to operate on
String aliasType = "aliasType_example"; // String | Alias type, see the corresponding API model
try {
    apiInstance.removeGuidAlias(id4n, aliasType);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#removeGuidAlias");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The GUID or Collection to operate on
aliasType String Alias type, see the corresponding API model [enum: gtin, article, mapp, item, rfid, tracking, eclass, unspsc, product, material, reference]

Return type

null (empty response body)

Authorization

Authorization

HTTP request headers

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

updateGuid

Object updateGuid(id4n, request)

Change GUID information.

Allows ownership transfer.

Example

// Import classes:
//import de.id4i.ApiClient;
//import de.id4i.ApiException;
//import de.id4i.Configuration;
//import de.id4i.auth.*;
//import de.id4i.api.GuidsApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: Authorization
ApiKeyAuth Authorization = (ApiKeyAuth) defaultClient.getAuthentication("Authorization");
Authorization.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.setApiKeyPrefix("Token");

GuidsApi apiInstance = new GuidsApi();
String id4n = "id4n_example"; // String | The GUID number
Guid request = new Guid(); // Guid | request
try {
    Object result = apiInstance.updateGuid(id4n, request);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling GuidsApi#updateGuid");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id4n String The GUID number
request Guid request

Return type

Object

Authorization

Authorization

HTTP request headers

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