Question

How can I programmatically get the FME Registration Key or Machine Code?

  • 8 March 2017
  • 4 replies
  • 10 views

Userlevel 4
Badge +13

For my workflow, I need to expose this value in an attribute. What are my options?


4 replies

Badge +11

One of our customers identified that this is possible using FMEObjects and Python:

import fmeobjects
lm = fmeobjects.FMELicenseManager()
print lm.getLicenseProperty('MACHINE CODE')

One of our customers identified that this is possible using FMEObjects and Python:

import fmeobjects
lm = fmeobjects.FMELicenseManager()
print lm.getLicenseProperty('MACHINE CODE')

This seems to work on FME Desktop with a fixed license.   If using a floating license or on FME Server then "MACHINE CODE" is not defined. 

Any suggestions on how to do this when using a floating license and/or on Server?

Badge +11

This seems to work on FME Desktop with a fixed license.   If using a floating license or on FME Server then "MACHINE CODE" is not defined. 

Any suggestions on how to do this when using a floating license and/or on Server?

Hi @neilhellas​ , for FME Server you can use the authenticated REST API endpoint:

/fmerest/v3/licensing/machinekey

I'll share your question regarding the floating license with my colleagues and hopefully we can find an answer for you!

Badge +11

This seems to work on FME Desktop with a fixed license.   If using a floating license or on FME Server then "MACHINE CODE" is not defined. 

Any suggestions on how to do this when using a floating license and/or on Server?

For FME Desktop, you can use the following command—which could be used with the SystemCaller transformer—to retrieve the value:

<path_to>/fme.exe MACHINE_KEY

This command simply returns the machine key (e.g. 1-234-567-890).

Reply