The permid API does not return record matches for the Person datatype. The API fails in 2 different ways, depending on if the input data has a single row or multiple rows, as shown in the examples below. Calling the API with a .csv file, csv string, or dataframe all run into the same issue.
The example files both use the OpenPermID Python library (https://github.com/Refinitiv-API-Samples/Article.OpenPermID.Python.APIs) for simplicity. When using the permid API without a library, the same results are returned.
Example data is taken from https://github.com/Refinitiv-API-Samples/Example.OpenPermID.Python.Jupyter
Example 1:
Code:
from OpenPermID import OpenPermID import pandas as pd opid = OpenPermID() opid.set_access_token("ACCESS_TOKEN") opid.set_timeout(10000) person = pd.DataFrame(columns = ['LocalID', 'FirstName', 'MiddleName', 'PreferredName', 'LastName', 'CompanyPermID', 'CompanyName', 'NamePrefix', 'NameSuffix']) person = person.append(pd.Series(['1','Satya','','','Nadella','4295907168','','',''], index=person.columns),ignore_index=True) output,err = opid.match(person, dataType='Person') print(output)
Issue: A match is expected but no match is found
Expected output:
Input_First NameInput_Last NameInput_LocalIDInput_OrgNameInput_OrgOpenPermIDMatch First NameMatch Last NameMatch LevelMatch OpenPermIDMatch OrdinalMatch OrgNameMatch OrgOpenPermIDMatch ScoreOriginal Row NumberProcessingStatus 0SatyaNadella1NaNhttps://permid.org/1-4295907168SatyaNadellaExcellenthttps://permid.org/1-344132626121MICROSOFT CORPORATIONhttps://permid.org/1-42959071680.952OK
Actual output:
ProcessingStatus Match Level Original Row Number Input_LocalID Input_First Name Input_Last Name Input_OrgOpenPermID 0 OK No Match 2 1 Satya Nadella https://permid.org/1-4295907168
Example 2:
Code:
from OpenPermID import OpenPermID import pandas as pd opid = OpenPermID() opid.set_access_token("ACCESS_TOKEN") opid.set_timeout(10000) person = pd.DataFrame(columns = ['LocalID', 'FirstName', 'MiddleName', 'PreferredName', 'LastName', 'CompanyPermID', 'CompanyName', 'NamePrefix', 'NameSuffix']) person = person.append(pd.Series(['1','Satya','','','Nadella','','Microsoft Corp','',''], index=person.columns),ignore_index=True) person = person.append(pd.Series(['2','Satya','','','Nadella','4295907168','','',''], index=person.columns),ignore_index=True) output,err = opid.match(person, dataType='Person') print(output)
Issue: 2 Matches are expected but the server returns a timeout error
Expected output:
Input_First NameInput_Last NameInput_LocalIDInput_OrgNameInput_OrgOpenPermIDMatch First NameMatch Last NameMatch LevelMatch OpenPermIDMatch OrdinalMatch OrgNameMatch OrgOpenPermIDMatch ScoreOriginal Row NumberProcessingStatus 0SatyaNadella1Microsoft CorpNaNSatyaNadellaGoodhttps://permid.org/1-344132626121MICROSOFT CORPORATIONhttps://permid.org/1-42959071680.752OK 1SatyaNadella2NaNhttps://permid.org/1-4295907168SatyaNadellaExcellenthttps://permid.org/1-344132626121MICROSOFT CORPORATIONhttps://permid.org/1-42959071680.953OK
Result: There is no output as the server returns the following response text:
{"ignore":" ","errorCode":9,"errorCodeMessage":"Processing Timeout - timeout reached. Please try again later."}