1

A little confused with the application key as mentioned in Cumulocity website,

"Applications are identified by a so-called application key, which is included into requests that an application makes. The application key enables Cumulocity to associate a request with a particular application and to distinguish the request from other requests coming from devices."

Can the application key be chosen freely by app developer or needs to be assigned by the Cumulocity? If former, what if two developers using the same application key for different apps? Or the scope of the key is per tenant?

Abdulla Nilam
  • 36,589
  • 17
  • 64
  • 85
Bill Zhou
  • 25
  • 3

2 Answers2

1

As that quote explains, it allows Cumulocity "to distinguish the request from other requests coming from devices". For example, if an alarm status is changed to CLEARED from the alarm list in Device Management app, change history would mark that particular change with device management app key:

enter image description here

So basically as long as you provide a valid app key that your user account has access to, it is for logging/auditing purposes.

mostruash
  • 4,169
  • 1
  • 23
  • 40
1

"Can the application key be chosen freely by app developer or needs to be >assigned by the Cumulocity?"

You can choose it freely. In the Adminstration Application, under "Own Applications", you can create an application with your API Key. Please use a long one that would not conflict with others (e.g. com_yourcompany_xyz).

If former, what if two developers using the same application key for different apps? Or the scope of the key is per tenant?

The scope by default is per tenant. However, for marketplace applications, the same API key is used for all tenant. So its better to ensure it is globally unique.

Stefan Vaillant
  • 511
  • 3
  • 6