Authentication
3 min
generating a session token access to the kyc data api will be granted when user credentials are issued the credentials are required in order to obtain a session token a session token is valid for 8 hours, and a user can have multiple active session tokens when you subscribe to the data zoo kyc data api you'll receive a username and password for every child account required; often this may be only one set of credentials however depending on the number of configuration profiles, reseller accounts etc then multiple credentials may be issued { "name" " authentication sandbox", "method" "post", "url" "https //idu test datazoo com/api/v2/auth/sign in", "description" "", "tab" "examples", "examples" { "languages" \[ { "id" "g2qncshal0cgdvmerxy96", "language" "curl", "code" "curl location 'https //idu test datazoo com/api/v2/auth/sign in' \\\\\n header 'accept application/json' \\\\\n header 'content type application/json' \\\\\n data '{\\"data\\" {\\"username\\" \\"string\\",\\"password\\" \\"string\\"}}'", "customlabel" "" } ], "selectedlanguageid" "g2qncshal0cgdvmerxy96" }, "results" { "languages" \[ { "id" "cgwiic4i8aqbeol4mchqx", "language" "200", "customlabel" "", "code" "{\n \\"message\\" \\"logged in!\\",\n \\"sessiontoken\\" \\"bearer eyjhbgcioijiuzuxmiisinr5cci6ikpxvcj9 eyjpc3mioij0zxn0iiwiawf0ijoxnza4nzgymdcylcjpcgeioiiznc4xnteumte3lji0osisinvpzci6mtusim9pzci6mswibglkijozmty5odc5lcjlehaioje3mdg4mta4nzisimf1zci6imh0dhbzoi8vawr1lmrhdgf6b28uy29tiiwizhnwijpbiioixx0 h1h0dycaxptrxcvt mcipp4ya8mfmac67gdirlpridjkfsrcqtocdbtkjemdgvhtg2hw vmeth9pgrqc 2hjq\\"\n}" }, { "id" "muddfcgyuspqd0tz8t7fg", "language" "401", "customlabel" "", "code" "{\n \\"error\\" \\"incorrect password detected\\"\n}\nor\n{\n \\"error\\" \\"incorrect log in credentials detected\\"\n}" } ], "selectedlanguageid" "cgwiic4i8aqbeol4mchqx" }, "request" { "pathparameters" \[], "queryparameters" \[], "headerparameters" \[], "bodydataparameters" \[ { "name" "data", "kind" "required", "type" "object", "description" "", "value" "rumana khandoker test", "" "", "children" \[ { "name" "username", "kind" "required", "type" "string", "description" "supplied username" }, { "name" "password", "kind" "required", "type" "string", "description" "supplied password" } ], "schema" \[ { "name" "username", "kind" "required", "type" "string", "description" "supplied username" }, { "name" "password", "kind" "required", "type" "string", "description" "supplied password" } ] } ], "formdataparameters" \[] }, "currentnewparameter" { "label" "body parameter", "value" "bodydataparameters" }, "hastryitout" false, "response" \[ { "name" "message", "kind" "optional", "type" "string", "description" "" }, { "name" "sessiontoken", "kind" "optional", "type" "string", "description" "", "children" \[] } ] } { "name" " authentication production", "method" "post", "url" "https //idu datazoo com/api/v2/auth/sign in", "description" "", "tab" "examples", "examples" { "languages" \[ { "id" "g2qncshal0cgdvmerxy96", "language" "curl", "code" "curl location 'https //idu datazoo com/api/v2/auth/sign in' \\\\\n header 'accept application/json' \\\\\n header 'content type application/json' \\\\\n data '{\\"data\\" {\\"username\\" \\"string\\",\\"password\\" \\"string\\"}}'", "customlabel" "" } ], "selectedlanguageid" "g2qncshal0cgdvmerxy96" }, "results" { "languages" \[ { "id" "cgwiic4i8aqbeol4mchqx", "language" "200", "customlabel" "", "code" "{\n \\"message\\" \\"logged in!\\",\n \\"sessiontoken\\" \\"bearer eyjhbgcioijiuzuxmiisinr5cci6ikpxvcj9 eyjpc3mioij0zxn0iiwiawf0ijoxnza4nzgymdcylcjpcgeioiiznc4xnteumte3lji0osisinvpzci6mtusim9pzci6mswibglkijozmty5odc5lcjlehaioje3mdg4mta4nzisimf1zci6imh0dhbzoi8vawr1lmrhdgf6b28uy29tiiwizhnwijpbiioixx0 h1h0dycaxptrxcvt mcipp4ya8mfmac67gdirlpridjkfsrcqtocdbtkjemdgvhtg2hw vmeth9pgrqc 2hjq\\"\n}" }, { "id" "muddfcgyuspqd0tz8t7fg", "language" "401", "customlabel" "", "code" "{\n \\"error\\" \\"incorrect password detected\\"\n}\nor\n{\n \\"error\\" \\"incorrect log in credentials detected\\"\n}" } ], "selectedlanguageid" "cgwiic4i8aqbeol4mchqx" }, "request" { "pathparameters" \[], "queryparameters" \[], "headerparameters" \[], "bodydataparameters" \[ { "name" "data", "kind" "required", "type" "object", "description" "", "value" "rumana khandoker test", "" "", "children" \[ { "name" "username", "kind" "required", "type" "string", "description" "supplied username" }, { "name" "password", "kind" "required", "type" "string", "description" "supplied password" } ], "schema" \[ { "name" "username", "kind" "required", "type" "string", "description" "supplied username" }, { "name" "password", "kind" "required", "type" "string", "description" "supplied password" } ] } ], "formdataparameters" \[] }, "currentnewparameter" { "label" "body parameter", "value" "bodydataparameters" }, "hastryitout" false, "response" \[ { "name" "message", "kind" "optional", "type" "string", "description" "" }, { "name" "sessiontoken", "kind" "optional", "type" "string", "description" "", "children" \[] } ] }