Skip to content

Instantly share code, notes, and snippets.

class DeleteTicJob
include Sidekiq::Job
sidekiq_options queue: "default", retry_queue: "errors"
def perform(ticket_id)
require "zendesk_api"
client = ZendeskAPI::Client.new do |config|
config.url = ENV["ZENDESK_URL"] # e.g. https://yoursubdomain.zendesk.com/api/v2
config.username = ENV["ZENDESK_USERNAME"]
class Dashing.Btcprice extends Dashing.Widget
@accessor 'value', Dashing.AnimatedValue
@accessor 'btcprice', ->
if @get('value')
price = parseFloat(@get('value'))
class Dashing.Ethprice extends Dashing.Widget
@accessor 'value', Dashing.AnimatedValue
@accessor 'ethprice', ->
if @get('value')
price = parseFloat(@get('value'))
@Skeyelab
Skeyelab / gdax-ltc.rb
Last active January 16, 2018 15:31
GDAX Spot Price - LTC
require 'net/http'
require 'json'
require 'uri'
SCHEDULER.every '5s', allow_overlapping: false do
uri = URI.parse('https://api.coinbase.com/v2/prices/LTC-USD/spot')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Get.new(uri.request_uri)
{{ email_in.body | scan: '(Job Number:|Incident) (INC[0-9]*)', '0'}}
@Skeyelab
Skeyelab / readme.md
Last active October 5, 2017 12:56
Zendesk Dashing Widget

i'll add some documentaton, but it should be pretty straight forward from the comments

add gem 'zendesk_api', '~> 1.4.3' to your gemfile

@Skeyelab
Skeyelab / Groupon2Shopify.iim
Created April 2, 2012 17:13
The Goal: I needed a way for us to quickly import the hundreds of Groupon codes into our Shopify site. My Solution: Use iMacros for FireFox to read in the Groupon CSV and automate the process of creating Shopify discount codes.
VERSION BUILD=7000908
'Use groupon csv to automatically create discount codes in shopify.
'####################### ENTER YOUR SETTINGS BELOW #############################
'What is your shopify store name yourshopname.myshopify.com
SET !VAR1 https://fortunecookiesoap.myshopify.com
'How much is your discount? for a $15 discount enter 15
SET !VAR2 15