René's URL Explorer Experiment


Title: Add Simplified multipart/form-data Support to Web Cmdlets Through -Form Parameter by markekraus · Pull Request #5972 · PowerShell/PowerShell · GitHub

Open Graph Title: Add Simplified multipart/form-data Support to Web Cmdlets Through -Form Parameter by markekraus · Pull Request #5972 · PowerShell/PowerShell

X Title: Add Simplified multipart/form-data Support to Web Cmdlets Through -Form Parameter by markekraus · Pull Request #5972 · PowerShell/PowerShell

Description: PR Summary Closes #2112 🎉 Adds -Form Parameter to Invoke-WebRequest and Invoke-RestMethod -Form Accepts any IDictionary. Keys are used as multipart/form-data field names (PSObject unwrapped and ConvertTo(Object)) FileInfo values are added as StreamContent with application/octet-stream content type and the FileInfo.Name as the file name. Strings are treated as StringContent Singe values are converted to string with ConvertTo(Object) and treated as StringContent Top level collections are enumerated and converted as above. Nested collections are treated as a single value and converted accordingly. -Form is mutually exclusive with -Body and -InFile Per committee decision, -Form makes no assumptions about the HTTP method used. It can theoretically be used with any method. User will need to manually supply -Method POST to post the form. -ContentType and content related headers supplied to -Headers will be ignored/cleared as MultipartFormDataContent requires control of these headers. PR Checklist Note: Please mark anything not applicable to this PR NA. PR has a meaningful title Use the present tense and imperative mood when describing your changes Summarized changes User facing Documentation needed Issue filed - Issue link: MicrosoftDocs/PowerShell-Docs#2077 Change is not breaking Make sure you've added a new test if existing tests do not effectively test the code changed Add [feature] if the change is significant or affects feature tests This PR is ready to merge and is not Work in Progress. If the PR is work in progress, please add the prefix WIP: to the beginning of the title and remove the prefix when the PR is ready.

Open Graph Description: PR Summary Closes #2112 🎉 Adds -Form Parameter to Invoke-WebRequest and Invoke-RestMethod -Form Accepts any IDictionary. Keys are used as multipart/form-data field names (PSObject unwrapped and Co...

X Description: PR Summary Closes #2112 🎉 Adds -Form Parameter to Invoke-WebRequest and Invoke-RestMethod -Form Accepts any IDictionary. Keys are used as multipart/form-data field names (PSObject unwrapped and Co...

Opengraph URL: https://github.com/PowerShell/PowerShell/pull/5972

X: @github

direct link

Domain: github.com

route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:e1fac410-6940-5ae5-774b-254b09030bc1
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idCF3A:38B43C:14D12F1:1D65A49:6A552D73
html-safe-nonce5ef02ee09cb446556107233f4bb3631e7117878c7e6d10c009f074529358e835
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDRjNBOjM4QjQzQzoxNEQxMkYxOjFENjVBNDk6NkE1NTJENzMiLCJ2aXNpdG9yX2lkIjoiNTA1NzI3ODk1NTc5NjkwMTIzNSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmacea1a183364b13cf4f701389c32248c6bd5277215e8ed59f51c66382b5bcccbfa
hovercard-subject-tagpull_request:164178171
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/PowerShell/PowerShell/pull/5972/files
twitter:imagehttps://avatars.githubusercontent.com/u/6509955?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/6509955?s=400&v=4
og:image:altPR Summary Closes #2112 🎉 Adds -Form Parameter to Invoke-WebRequest and Invoke-RestMethod -Form Accepts any IDictionary. Keys are used as multipart/form-data field names (PSObject unwrapped and Co...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Nonefbd8fce4d63ac394c5405faa20aa50d5c9e56b979ac43ee1b26f8e7c47c4cd89
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/PowerShell/PowerShell git https://github.com/PowerShell/PowerShell.git
octolytics-dimension-user_id11524380
octolytics-dimension-user_loginPowerShell
octolytics-dimension-repository_id49609581
octolytics-dimension-repository_nwoPowerShell/PowerShell
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id49609581
octolytics-dimension-repository_network_root_nwoPowerShell/PowerShell
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasecf96660b44878f418b09d3d6ecde00ad62332910
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/PowerShell/PowerShell/pull/5972/files#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPowerShell%2Fpull%2F5972%2Ffiles
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FPowerShell%2FPowerShell%2Fpull%2F5972%2Ffiles
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=PowerShell%2FPowerShell
Reloadhttps://github.com/PowerShell/PowerShell/pull/5972/files
Reloadhttps://github.com/PowerShell/PowerShell/pull/5972/files
Reloadhttps://github.com/PowerShell/PowerShell/pull/5972/files
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
PowerShell https://github.com/PowerShell
PowerShellhttps://github.com/PowerShell/PowerShell
Notifications https://github.com/login?return_to=%2FPowerShell%2FPowerShell
Fork 8.4k https://github.com/login?return_to=%2FPowerShell%2FPowerShell
Star 54.4k https://github.com/login?return_to=%2FPowerShell%2FPowerShell
Code https://github.com/PowerShell/PowerShell
Issues 1.2k https://github.com/PowerShell/PowerShell/issues
Pull requests 288 https://github.com/PowerShell/PowerShell/pulls
Discussions https://github.com/PowerShell/PowerShell/discussions
Actions https://github.com/PowerShell/PowerShell/actions
Projects https://github.com/PowerShell/PowerShell/projects
Security and quality 3 https://github.com/PowerShell/PowerShell/security
Insights https://github.com/PowerShell/PowerShell/pulse
Code https://github.com/PowerShell/PowerShell
Issues https://github.com/PowerShell/PowerShell/issues
Pull requests https://github.com/PowerShell/PowerShell/pulls
Discussions https://github.com/PowerShell/PowerShell/discussions
Actions https://github.com/PowerShell/PowerShell/actions
Projects https://github.com/PowerShell/PowerShell/projects
Security and quality https://github.com/PowerShell/PowerShell/security
Insights https://github.com/PowerShell/PowerShell/pulse
Sign up for GitHub https://github.com/signup?return_to=%2FPowerShell%2FPowerShell%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2FPowerShell%2FPowerShell%2Fissues%2Fnew%2Fchoose
iSazonovhttps://github.com/iSazonov
PowerShell:masterhttps://github.com/PowerShell/PowerShell/tree/master
markekraus:SimplifyMultipartFormDatahttps://github.com/markekraus/PowerShell/tree/SimplifyMultipartFormData
Conversation 52 https://github.com/PowerShell/PowerShell/pull/5972
Commits 11 https://github.com/PowerShell/PowerShell/pull/5972/commits
Checks 0 https://github.com/PowerShell/PowerShell/pull/5972/checks
Files changed https://github.com/PowerShell/PowerShell/pull/5972/files
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
Add Simplified multipart/form-data Support to Web Cmdlets Through -Form Parameter https://github.com/PowerShell/PowerShell/pull/5972/files#top
Show all changes 11 commits https://github.com/PowerShell/PowerShell/pull/5972/files
d383458 [Feature] Add Simplified multipart/form-data Support to Web Cmdlets markekraus Jan 20, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/d383458b18f7447676af253e9a4f3c15d59b162a
2abd895 [feature] Add Tests and Address PR Feedback markekraus Jan 22, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/2abd8959056ca618d3a333a40a02416ca33c6240
cb249f0 [feature] Move private below internal markekraus Jan 22, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/cb249f0b3e12e3cec197e156e1034d805ebd3251
3939df9 [feature] Cleanup formatting markekraus Jan 22, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/3939df91f555caead9a5d5dafa185d38c1dc1cf1
c45e693 [feature] Address PR Feedback markekraus Jan 22, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/c45e693bf5c6bbcf555149e22ce899c971d9fb8d
3bcf3af [Feature] add missing -force markekraus Jan 22, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/3bcf3aff7bc1a1950a619e755a04a5421773e5a4
a64dfeb [feature] Revert Content-Type to Match markekraus Jan 22, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/a64dfebf1750f6351336bae44a29e2bead59f739
aa187ff [Feature] Rerun CI markekraus Jan 23, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/aa187ff04b22c65a0527d011b62be1c384591402
b4ac5c4 [Feature] remove errant inc file markekraus Jan 23, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/b4ac5c453ce809fc094a57c84a79301a4878155f
ca81f0a Address PR Feedback markekraus Jan 23, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/ca81f0a7d0250e335bb330d6593a6166e2ba625a
9e78323 [feature] Address PR Feedback markekraus Jan 24, 2018 https://github.com/PowerShell/PowerShell/pull/5972/commits/9e7832316c51ff4e49827b4b273aa107b99ae744
Clear filters https://github.com/PowerShell/PowerShell/pull/5972/files
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
WebRequestPSCmdlet.Common.cs https://github.com/PowerShell/PowerShell/pull/5972/files#diff-9e8673bc737d91c9712fa4e7e5fef6aac6690999bcbd0777759563afd015c50d
WebCmdletStrings.resx https://github.com/PowerShell/PowerShell/pull/5972/files#diff-6369d0eaaf4ecd1af385b0750c055d6b517506e3644cb46dd4e0140b0b12fcbc
WebCmdlets.Tests.ps1 https://github.com/PowerShell/PowerShell/pull/5972/files#diff-1b256250c40f42b7c01f2695c0c908112a4eead87e3ef3ff534768ad930e7ca1
https://github.com/PowerShell/PowerShell/blob/master/.github/CODEOWNERS#L7
...owerShell.Commands.Utility/commands/utility/WebCmdlet/Common/WebRequestPSCmdlet.Common.cshttps://github.com/PowerShell/PowerShell/pull/5972/files#diff-9e8673bc737d91c9712fa4e7e5fef6aac6690999bcbd0777759563afd015c50d
View file https://github.com/markekraus/PowerShell/blob/9e7832316c51ff4e49827b4b273aa107b99ae744/src/Microsoft.PowerShell.Commands.Utility/commands/utility/WebCmdlet/Common/WebRequestPSCmdlet.Common.cs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/PowerShell/PowerShell/pull/5972/{{ revealButtonHref }}
https://github.com/PowerShell/PowerShell/pull/5972/files#diff-9e8673bc737d91c9712fa4e7e5fef6aac6690999bcbd0777759563afd015c50d
https://github.com/PowerShell/PowerShell/pull/5972/files#diff-9e8673bc737d91c9712fa4e7e5fef6aac6690999bcbd0777759563afd015c50d
https://github.com/PowerShell/PowerShell/pull/5972/files#diff-9e8673bc737d91c9712fa4e7e5fef6aac6690999bcbd0777759563afd015c50d
https://github.com/PowerShell/PowerShell/pull/5972/files#diff-9e8673bc737d91c9712fa4e7e5fef6aac6690999bcbd0777759563afd015c50d
https://github.com/PowerShell/PowerShell/pull/5972/files#diff-9e8673bc737d91c9712fa4e7e5fef6aac6690999bcbd0777759563afd015c50d
https://github.com/PowerShell/PowerShell/pull/5972/files#diff-9e8673bc737d91c9712fa4e7e5fef6aac6690999bcbd0777759563afd015c50d
https://github.com/PowerShell/PowerShell/pull/5972/files#diff-9e8673bc737d91c9712fa4e7e5fef6aac6690999bcbd0777759563afd015c50d
SteveL-MSFThttps://github.com/SteveL-MSFT
Jan 24, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r163432891
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
iSazonovhttps://github.com/iSazonov
Jan 24, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r163452369
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
rkeithhillhttps://github.com/rkeithhill
Jan 24, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r163455132
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
markekraushttps://github.com/markekraus
Jan 24, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r163493581
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
@rkeithhillhttps://github.com/rkeithhill
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
markekraushttps://github.com/markekraus
Jan 24, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r163495940
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
@SteveL-MSFThttps://github.com/SteveL-MSFT
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
iSazonovhttps://github.com/iSazonov
Jan 24, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r163497413
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
SteveL-MSFThttps://github.com/SteveL-MSFT
Jan 24, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r163698558
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
@markekraushttps://github.com/markekraus
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
https://github.com/PowerShell/PowerShell/blob/master/.github/CODEOWNERS#L7
src/Microsoft.PowerShell.Commands.Utility/resources/WebCmdletStrings.resxhttps://github.com/PowerShell/PowerShell/pull/5972/files#diff-6369d0eaaf4ecd1af385b0750c055d6b517506e3644cb46dd4e0140b0b12fcbc
View file https://github.com/markekraus/PowerShell/blob/9e7832316c51ff4e49827b4b273aa107b99ae744/src/Microsoft.PowerShell.Commands.Utility/resources/WebCmdletStrings.resx
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/PowerShell/PowerShell/pull/5972/{{ revealButtonHref }}
https://github.com/PowerShell/PowerShell/pull/5972/files#diff-6369d0eaaf4ecd1af385b0750c055d6b517506e3644cb46dd4e0140b0b12fcbc
iSazonovhttps://github.com/iSazonov
Jan 22, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r162857125
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
markekraushttps://github.com/markekraus
Jan 22, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r162885058
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
#5140https://github.com/PowerShell/PowerShell/issues/5140
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
iSazonovhttps://github.com/iSazonov
Jan 22, 2018https://github.com/PowerShell/PowerShell/pull/5972/files#r162888868
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
https://github.com/PowerShell/PowerShell/pull/5972/files#diff-6369d0eaaf4ecd1af385b0750c055d6b517506e3644cb46dd4e0140b0b12fcbc
Please reload this pagehttps://github.com/PowerShell/PowerShell/pull/5972/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.