Twelve Go Best Practices
Francesc Campoy Flores Gopher at Google @francesc http://campoy.cat/+
- Best practices
If you find any errors or discrepancies please notify [email protected]__. Also if you have any brilliant ideas on how we can make it better, let us know. __:)__ | |
Also, __don’t be evil__. | |
# Introduction | |
The Vend API is implemented as JSON over HTTPS using the verbs GET, PUT, POST and DELETE. | |
## Authentication | |
Authentication is managed using HTTP authentication (only "Basic" is supported right now). Every request must include the Authorization HTTP header. Use the properties username and password to authenticate. Example with Curl: |
load_assembly "RevitAPI" | |
load_assembly "RevitAPIUI" | |
include Autodesk::Revit::DB | |
include Autodesk::Revit::UI | |
include Autodesk::Revit::UI::Selection | |
include System::Collections::Generic | |
include System::Collections | |
include System |
on idle | |
set powerStatus to do shell script "pmset -g ps" | |
tell application "System Preferences" | |
reveal pane id "com.apple.preferences.Bluetooth" | |
#activate | |
tell application "System Events" to tell process "System Preferences" | |
set btCheckBox to checkbox "On" of window 1 | |
if powerStatus contains "Battery Power" then | |
tell btCheckBox |
using System; | |
using System.Net.Http; | |
namespace VendTest | |
{ | |
class MainClass | |
{ | |
public static void Main(string[] args) | |
{ | |
Client client = new Client(); |
Twelve Go Best Practices
Francesc Campoy Flores Gopher at Google @francesc http://campoy.cat/+
package main | |
import "fmt" | |
func main() { | |
var a int | |
var b int | |
var c *int | |
a = 42 |
I hereby claim:
To claim this, I am signing this object:
// This function exchanges the authorization code for a token and returns the parsed info | |
function getToken(myCode, myDomainPrefix) { | |
var tokenUrl = "https://" + myDomainPrefix + ".vendhq.com/api/1.0/token"; | |
var payload = { | |
"code": myCode, | |
"client_id": myVendClientId, | |
"client_secret": myVendClientSecret, | |
"grant_type": "authorization_code", | |
"redirect_uri": myVendRedirectUri |
This module should include three main elements that will allow for a full integration of Tidio Chat with a website based on typo3.
These elements are: