Guest User

Untitled

a guest
Apr 21st, 2018
244
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.18 KB | None | 0 0
  1. using MundiAPI.PCL;
  2. using MundiAPI.PCL.Models;
  3. using System.Collections.Generic;
  4.  
  5. namespace TutorialPedido {
  6. class Program {
  7. static void Main(string[] args) {
  8.  
  9. // Secret key fornecida pela MundiPagg
  10. string basicAuthUserName = "sk_test_4AdjlqpseatnmgbW";
  11. // Senha em branco. Passando apenas a secret key
  12. string basicAuthPassword = "";
  13. var client = new MundiAPIClient(basicAuthUserName, basicAuthPassword);
  14.  
  15. var customer = new CreateCustomerRequest {
  16. Name = "Tony Stark",
  17. Email = "tonystark@avengers.com",
  18. };
  19.  
  20. var items = new List<CreateOrderItemRequest> {
  21. new CreateOrderItemRequest{
  22. Amount = 2990,
  23. Description = "Chaveiro do Tesseract",
  24. Quantity =1,
  25. },
  26. new CreateOrderItemRequest{
  27. Amount = 5990,
  28. Description = "Manopla do Infinito",
  29. Quantity =1
  30. },
  31.  
  32. };
  33.  
  34. var order = new CreateOrderRequest() {
  35. Items = items,
  36. };
  37. }
  38. }
  39. }
Add Comment
Please, Sign In to add comment