Skip to content

Instantly share code, notes, and snippets.

View johnnygoodman's full-sized avatar

Johnny Goodman johnnygoodman

View GitHub Profile
{"apiVersion":"v1","swaggerVersion":"1.2","resourcePath":"/messages","produces":["application/xml","application/json","application/octet-stream","text/plain"],"apis":[{"path":"/api/v1/messages","operations":[{"notes":"","summary":"Return all messages","nickname":"GET-api--version-messages--json-","method":"GET","parameters":[],"type":"void"},{"notes":"","summary":"Create and send a message","nickname":"POST-api--version-messages--json-","method":"POST","parameters":[{"paramType":"form","name":"title","description":"Title/Subject of the message","type":"string","required":true,"allowMultiple":false},{"paramType":"form","name":"body","description":"Body of the message","type":"string","required":true,"allowMultiple":false},{"paramType":"form","name":"user_id","description":"User ID of the message author","type":"integer","required":true,"allowMultiple":false,"format":"int32"},{"paramType":"body","name":"group_ids","description":"Group IDs of message targets, passed as a String and typecast as an array on the AP
➜ ~ traceroute cpap.com
traceroute: Warning: cpap.com has multiple addresses; using 199.83.132.93
traceroute to cpap.com (199.83.132.93), 64 hops max, 52 byte packets
1 192.168.1.1 (192.168.1.1) 8.024 ms 2.448 ms 2.232 ms
2 172.26.242.53 (172.26.242.53) 43.347 ms 40.345 ms 40.676 ms
3 172.26.236.2 (172.26.236.2) 37.815 ms 39.028 ms 44.567 ms
4 172.26.96.2 (172.26.96.2) 37.488 ms 44.165 ms 35.750 ms
5 172.26.96.193 (172.26.96.193) 37.873 ms 40.352 ms 40.324 ms
6 172.16.78.113 (172.16.78.113) 40.214 ms 38.989 ms 42.524 ms
7 12.249.2.1 (12.249.2.1) 41.296 ms 40.769 ms 38.245 ms
@johnnygoodman
johnnygoodman / gist:8221803
Created January 2, 2014 16:24
Working Xpenser POST
opened
<- "POST /api/v1.0/expense?q=Freight%2010.00%20Fedex%20Refund%20%23%20%23TaxNotPaid-Exempt&d=2013-12-04%2012%3A00%3A00 HTTP/1.1\r\nAuthorization: Basic am9obm55Lmdvb2RtYW5AZ21haWwuY29tOm1peTk1a2Vr\r\nConnection: close\r\nHost: xpenser.com\r\n\r\n"
-> "HTTP/1.1 200 OK\r\n"
-> "Server: nginx/1.1.19\r\n"
-> "Date: Thu, 02 Jan 2014 16:11:21 GMT\r\n"
-> "Content-Type: application/json; charset=utf-8\r\n"
-> "Transfer-Encoding: chunked\r\n"
-> "Connection: close\r\n"
-> "Vary: Authorization, Cookie\r\n"
-> "\r\n"
html {
height:100%;
margin:0;
padding:0;
}
body {
height:100%;
font-family:Tahoma,Arial,FreeSans,sans-serif;
font-size:12px;
This file has been truncated, but you can view the full file.
html {
margin: 0;
padding: 0;
height: 100 %
}
body {
margin: 0;
padding: 0;
height: 100 % ;
font - family: Tahoma,
opening connection to xpenser.com...
opened
<- "POST /api/v1.0/expense/4926992?tags=TaxedAlready&amount=35.95 HTTP/1.1\r\nAuthorization: Basic am9obm55Lmdvb2RtYW5AZ21haWwuY29tOm1peTk1a2Vr\r\nConnection: close\r\nHost: xpenser.com\r\n\r\n"
-> "HTTP/1.1 200 OK\r\n"
-> "Server: nginx/1.1.19\r\n"
-> "Date: Thu, 10 Oct 2013 00:31:04 GMT\r\n"
-> "Content-Type: application/json; charset=utf-8\r\n"
-> "Transfer-Encoding: chunked\r\n"
-> "Connection: close\r\n"
-> "Vary: Authorization, Cookie\r\n"
require 'contextio'
require 'active_support/all'
require 'date'
contextio = ContextIO.new('key', 'secret')
account = contextio.accounts.where(email: 'myemail@cpap.com').first
date_before = Time.now.utc - 30.minutes
date_after = Time.now.utc - 1.minute
@johnnygoodman
johnnygoodman / gist:5623575
Created May 21, 2013 21:53
CPAP.com Source Code
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta content="IE=8" http-equiv="X-UA-Compatible" />
<meta name="description" content="Shop CPAP.com for low prices on CPAP masks, machines and supplies. Find the biggest selection here for ResMed, Respironics, Fisher &amp; Paykel plus more.">
<meta name="keywords" content="cpap,cpaps,cpap machine,cpap machines,cpap mask,cpap masks,cpap supplies,cpap supply,resmed,respironics,puritan benet,fisher &amp; paykel,cpap.com,filters,tubing,cushions,headgear,devilbiss,somnetics">
<link rel="canonical" href="http://www.cpap.com/"/>
<meta name="google-site-verification" content="wYqVbCtxN_YM1tLTZmGkUDbEmNrSjpB7hBNp5_Avsvs" />
1.9.3-p392 :021 > HTTParty.get('http://api.framebase.io/videos/f4ad2fdf-d272-481e-9c9a-904fcf182404').response.body.inspect
=> "\"Array\""
Are you intending to return the string Array to this request?
I suspect ya'll accidentally echo'd array instead of returning an actual array with attributes fileURI and rtmpURI (https://framebase.io/docs/rest)
<!DOCTYPE html>
<html>
<head>
<title>Cpapevents</title>
<link href="/assets/application-4bd27be0b3ffecfd52de4ba6812b4694.css" media="all" rel="stylesheet" type="text/css" />
<script src="/assets/application-613c0b3882f97791291dda5a6fa98da0.js" type="text/javascript"></script>
<meta content="authenticity_token" name="csrf-param" />
<meta content="npM7UoIcujeJlSHikWSMWO8VXxmyX5uWLCwYNlT5tN8=" name="csrf-token" />
</head>