Setting up API to select / insert / mate a part that could have changing last character.

I have parts saved as Partnumber - Rev letter.SLDPRT.  example : 123456-A.SLDPRT

I am writing an API that has many call outs for the part, for example "Front Plane@123456-A".  The only problem is if this part gets a revision, then the new name of it will be 123456-B.SLDPRT and the API won't work.  Is there a "universal character" or a way around this so that the API doesn't have to be updated every time there is a revision for parts?  The first 6 numbers will always be the same, only the letter will change at some point possibly for the parts.

Thanks!

SolidworksApi macros