Hi,
I have a series of API's that I want to automatically pull into SAS on a daily/weekly basis. The data is in Json format. Please can somebody offer advice on how I would go about doing this from a coding perspective? I've never needed to do this before and hence I'm not quite sure the steps involved. I am using SAS 9.4.
Many thanks
Chris
That's a very big question but as a start you could check out Proc HTTP to issue HTTP requests to bring the data into SAS then use the JSON libname engine to convert the JSON into SAS data sets. You'll find some documentation to get you started at these links:
Reading data with PROC HTTP and the JSON libname engine
How to test PROC HTTP and the JSON engine
The JSON LIBNAME Engine: Real-World Applications Using Open APIs
My advice would be to give this a try and post more specific questions if/when you hit a problem.
That's a very big question but as a start you could check out Proc HTTP to issue HTTP requests to bring the data into SAS then use the JSON libname engine to convert the JSON into SAS data sets. You'll find some documentation to get you started at these links:
Reading data with PROC HTTP and the JSON libname engine
How to test PROC HTTP and the JSON engine
The JSON LIBNAME Engine: Real-World Applications Using Open APIs
My advice would be to give this a try and post more specific questions if/when you hit a problem.
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.
Find more tutorials on the SAS Users YouTube channel.