The Client Id is an identifier of a SD application (main SD object). When a request, in any event, is done to the server, both, Client Id and client secret information are used to determine the SD application which is trying to connect to GeneXus Access Manager and if it is authorized to do it. See Secure Native Mobile applications architecture for more information.
For an application to be connected to GAM, it needs to be registered previously in GAM database, this process is executed inside Genexus IDE: see GAM Applications Registration process.
The GAM Application Registration process assigns the Client Secret for an application and updates the GAM database. It is done during F5 process and can be executed also from the menu: Applications Registration option.
As stated, the Client Id is used as an identifier of the application (it can be public) and the Client Secret is information that must not be revealed.
The Client Id and Client Secret information are kept in GAM database and in Genexus IDE as well. Inside GeneXus, it is used to build up metadata files so that the applications can be run using the KBN in prototyping time.
That information is also included in the binary files (apk, ipa), with the same purpose.
Both properties are stored for each object-environment. That is, for the same object in the KB, the value of Client Id and Client Secret can vary depending on the active environment.
But take into consideration that the Client Secret is generated by GAM only when the IDE has no value stored for that property. See Security Client Secret property for more information.
If an application already exists in GAM with the same Client Id, GAM returns the Client Secret existent in the database. So, if you create a new environment pointing to the same GAM DB; the applications won't reset their Client Secret values because they already exist in the DB with their Client Id.
When using GeneXus Server take into consideration that these properties are not exported and are not included in the Commit/Update.
Security Client Id property
Security Client Secret property
The Security Client Secret property isn't available anymore as of GeneXus 15.