Passing a Node ID Datatype on OPC Method Call

I'm using Ignition to copy log file dumps from a Siemens controller. Ignition connects to the device via OPC UA, opens, reads, and copies the raw byte data to a server. This is all done through OPC Method calls and works properly. Below is a partial example of how I'm opening the file and reading data:

log.trace('Beginning Open Method for file %s'%(fileName))
payload['methodId'] = fileName + '.Open'#call open method
payload['inputList'] = [1]#pass the input parameter 1. This will give us a file handle id to use
resultsOpen = system.util.sendRequest(project, messageHandler, payload)#if the call was successful, the message handler will return an arraylist
log.debug('Open Output for %s is; %s' %(isolatedFileName, str(resultsOpen)))	#otherwise, it will return a -1
if resultsOpen == -1:
	raise OPCMethodOpenFailure#raise custom exception
	log.debug('Successful Open Method for file %s'%(isolatedFileName))
	fileHandle = int(resultsOpen[2][0])#get the file handle integer
fileSize = system.opc.readValue('M044 MC30L', fileName+'.Size').value #this gets the file size. Needed for the read method call
log.debug('File Size for %s is %s'%(isolatedFileName,str(fileSize)))
log.trace('Beginning Read Method for file %s'%(isolatedFileName))
payload['methodId'] = fileName + '.Read'
payload['inputList'] = [fileHandle,fileSize]#pass the file handle and file size gathered above
resultsRead = system.util.sendRequest(project, messageHandler, payload)
log.debug('Read Output for %s is; %s' %(isolatedFileName, str(resultsRead)))
if resultsRead == -1:#file failed to read
	raise OPCMethodReadFailure
elif len(resultsRead[2]) == 0:#file successfully read, but no byte data returned
	log.warn('Read succeeded on file %s, but no byte data returned.'%(isolatedFileName))
	log.debug('Successful Read Method for file %s'%(isolatedFileName))

Once the file is read, I need to invoke the 'delete' method to remove the file sitting on the OPC Server to clear space off the disk. For the above two method calls, I simply have to pass integers as input parameters when calling the method. However, for the delete call, the server requires a 'NodeId' data type as a parameter. Below is an example of the method call in UAExpert:

The NodeId type consists of 3 values; the NamespaceIndex, the IdentifierType, and the Identifier. How do I go about passing this non-intuitive datatype from an Ignition script as an input parameter? Thanks.

Unfortunately I don't think this is possible right now. Ignition doesn't have corresponding datatypes for many of the OPC UA built-in types, and even if you were running your script in the gateway scope you still wouldn't have access to the types provided by the OPC UA module because they are loaded in a module ClassLoader that sits below the gateway scope.

Dang, I was worried this would be the case. Has there been a workaround others have found? Is there a way to somehow pass the parameters as an array which the server would understand? I unfortunately do not have access to Wireshark or anything that would let me sniff the format of the data UA Expert passes along. Could I pull in a java or python OPC library that would have the NodeID definition type defined? Sorry if these seem impractical. I've been learning OPC terminology and how to invoke methods as I've built this project, so still fresh for me.

No, this is what I meant when I was talking about ClassLoaders and types provided by the OPC UA module... they just aren't accessible from scripting.

I don't really see a workaround for this, I think this has to be something we add support for explicitly in a future version.

Bumping this thread again. We recently upgraded Ignition versions and have needed to potentially reapproach this issue. I discovered this blog post about 8.1.27

Ignition 8.1.27: OPC UA Writes, OIDC Request Options, Designer & Gateway Configuration Properties | Inductive Automation

Does this update allow for complex data type structures to be passed? Will the driver not handle this? Thanks.

Complex types (structures) are different than what this thread was originally about, which is that some of the OPC UA built-in types aren't supported, and that hasn't and won't change until Ignition 8.3.

I figured doing some additional reading. It had been awhile since I approached the project and the blog post caught my eye. On some additional reading I can see it is not related. Thanks for confirming.