Developer Night 2017

October 26th, Square HQ
Use https if you want the payment forms to load
    What is going on?
  • Getting started with Square's developer platform
  • Recap: what has come out recently?
  • A sneak peek into some upcoming features🕵
  • Socializing + Q & A
Gettings Started with Square as a Developer
E-Commerce

					
					
ssdf
ss
sss
sss
Card Nonce:

Charge Endpoint


					POST /v2/locations/LOCATION_ID/transactions  {

						"idempotency_key": "74ae1696",
						"amount_money": {
							"amount": 5000,  
							"currency": "USD"
						},
						"card_nonce": "card_nonce_from_square_123"
					}
			

			curl -X POST \
			https://connect.squareup.com/v2/locations/CBASEM9Ry3uB-6qCeuoZP6wRR7k/transactions \
			-H 'authorization: Bearer sq0atb-tsn132D7btUhW3uL_y5I3w' \
			-H 'content-type: application/json' \
			-d '{
				"idempotency_key": "",
				"amount_money": {
				"amount": 100,
				"currency": "USD"
			},
				"card_nonce": ""
			}' | python -m json.tool
Recurring payments?

Create a customer


				curl -X POST \
				https://connect.squareup.com/v2/customers \
				-H 'authorization: Bearer sq0atb-tsn132D7btUhW3uL_y5I3w' \
				-H 'content-type: application/json' \
				-d '{
				"given_name": "Veronica",
				"family_name": "Slocombe",
				"email_address": "V.Slocombe@example.com",
				"note": "an exceptional customer"
				}' | python -m json.tool
		
Create a card Nonce
ssdf
ss
sss
sss
Card Nonce:

attach to customer:


			curl -X POST \
			https://connect.squareup.com/v2/customers//cards \
			-H 'authorization: Bearer sq0atb-tsn132D7btUhW3uL_y5I3w' \
			-H 'content-type: application/json' \
			-d '{
			"card_nonce": "",
			"billing_address": {
			"address_line_1": "500 Electric Ave",
			"address_line_2": "Suite 600",
			"locality": "New York",
			"administrative_district_level_1": "NY",
			"postal_code": "11111",
			"country": "US"
			},
			"cardholder_name": "Amelia Earhart"
			}' | python -m json.tool

Charge


		curl -X POST \
		https://connect.squareup.com/v2/locations/CBASEM9Ry3uB-6qCeuoZP6wRR7k/transactions \
		-H 'authorization: Bearer sq0atb-tsn132D7btUhW3uL_y5I3w' \
		-H 'content-type: application/json' \
		-d '{
		"idempotency_key": "",
		"amount_money": {
		"amount": 100,
		"currency": "USD"
		},
		"customer_id":"",
		"customer_card_id":""
		}' | python -m json.tool

List Transactions


		curl -X GET \
		https://connect.squareup.com/v2/locations/CBASEM9Ry3uB-6qCeuoZP6wRR7k/transactions \
		-H 'authorization: Bearer sq0atb-tsn132D7btUhW3uL_y5I3w' \
		| python -m json.tool
	

Square Checkout


			curl -X POST \
			https://connect.squareup.com/v2/locations/CBASEM9Ry3uB-6qCeuoZP6wRR7k/checkouts \
			-H 'authorization: Bearer sq0atb-tsn132D7btUhW3uL_y5I3w' \
			-H 'content-type: application/json' \
			-d '{
			"idempotency_key": "",
			"order": {
			"line_items": [{
			"name": "Spikey Succulent",
			"quantity": "2",
			"base_price_money": {
			"amount": 1500,
			"currency": "USD"
			},
			"discounts": [{
			"name": "15% off mean looking item",
			"percentage": "7"
			}]
			}],
			"taxes": [{
			"name": "Sales Tax",
			"percentage": "8.5"
			}]
			},
			"redirect_url": "https://giphy.com/search/happy"
			}' | python -m json.tool

Point of Sale API

Point of Sale API

Click here to checkout

Recent releases

  • Orders API
  • Apple Pay on the Web
  • Interactive documentation sandbox
  • LocationId's in the developer portal
  • Catalog API, Checkout & More!

What is coming up

  • Multi-party settlement
  • Node.js SDK
  • New Transaction/Charge documentation

square.com/developers

squ.re/slack

@SquareDev

corner.squareup.com

tristansokol.github.io/Presentations

Thanks to Mathias Berwig for intro animation