SlideShare ist ein Scribd-Unternehmen logo
1 von 10
REST API File Upload using
SSIS (Multi Part POST)
Reach for the Clouds, Inc.
Next Generation SSIS Tasks and Connectors Series
AUTHOR:
NAYAN PATEL | SR. ETL SSIS ARCHITECT
N PAT E L @ R F TC LO U D S . C O M
Content
• Introduction
• How to do REST API File Upload using SSIS
• Understanding Multipart Upload / File Upload
• Conclusion
• Keywords
Introduction
• In this post you will learn how to use the SSIS REST APITask to perform REST
API File Upload (i.e. RESTful file upload) to web server.Typically to access
REST API you may have to use programming language but in this post we will
use visual drag and drop approach.
• File upload using HTTP/HTTPS protocol sometimes also known as
multipart/form-data POST. Many REST APIs support for file upload using
HTTP methods such as POST or PUT.
• Real-world scenarios:
• Uploading Image/media toTwitter or Facebook
• Import Marketo Lead files using REST API
How to do REST API File Upload using SSIS
1.DOWNLOAD AND INSTALL SSIS REST API TASK
2.FROM TOOLBOX OF THE SSIS DESIGNER DRAG ZS SSIS REST API TASK
3.DOUBLE CLICK REST API TASK TO CONFIGURE IT
4.SPECIFY URL WHERE YOU WISH TO POST FILE/OTHER DATA
EXAMPLE : HTTP://MYSERVER/API/V1/UPLOADDATA
5.SELECT HTTP REQUEST METHOD AS POST
( MAKE SURE YOUR API DOCUMENTATION FOR THIS. SOMETIMES ITS PUT R ATHE R POST)
6.CHECK FILE UPLOAD OPTION NEXT TO BODY TEXT BOX
!!!!THIS IS THE MOST IMPORTANT SO DON’T FORGET !!!!
How to do REST API File Upload using SSIS
7.NOW CLICK EDIT BUTTON NEXT TO BODY TEXT BOX. YOU MAY SPECIFY F ILES / FIELDS
YOU WISH TO SUBMIT ALONG WITH YOUR REQUEST IN THE FOLLOWING FORM AT. ITS
KEY/VALUE PAIR SEPARATED BY NEW LINE. EACH KEY/VALUE PAIR HAS TO BE
SEPARATED WITH EQUAL SIGN (=).NOTE: ANY VALUE STARTING WITH AT SYMBOL (@) IS
TREATED AS FILE PATH. IF YOU DON’T WANT THAT BEHAVIOR THEN USE S LASH ALSO
KNOWN AS ESCAPE SEQUENCE (E.G.
SOMEFIELD3STARTSWITHAT=@MYTWITTERHANDLE). YOU CAN DO SAME THING TO ADD
NEW LINE CHARACTER IN YOUR VALUE. USE RN FOR NEW LINE. USE T FOR TABALSO
NOTICE NAME OF FIELD CAN BE ANYTHING UNLESS YOUR API EXPECTS IN CERTAIN WAY.
EXAMPLE: TWITTER IMAGE UPLOAD API MAY EXPECT YOUR IMAGE FILE AS MEDIA FIELD
IN THAT CASE YOU WOULD WRITE …. MEDIA=@C:DATASOMEIMAGE.PNG …. RATHER
THAN FILE1=@C:DATASOMEIMAGE.PNG
File1=@c:datasomedata.txt
File2=@c:datasomeimage.png
Somefield1=abcdef
Somefield2=123456
Extrafield3WithNewLine=This is line1rnThis is line2 with tabt and more t tab
Somefield3StartsWithAt=@MyTwitterHandle
CLICK OK TO SAVE ABOVE
How to do REST API
File Upload using SSIS
8. NOW CLICK TEST BUTTON
ON UI TO MAKE SURE
EVERYTHING IS LOOKING
GOOD.
UPLOADING FILES USING REST API IN SSIS ( REST API FILE UPLOAD
USING MULTIPART/FORM -DATA POST)
Understanding Multipart Upload / File Upload
NOW LETS TAKE A LOOK HOW DOES IT LOOK LIKE IN FIDDLER WHEN ACTUAL
MULTIPART POST REQUEST IS MADE FOR REST API FILE UPLOAD. NOTICE
EACH FIELD INCLUDED IN OUT HTTP POST REQUEST IS SEPARATED BY SOM E
RANDOM BOUNDARY. THIS BOUNDARY IS AUTOMATICALLY GENERATED BY
REST API TASK. IF YOU POST IMAGE THEN YOU WILL SEE BINARY DATA R ATHER
THAN TEXT FOR FILE CONTENT.
SEE IMAGE ON NEXT SLIDE
HTTTP MULTIPART POST – FILE UPLOAD EXAMPLE – CHECK FIDDLER REQUEST
Conclusion
IF YOU HAVE NEED TO PERFORM REST API FILE UPLOAD / REST API
INTEGRATION WITHOUT LEARNING COMPLEX APIS AND PROGRAMMING
LANGUAGES (E.G. PYTHON, JAVA, C#) THEN SSIS REST API TASK PROVIDES
PERFECT WAY TO DO REST API INTEGRATION WITH YOUR EXISTING SYSTEM .
YOU CAN UNCOVER ENDLESS POSSIBILITIES WITH DRAG AND DROP APPROAC H
WHICH IS NOT ONLY SIMPLE TO USE BUT INCLUDES MANY OPTIONS FOR
COMPLEX SCENARIOS TOO.
Keywords
HOW TO PERFORM REST API FILE UPLOAD | HOW TO DO RESTFUL FILE UPLOAD
IN C# | HOW TO DO MULTIPART FILE UPLOAD WITHOUT CURL | HOW TO
UPLOAD MULTIPLE FILES USING HTTP MULTI PART FORMS | REST CLIENT
UPLOAD FILE | C# REST API UPLOAD FILE | REST API UPLOAD IMAGE | REST API
UPLOAD FILE

Weitere ähnliche Inhalte

Kürzlich hochgeladen

Jax, FL Admin Community Group 05.14.2024 Combined Deck
Jax, FL Admin Community Group 05.14.2024 Combined DeckJax, FL Admin Community Group 05.14.2024 Combined Deck
Jax, FL Admin Community Group 05.14.2024 Combined Deck
Marc Lester
 

Kürzlich hochgeladen (20)

Weeding your micro service landscape.pdf
Weeding your micro service landscape.pdfWeeding your micro service landscape.pdf
Weeding your micro service landscape.pdf
 
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAOpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
 
Transformer Neural Network Use Cases with Links
Transformer Neural Network Use Cases with LinksTransformer Neural Network Use Cases with Links
Transformer Neural Network Use Cases with Links
 
The Strategic Impact of Buying vs Building in Test Automation
The Strategic Impact of Buying vs Building in Test AutomationThe Strategic Impact of Buying vs Building in Test Automation
The Strategic Impact of Buying vs Building in Test Automation
 
OpenChain @ LF Japan Executive Briefing - May 2024
OpenChain @ LF Japan Executive Briefing - May 2024OpenChain @ LF Japan Executive Briefing - May 2024
OpenChain @ LF Japan Executive Briefing - May 2024
 
^Clinic ^%[+27788225528*Abortion Pills For Sale In birch acres
^Clinic ^%[+27788225528*Abortion Pills For Sale In birch acres^Clinic ^%[+27788225528*Abortion Pills For Sale In birch acres
^Clinic ^%[+27788225528*Abortion Pills For Sale In birch acres
 
Community is Just as Important as Code by Andrea Goulet
Community is Just as Important as Code by Andrea GouletCommunity is Just as Important as Code by Andrea Goulet
Community is Just as Important as Code by Andrea Goulet
 
architecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdfarchitecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdf
 
^Clinic ^%[+27788225528*Abortion Pills For Sale In harare
^Clinic ^%[+27788225528*Abortion Pills For Sale In harare^Clinic ^%[+27788225528*Abortion Pills For Sale In harare
^Clinic ^%[+27788225528*Abortion Pills For Sale In harare
 
Effective Strategies for Wix's Scaling challenges - GeeCon
Effective Strategies for Wix's Scaling challenges - GeeConEffective Strategies for Wix's Scaling challenges - GeeCon
Effective Strategies for Wix's Scaling challenges - GeeCon
 
Food Delivery Business App Development Guide 2024
Food Delivery Business App Development Guide 2024Food Delivery Business App Development Guide 2024
Food Delivery Business App Development Guide 2024
 
Jax, FL Admin Community Group 05.14.2024 Combined Deck
Jax, FL Admin Community Group 05.14.2024 Combined DeckJax, FL Admin Community Group 05.14.2024 Combined Deck
Jax, FL Admin Community Group 05.14.2024 Combined Deck
 
Alluxio Monthly Webinar | Simplify Data Access for AI in Multi-Cloud
Alluxio Monthly Webinar | Simplify Data Access for AI in Multi-CloudAlluxio Monthly Webinar | Simplify Data Access for AI in Multi-Cloud
Alluxio Monthly Webinar | Simplify Data Access for AI in Multi-Cloud
 
Evolving Data Governance for the Real-time Streaming and AI Era
Evolving Data Governance for the Real-time Streaming and AI EraEvolving Data Governance for the Real-time Streaming and AI Era
Evolving Data Governance for the Real-time Streaming and AI Era
 
How to install and activate eGrabber JobGrabber
How to install and activate eGrabber JobGrabberHow to install and activate eGrabber JobGrabber
How to install and activate eGrabber JobGrabber
 
Abortion Clinic In Springs ](+27832195400*)[ 🏥 Safe Abortion Pills in Springs...
Abortion Clinic In Springs ](+27832195400*)[ 🏥 Safe Abortion Pills in Springs...Abortion Clinic In Springs ](+27832195400*)[ 🏥 Safe Abortion Pills in Springs...
Abortion Clinic In Springs ](+27832195400*)[ 🏥 Safe Abortion Pills in Springs...
 
Abortion Clinic Pretoria ](+27832195400*)[ Abortion Clinic Near Me ● Abortion...
Abortion Clinic Pretoria ](+27832195400*)[ Abortion Clinic Near Me ● Abortion...Abortion Clinic Pretoria ](+27832195400*)[ Abortion Clinic Near Me ● Abortion...
Abortion Clinic Pretoria ](+27832195400*)[ Abortion Clinic Near Me ● Abortion...
 
Lessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdfLessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdf
 
Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024
 
Software Engineering - Introduction + Process Models + Requirements Engineering
Software Engineering - Introduction + Process Models + Requirements EngineeringSoftware Engineering - Introduction + Process Models + Requirements Engineering
Software Engineering - Introduction + Process Models + Requirements Engineering
 

Empfohlen

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 

Empfohlen (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

Uploading Files using REST API in SSIS

  • 1. REST API File Upload using SSIS (Multi Part POST) Reach for the Clouds, Inc. Next Generation SSIS Tasks and Connectors Series AUTHOR: NAYAN PATEL | SR. ETL SSIS ARCHITECT N PAT E L @ R F TC LO U D S . C O M
  • 2. Content • Introduction • How to do REST API File Upload using SSIS • Understanding Multipart Upload / File Upload • Conclusion • Keywords
  • 3. Introduction • In this post you will learn how to use the SSIS REST APITask to perform REST API File Upload (i.e. RESTful file upload) to web server.Typically to access REST API you may have to use programming language but in this post we will use visual drag and drop approach. • File upload using HTTP/HTTPS protocol sometimes also known as multipart/form-data POST. Many REST APIs support for file upload using HTTP methods such as POST or PUT. • Real-world scenarios: • Uploading Image/media toTwitter or Facebook • Import Marketo Lead files using REST API
  • 4. How to do REST API File Upload using SSIS 1.DOWNLOAD AND INSTALL SSIS REST API TASK 2.FROM TOOLBOX OF THE SSIS DESIGNER DRAG ZS SSIS REST API TASK 3.DOUBLE CLICK REST API TASK TO CONFIGURE IT 4.SPECIFY URL WHERE YOU WISH TO POST FILE/OTHER DATA EXAMPLE : HTTP://MYSERVER/API/V1/UPLOADDATA 5.SELECT HTTP REQUEST METHOD AS POST ( MAKE SURE YOUR API DOCUMENTATION FOR THIS. SOMETIMES ITS PUT R ATHE R POST) 6.CHECK FILE UPLOAD OPTION NEXT TO BODY TEXT BOX !!!!THIS IS THE MOST IMPORTANT SO DON’T FORGET !!!!
  • 5. How to do REST API File Upload using SSIS 7.NOW CLICK EDIT BUTTON NEXT TO BODY TEXT BOX. YOU MAY SPECIFY F ILES / FIELDS YOU WISH TO SUBMIT ALONG WITH YOUR REQUEST IN THE FOLLOWING FORM AT. ITS KEY/VALUE PAIR SEPARATED BY NEW LINE. EACH KEY/VALUE PAIR HAS TO BE SEPARATED WITH EQUAL SIGN (=).NOTE: ANY VALUE STARTING WITH AT SYMBOL (@) IS TREATED AS FILE PATH. IF YOU DON’T WANT THAT BEHAVIOR THEN USE S LASH ALSO KNOWN AS ESCAPE SEQUENCE (E.G. SOMEFIELD3STARTSWITHAT=@MYTWITTERHANDLE). YOU CAN DO SAME THING TO ADD NEW LINE CHARACTER IN YOUR VALUE. USE RN FOR NEW LINE. USE T FOR TABALSO NOTICE NAME OF FIELD CAN BE ANYTHING UNLESS YOUR API EXPECTS IN CERTAIN WAY. EXAMPLE: TWITTER IMAGE UPLOAD API MAY EXPECT YOUR IMAGE FILE AS MEDIA FIELD IN THAT CASE YOU WOULD WRITE …. MEDIA=@C:DATASOMEIMAGE.PNG …. RATHER THAN FILE1=@C:DATASOMEIMAGE.PNG File1=@c:datasomedata.txt File2=@c:datasomeimage.png Somefield1=abcdef Somefield2=123456 Extrafield3WithNewLine=This is line1rnThis is line2 with tabt and more t tab Somefield3StartsWithAt=@MyTwitterHandle CLICK OK TO SAVE ABOVE
  • 6. How to do REST API File Upload using SSIS 8. NOW CLICK TEST BUTTON ON UI TO MAKE SURE EVERYTHING IS LOOKING GOOD. UPLOADING FILES USING REST API IN SSIS ( REST API FILE UPLOAD USING MULTIPART/FORM -DATA POST)
  • 7. Understanding Multipart Upload / File Upload NOW LETS TAKE A LOOK HOW DOES IT LOOK LIKE IN FIDDLER WHEN ACTUAL MULTIPART POST REQUEST IS MADE FOR REST API FILE UPLOAD. NOTICE EACH FIELD INCLUDED IN OUT HTTP POST REQUEST IS SEPARATED BY SOM E RANDOM BOUNDARY. THIS BOUNDARY IS AUTOMATICALLY GENERATED BY REST API TASK. IF YOU POST IMAGE THEN YOU WILL SEE BINARY DATA R ATHER THAN TEXT FOR FILE CONTENT. SEE IMAGE ON NEXT SLIDE
  • 8. HTTTP MULTIPART POST – FILE UPLOAD EXAMPLE – CHECK FIDDLER REQUEST
  • 9. Conclusion IF YOU HAVE NEED TO PERFORM REST API FILE UPLOAD / REST API INTEGRATION WITHOUT LEARNING COMPLEX APIS AND PROGRAMMING LANGUAGES (E.G. PYTHON, JAVA, C#) THEN SSIS REST API TASK PROVIDES PERFECT WAY TO DO REST API INTEGRATION WITH YOUR EXISTING SYSTEM . YOU CAN UNCOVER ENDLESS POSSIBILITIES WITH DRAG AND DROP APPROAC H WHICH IS NOT ONLY SIMPLE TO USE BUT INCLUDES MANY OPTIONS FOR COMPLEX SCENARIOS TOO.
  • 10. Keywords HOW TO PERFORM REST API FILE UPLOAD | HOW TO DO RESTFUL FILE UPLOAD IN C# | HOW TO DO MULTIPART FILE UPLOAD WITHOUT CURL | HOW TO UPLOAD MULTIPLE FILES USING HTTP MULTI PART FORMS | REST CLIENT UPLOAD FILE | C# REST API UPLOAD FILE | REST API UPLOAD IMAGE | REST API UPLOAD FILE