Skip to content

Instantly share code, notes, and snippets.

View vaurdan's full-sized avatar

Henrique Mouta vaurdan

View GitHub Profile
@vaurdan
vaurdan / AGENT.md
Created May 8, 2026 09:52
SpritesDoc — staging proxy access (for the agent team)

SpritesDoc — staging proxy access (for the agent team)

TL;DR

When testing against staging, route SpritesDoc API calls through a proxy URL with a different auth header. Do not use this in production. Keep the proxy URL and X-Proxy-Auth token behind a configuration flag so prod talks to sprites-api directly.

Why a proxy exists

@vaurdan
vaurdan / spritesdoc-update-2026-05-06.md
Created May 6, 2026 12:52
SpritesDoc API update 2026-05-06 — start_and_probe action + behavior fixes

SpritesDoc API — update 2026-05-06

This patch covers behavior fixes and one new action since the last agent-facing gist. Read this alongside the existing gists (full API spec, mutations flow, sprite.lookup additions). Nothing here renames or removes any existing endpoint or arg; the patch is additive.


1. New action: start_and_probe

import cfscrape
import json
import sys
import argparse
import requests
import logging
import time
import random
from pgoapi import PGoApi
@vaurdan
vaurdan / generate.py
Created August 2, 2016 15:25
Generates supervisord config files
import itertools
import argparse
import os
import glob
import sys
parser = argparse.ArgumentParser()
parser.add_argument("-uf", "--users-file", help="File with users and passwords", default="users.txt")
parser.add_argument("-cf", "--coords-file", help="Coordinate files. Allows wildcards", default="*coords.txt")
parser.add_argument("-st", "--steps", help="Steps per worker", default=5)
@vaurdan
vaurdan / designer.html
Last active August 29, 2015 14:20
designer
<link rel="import" href="../core-drawer-panel/core-drawer-panel.html">
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<polymer-element name="my-element">
<template>
<style>
:host {
@vaurdan
vaurdan / shortcode-ip.php
Last active August 29, 2015 14:16
Get the IP address of a given hostname. Use it on a WordPress blog with a easy to use shortcode.
<?php
/*
Plugin Name: Shortcode for IP
Description: Get's an IP from an hostname
Author: Henrique Mouta
Version: 1.0
Author URI: http://henrique.mouta.org/
*/
add_shortcode( 'get_ip', function( $atts ) {