{"tools":[{"type":"function","function":{"name":"shorten_url","description":"Shorten a long URL and get a memorable b59.link short URL. Optionally specify a custom slug. Returns the short URL and a stats URL.","parameters":{"type":"object","properties":{"url":{"type":"string","description":"The URL to shorten."},"slug":{"type":"string","description":"Optional custom slug (letters, digits, hyphens, underscores, max 100 chars). A random slug is used if omitted."}},"required":["url"]}}},{"type":"function","function":{"name":"generate_qr","description":"Generate a QR code for a URL. Creates a b59.link short URL at the same time. Returns the short URL, a stats URL, and the QR code as a base64-encoded PNG.","parameters":{"type":"object","properties":{"url":{"type":"string","description":"The URL to generate a QR code for."}},"required":["url"]}}},{"type":"function","function":{"name":"get_stats","description":"Get click statistics for a b59.link short URL. Pass either the slug (e.g. 'cool-idea') or the original long URL.","parameters":{"type":"object","properties":{"identifier":{"type":"string","description":"The b59.link slug or the original URL."}},"required":["identifier"]}}},{"type":"function","function":{"name":"lookup_url","description":"Check whether a URL already has a b59.link short URL. Handles variations: http/https, www prefix, trailing slash. Returns the existing short URL and QR code if found.","parameters":{"type":"object","properties":{"url":{"type":"string","description":"The URL to look up."}},"required":["url"]}}}]}