SyntaxTree.FastSpring.Api is a C# library to query the FastSpring REST API.
It works on .NET 3.5, .NET 4.0 and .NET 4.5.
namespaceSyntaxTree.FastSpring.Api{publicsealedclassCompanyStore{publicCompanyStore(StoreCredentialcredential){}publicOrderOrder(stringreference){}}publicsealedclassStoreCredential{publicstringCompany{get;set;}publicstringUsername{get;set;}publicstringPassword{get;set;}publicStoreCredential(stringcompany,stringusername,stringpassword){}}}Usage sample:
usingSyntaxTree.FastSpring.Api;publicclassProgram{publicstaticvoidMain(){varstore=newCompanyStore(newStoreCredential(company:"Microsoft",username:"api-user",password:"xxx"));varorder=store.Order(reference:"SYNXXXXXX-XXXX-XXXXX");Console.WriteLine(order.Customer.FirstName);}}We currently only support the order and coupon API, not the subscription one.
All calls made to the FastSpring server are currently made synchronous and blocking. Wrap your calls into a Task if you want them to to be asynchronous.