@@ -46,10 +46,12 @@ function parameters() {
4646 this . language = null ;
4747 this . documentFile = null ;
4848 this . options = null ;
49+ this . profileId = null ;
4950
5051 // address similarity parameters
5152 this . address1 = null ;
5253 this . address2 = null ;
54+ this . parameters = null ;
5355
5456 // name matching parameters
5557 this . name1 = null ;
@@ -68,6 +70,7 @@ function parameters() {
6870 this . sourceScript = null ;
6971 this . targetScript = null ;
7072 this . targetScheme = null ;
73+ this . maximumResults = null ;
7174
7275 // transliteration parameters
7376 this . sourceLanguage = null ;
@@ -88,10 +91,15 @@ function parameters() {
8891 //URL parameters
8992 this . urlParameters = null ;
9093
94+ //record similarity
95+ this . fields = null ;
96+ this . records = null ;
97+ this . properties = null ;
98+
9199}
92100
93101/**
94- * Loads all non-null parameters into a new JSON that will be used as parameters for a Analytics API endpoint
102+ * Loads all non-null parameters into a new JSON that will be used as parameters for an Analytics API endpoint
95103 * Parameters that start with '_' are internal and not included in the endpoint request
96104 */
97105parameters . prototype . loadParams = function ( ) {
@@ -181,16 +189,16 @@ parameters.prototype.loadFile = function(filePath, loadedParameters, userKey, pr
181189 }
182190 headers [ "X-BabelStreetAPI-Key" ] = userKey ;
183191
184- if ( parameters . customHeaders != null ) {
185- parameters . customHeaders . forEach ( function ( element , index ) {
192+ if ( loadedParameters . customHeaders != null ) {
193+ loadedParameters . customHeaders . forEach ( function ( element , index ) {
186194 headers [ element [ 0 ] ] = element [ 1 ] ;
187195 } ) ;
188196 }
189197
190198 var urlPath = urlParts . path ;
191199
192- if ( parameters . urlParameters != null ) {
193- urlPath = `${ urlPath } ?${ querystring . stringify ( parameters . urlParameters ) } ` ;
200+ if ( loadedParameters . urlParameters != null ) {
201+ urlPath = `${ urlPath } ?${ querystring . stringify ( loadedParameters . urlParameters ) } ` ;
194202 }
195203
196204 var result = Buffer . from ( "" ) ;
0 commit comments