Skip to content

Instantly share code, notes, and snippets.

@jovaneyck
Created June 18, 2017 18:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jovaneyck/f215bbd7ef7a42dce9a91ccb0c16c5fb to your computer and use it in GitHub Desktop.
Save jovaneyck/f215bbd7ef7a42dce9a91ccb0c16c5fb to your computer and use it in GitHub Desktop.
#r @"..\packages\FSharp.Data.TypeProviders\lib\net40\FSharp.Data.TypeProviders.dll"
#r @"System.ServiceModel.dll"
#r @"System.Runtime.Serialization.dll" //Needed to see the generated contract types in you IDE.
open FSharp.Data.TypeProviders
open System.ServiceModel
type Service = WsdlService<"http://webservices.oorsprong.org/websamples.countryinfo/CountryInfoService.wso?WSDL">
let svc = Service.GetCountryInfoServiceSoap12()
let response = svc.FullCountryInfo("NG")
printf "Languages of %s: " response.sName
response.Languages
|> Seq.map(fun lang -> lang.sName)
|> String.concat ","
|> printfn "%s"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment