This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using Xero.Api.Core; | |
using Xero.Api.Example.TokenStores; | |
using Xero.Api.Infrastructure.OAuth; | |
namespace Xero.Api.Example.Counts | |
{ | |
class Program | |
{ | |
static void Main(string[] args) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Test] | |
public void find_PL_report() | |
{ | |
var reports = Api.Reports.ProfitAndLoss(DateTime.Now.AddDays(-50), null, null, Guid.Parse("351953c4-XXXX-4009-88c3-f9cd8c9cbe9f"), null, Guid.Parse("48d69e13-XXXX-47ec-a615-c1a9ff47962a")); | |
Assert.IsNotNull(reports); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Test] | |
public void find_all_accounts() | |
{ | |
var accounts = Api.Accounts.Find(); | |
Assert.True(accounts.Count() > 0); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PUT https://api.xero.com/api.xro/2.0/Invoices?unitdp=4&page=1 HTTP/1.1 | |
Accept: application/json | |
Authorization: OAuth oauth_consumer_key="?", oauth_token="??", oauth_signature_method="RSA-SHA1", oauth_signature="??", oauth_timestamp="?", oauth_nonce="?", oauth_version="1.0" | |
User-Agent: Xero Api - Integration tests | |
Content-Type: application/xml | |
Host: api.xero.com | |
Content-Length: 487 | |
Expect: 100-continue | |
Accept-Encoding: gzip, deflate | |
Connection: Keep-Alive |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
var restify = require('restify'); | |
var fs = require('fs'); | |
var request = require('request'); | |
var qs = require('qs'); | |
var GET_request = function (req, res, next) { | |
var options = { | |
url: process.env.XERO_REQUEST_URL, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if ($this->config ['application_type'] == 'Partner') { | |
if (! file_get_contents ( $this->config ['curl_ssl_cert'] )) { | |
$testOutput ['ssl_cert_error'] = "Can't read the Xero Entrust cert. You need one for partner API applications. http://developer.xero.com/documentation/getting-started/partner-applications/ \n"; | |
} else { | |
$data = openssl_x509_parse ( file_get_contents ( $this->config ['curl_ssl_cert'] ) ); | |
$validFrom = date ( 'Y-m-d H:i:s', $data ['validFrom_time_t'] ); | |
if (time () < $data ['validFrom_time_t']) { | |
$testOutput ['ssl_cert_error'] = "Xero Entrust cert not yet valid - cert valid from " . $validFrom . "\n"; | |
} | |
$validTo = date ( 'Y-m-d H:i:s', $data ['validTo_time_t'] ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo rm -rf ~/dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"language": "Frisian", | |
"text": "Goeie dei" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@charset "UTF-8"; | |
.szh-menu-container { | |
position: relative; | |
width: 0px; | |
height: 0px; | |
} | |
.szh-menu { | |
margin: 0; | |
padding: 0; |