The TinyURL connector lets your AI agent act in each user's TinyURL account. Each user connects their own TinyURL access token once, and Scalekit sends it with every call, so your agent never handles credentials. It comes with 21 tools.
- Tools
- 21
- What they doRead · write · destructive
- 13 · 7 · 113 read7 write1 destructive
- Users sign in with
- Access token
Setup
Install the SDK
Terminal window npm install @scalekit-sdk/node dotenvTerminal window pip install scalekit-sdk-python python-dotenvSet your credentials
Add your Scalekit credentials to your
.envfile. Find values in app.scalekit.com > Developers > API Credentials..env SCALEKIT_ENVIRONMENT_URL=<your-environment-url>SCALEKIT_CLIENT_ID=<your-client-id>SCALEKIT_CLIENT_SECRET=<your-client-secret>Create the TinyURL connection
In AgentKit > Connections, create a TinyURL connection. The name you give it is the
connection_nameyour code passes. See Configure connections.Authorize a user and make your first call
quickstart.mts import { ScalekitClient } from '@scalekit-sdk/node'import 'dotenv/config'import { createInterface } from 'node:readline/promises'const scalekit = new ScalekitClient(process.env.SCALEKIT_ENVIRONMENT_URL,process.env.SCALEKIT_CLIENT_ID,process.env.SCALEKIT_CLIENT_SECRET,)const actions = scalekit.actionsconst connector = 'tinyurl'const identifier = 'user_123'// Generate an authorization link for the userconst { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })console.log('Authorize TinyURL:', link)const rl = createInterface({ input: process.stdin, output: process.stdout })await rl.question('Press Enter after authorizing...')rl.close()// Make your first callconst result = await actions.executeTool({connector,identifier,toolName: 'tinyurl_analytics_general_get',toolInput: { from: '2025-01-01 00:00:00' },})console.log(result)Terminal window npx tsx quickstart.mtsquickstart.py import osfrom scalekit import ScalekitClientfrom dotenv import load_dotenvload_dotenv()scalekit_client = ScalekitClient(env_url=os.getenv("SCALEKIT_ENVIRONMENT_URL"),client_id=os.getenv("SCALEKIT_CLIENT_ID"),client_secret=os.getenv("SCALEKIT_CLIENT_SECRET"),)actions = scalekit_client.actionsconnection_name = "tinyurl"identifier = "user_123"# Generate an authorization link for the userlink_response = actions.get_authorization_link(connection_name=connection_name,identifier=identifier,)print("Authorize TinyURL:", link_response.link)input("Press Enter after authorizing...")# Make your first callresult = actions.execute_tool(tool_input={"from":"2025-01-01 00:00:00"},tool_name="tinyurl_analytics_general_get",connection_name=connection_name,identifier=identifier,)print(result)Terminal window python quickstart.pyEach user opens the link once and enters their TinyURL credentials there. See Authorize a user for the full flow and statuses.
Tools
Pass the exact name toexecute_tooltinyurl_analytics_general_getGet browser, operating system and device breakdowns for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account.Read-onlyGet Browser, OS and Device Stats
Get browser, operating system and device breakdowns for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account. Returns data with click counts by browser, os and device. Use the other analytics tools for other breakdowns. Click analytics need a paid TinyURL plan.
Inputs
fromstringrequired- Start of the report as a date-time. Example: 2025-01-01 00:00:00.
aliasstring- Limit the report to one TinyURL alias. Example: myexamplelink.
tagstring- Limit the report to TinyURLs with this tag. Example: campaign-q1.
tostring- End of the report as a date-time; defaults to now. Example: 2025-01-31 23:59:59.
tinyurl_analytics_hours_getGet click counts by hour of the day for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account.Read-onlyGet Hour Popularity
Get click counts by hour of the day for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account. Returns data with clicks per hour. Use the other analytics tools for other breakdowns. Click analytics need a paid TinyURL plan.
Inputs
fromstringrequired- Start of the report as a date-time. Example: 2025-01-01 00:00:00.
aliasstring- Limit the report to one TinyURL alias. Example: myexamplelink.
tagstring- Limit the report to TinyURLs with this tag. Example: campaign-q1.
tostring- End of the report as a date-time; defaults to now. Example: 2025-01-31 23:59:59.
tinyurl_analytics_languages_getGet the top visitor languages for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account.Read-onlyGet Top Languages
Get the top visitor languages for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account. Returns data with languages and their click counts. Use the other analytics tools for other breakdowns. Click analytics need a paid TinyURL plan.
Inputs
fromstringrequired- Start of the report as a date-time. Example: 2025-01-01 00:00:00.
aliasstring- Limit the report to one TinyURL alias. Example: myexamplelink.
tagstring- Limit the report to TinyURLs with this tag. Example: campaign-q1.
tostring- End of the report as a date-time; defaults to now. Example: 2025-01-31 23:59:59.
tinyurl_analytics_locations_getGet click locations by country, or by area inside one country for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account.Read-onlyGet Click Locations
Get click locations by country, or by area inside one country for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account. Returns data with locations and their click counts. Use the other analytics tools for other breakdowns. Click analytics need a paid TinyURL plan.
Inputs
fromstringrequired- Start of the report as a date-time. Example: 2025-01-01 00:00:00.
regionstringrequired- world for a breakdown by country, or a two-letter ISO 3166-1 country code for areas inside that country. Example: US.default
world aliasstring- Limit the report to one TinyURL alias. Example: myexamplelink.
tagstring- Limit the report to TinyURLs with this tag. Example: campaign-q1.
tostring- End of the report as a date-time; defaults to now. Example: 2025-01-31 23:59:59.
tinyurl_analytics_raw_listGet raw click logs for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account.Read-onlyList Raw Click Logs
Get raw click logs for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account. Returns data[] with one entry per click, including time, referrer, browser, operating system, device and location. Use the other analytics tools for other breakdowns. Click analytics need a paid TinyURL plan.
Inputs
fromstringrequired- Start of the report as a date-time. Example: 2025-01-01 00:00:00.
aliasstring- Limit the report to one TinyURL alias. Example: myexamplelink.
tagstring- Limit the report to TinyURLs with this tag. Example: campaign-q1.
tostring- End of the report as a date-time; defaults to now. Example: 2025-01-31 23:59:59.
tinyurl_analytics_sources_getGet the top referring sources for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account.Read-onlyGet Top Sources
Get the top referring sources for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account. Returns data with sources and their click counts. Use the other analytics tools for other breakdowns. Click analytics need a paid TinyURL plan.
Inputs
fromstringrequired- Start of the report as a date-time. Example: 2025-01-01 00:00:00.
aliasstring- Limit the report to one TinyURL alias. Example: myexamplelink.
tagstring- Limit the report to TinyURLs with this tag. Example: campaign-q1.
tostring- End of the report as a date-time; defaults to now. Example: 2025-01-31 23:59:59.
tinyurl_analytics_timeline_getGet click counts over time for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account.Read-onlyGet Click Timeline
Get click counts over time for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account. Returns data with click counts per interval. Use the other analytics tools for other breakdowns. Click analytics need a paid TinyURL plan.
Inputs
fromstringrequired- Start of the report as a date-time. Example: 2025-01-01 00:00:00.
aliasstring- Limit the report to one TinyURL alias. Example: myexamplelink.
intervalstring- Time bucket: minute, hour, day, week or month. Example: day.one of
minutehourdayweekmonth tagstring- Limit the report to TinyURLs with this tag. Example: campaign-q1.
tostring- End of the report as a date-time; defaults to now. Example: 2025-01-31 23:59:59.
tinyurl_analytics_weekdays_getGet click counts by day of the week for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account.Read-onlyGet Weekday Popularity
Get click counts by day of the week for clicks on your TinyURLs in a date range, for one alias, one tag or the whole account. Returns data with clicks per weekday. Use the other analytics tools for other breakdowns. Click analytics need a paid TinyURL plan.
Inputs
fromstringrequired- Start of the report as a date-time. Example: 2025-01-01 00:00:00.
aliasstring- Limit the report to one TinyURL alias. Example: myexamplelink.
tagstring- Limit the report to TinyURLs with this tag. Example: campaign-q1.
tostring- End of the report as a date-time; defaults to now. Example: 2025-01-31 23:59:59.
tinyurl_bulk_request_report_getGet the per-item results of a bulk request.Read-onlyGet Bulk Request Report
Get the per-item results of a bulk request. Returns data[] with each item's operation, domain, alias, url, tinyurl, status (success or failed), comment and metadata. Use this after Get Bulk Request Status shows status 2 (processed).
Inputs
bulk_request_idintegerrequired- ID of the bulk request, from Create Bulk Request. Example: 1234.
tinyurl_bulk_request_status_getGet the progress of a bulk request.Read-onlyGet Bulk Request Status
Get the progress of a bulk request. Returns data with id, status (0 new, 1 processing, 2 processed), total, success, failed, created_at and updated_at. Use this after Create Bulk Request. Use Get Bulk Request Report once status is 2.
Inputs
bulk_request_idintegerrequired- ID of the bulk request, from Create Bulk Request. Example: 1234.
tinyurl_url_getGet one TinyURL by domain and alias.Read-onlyGet TinyURL
Get one TinyURL by domain and alias. Returns data with tiny_url, url, domain, alias, tags, archived, deleted, analytics settings, created_at and expires_at. Use this when you know the alias. Use List TinyURLs to find it.
Inputs
aliasstringrequired- Alias of the TinyURL: the part after the domain. Example: myexamplelink for https://tinyurl.com/myexamplelink.
domainstringrequired- Domain of the TinyURL, for example tinyurl.com or one of your branded domains. Example: tinyurl.com.
tinyurl_urls_countCount the account's active or archived TinyURLs, optionally by creation date or an alias or tag search.Read-onlyCount TinyURLs
Count the account's active or archived TinyURLs, optionally by creation date or an alias or tag search. Returns data.count. Use this for totals. Use List TinyURLs for the links themselves.
Inputs
typestringrequired- Which TinyURLs to list: available (active) or archived. Example: available.one of
availablearchived fromstring- Only TinyURLs created after this date-time. Example: 2025-01-01T00:00:00Z.
searchstring- Filter by alias or tag, written as alias:<text> or tag:<text>. Example: tag:campaign-q1.
tostring- Only TinyURLs created before this date-time. Example: 2025-12-31T23:59:59Z.
tinyurl_urls_listList the account's active or archived TinyURLs, optionally by creation date or an alias or tag search.Read-onlyList TinyURLs
List the account's active or archived TinyURLs, optionally by creation date or an alias or tag search. Returns data[] with each TinyURL's domain, alias, tiny_url, tags, archived, analytics settings and created_at. Use this to browse links. Use Count TinyURLs for just the number. Use Get TinyURL for one link.
Inputs
typestringrequired- Which TinyURLs to list: available (active) or archived. Example: available.one of
availablearchived fromstring- Only TinyURLs created after this date-time. Example: 2025-01-01T00:00:00Z.
searchstring- Filter by alias or tag, written as alias:<text> or tag:<text>. Example: tag:campaign-q1.
tostring- Only TinyURLs created before this date-time. Example: 2025-12-31T23:59:59Z.
tinyurl_bulk_request_createQueue a batch of TinyURL operations (create, update, change, delete, archive or unarchive), processed in the background.WriteCreate Bulk Request
Queue a batch of TinyURL operations (create, update, change, delete, archive or unarchive), processed in the background. Returns data with the bulk request id and status (0 new, 1 processing, 2 processed). Use Get Bulk Request Status to poll, then Get Bulk Request Report for per-item results.
Inputs
itemsarrayrequired- Operations to run. Each item has an operation (create, update, change, delete, archive or unarchive) plus that operation's fields: create takes url and optional domain, alias, tags, expires_at and description; update takes domain and alias plus new_ fields as in Update TinyURL; change takes domain, alias and url; delete, archive and unarchive take domain and alias. An optional metadata array is echoed back in the report. Example: [{"operation": "create", "url": "https://www.example.com/a", "alias": "bulk-a-2025"}, {"operation": "delete", "domain": "tinyurl.com", "alias": "old-link"}]
domainstring- Default domain for items that do not set one. Example: tinyurl.com.
tinyurl_url_analytics_sharing_setMake one TinyURL's analytics page public or private.WriteSet Analytics Sharing
Make one TinyURL's analytics page public or private. Returns data with the TinyURL and its analytics settings. Use Set Analytics Collection to turn collection on or off.
- Idempotent
Inputs
aliasstringrequired- Alias of the TinyURL: the part after the domain. Example: myexamplelink for https://tinyurl.com/myexamplelink.
domainstringrequired- Domain of the TinyURL, for example tinyurl.com or one of your branded domains. Example: tinyurl.com.
publicbooleanrequired- true to share the analytics publicly, false to keep them private. Example: false.
tinyurl_url_analytics_status_setTurn click analytics collection on or off for one TinyURL.WriteSet Analytics Collection
Turn click analytics collection on or off for one TinyURL. Returns data with the TinyURL and its analytics settings. Use Set Analytics Sharing to make the stats page public or private.
- Idempotent
Inputs
aliasstringrequired- Alias of the TinyURL: the part after the domain. Example: myexamplelink for https://tinyurl.com/myexamplelink.
domainstringrequired- Domain of the TinyURL, for example tinyurl.com or one of your branded domains. Example: tinyurl.com.
enabledbooleanrequired- true to collect click analytics, false to stop. Example: true.
tinyurl_url_archiveArchive an active TinyURL, or unarchive an archived one: the call switches its archived state.WriteArchive or Unarchive TinyURL
Archive an active TinyURL, or unarchive an archived one: the call switches its archived state. Returns data with the TinyURL, including its new archived value. Use Get TinyURL first to check archived. Archived links are listed with List TinyURLs type archived.
Inputs
aliasstringrequired- Alias of the TinyURL: the part after the domain. Example: myexamplelink for https://tinyurl.com/myexamplelink.
domainstringrequired- Domain of the TinyURL, for example tinyurl.com or one of your branded domains. Example: tinyurl.com.
tinyurl_url_createShorten a long URL into a new TinyURL, optionally with a custom alias, branded domain, tags, description and expiry.WriteCreate TinyURL
Shorten a long URL into a new TinyURL, optionally with a custom alias, branded domain, tags, description and expiry. Returns data with tiny_url, domain, alias, url, tags, analytics settings, created_at and expires_at. Use this to make one short link. Use Create Bulk Request for many at once.
Inputs
urlstringrequired- The long URL to shorten. Example: https://www.example.com/blog/2025/launch-announcement.
aliasstring- Custom alias, 5 to 30 characters on tinyurl.com (1+ on branded domains). Generated when omitted. Example: spring-launch.
descriptionstring- Description of the TinyURL, 3 to 1000 characters. Example: Spring launch email link.
domainstring- Domain for the TinyURL: tinyurl.com (default, free) or one of your branded domains. Example: tinyurl.com.
expires_atstring- When the TinyURL expires, as an ISO 8601 date-time. Leave empty for no expiry. Example: 2025-10-25 10:11:12.
tagsarray- Tags to group the TinyURL, up to 45 characters each. Example: ["campaign-q1", "email"].
tinyurl_url_long_url_changePoint an existing TinyURL at a new long URL, keeping its domain and alias.WriteChange Long URL
Point an existing TinyURL at a new long URL, keeping its domain and alias. Returns data with the updated TinyURL. Use this to redirect a link. Use Update TinyURL to change alias, tags or expiry.
- Idempotent
Inputs
aliasstringrequired- Alias of the TinyURL: the part after the domain. Example: myexamplelink for https://tinyurl.com/myexamplelink.
domainstringrequired- Domain of the TinyURL, for example tinyurl.com or one of your branded domains. Example: tinyurl.com.
urlstringrequired- New long URL the TinyURL should redirect to. Example: https://www.example.com/new-page.
tinyurl_url_updateChange a TinyURL's domain, alias, tags, description, expiry or analytics collection.WriteUpdate TinyURL
Change a TinyURL's domain, alias, tags, description, expiry or analytics collection. To change where it points, use Change Long URL. Returns data with the updated TinyURL. new_tags replaces all existing tags. Use Get TinyURL first to read the current values.
- Idempotent
Inputs
aliasstringrequired- Alias of the TinyURL: the part after the domain. Example: myexamplelink for https://tinyurl.com/myexamplelink.
domainstringrequired- Domain of the TinyURL, for example tinyurl.com or one of your branded domains. Example: tinyurl.com.
new_aliasstring- New alias. Example: promotion2026.
new_descriptionstring- New description. Example: Q2 promotion link.
new_domainstring- New domain to move the TinyURL to (tinyurl.com or a branded domain). Example: example.com.
new_expires_atstring- New expiry as an ISO 8601 date-time or duration. Example: 2026-01-31 00:00:00.
new_statsboolean- Set true to turn click analytics on, false to turn them off. Example: true.
new_tagsarray- Tags the TinyURL should have; replaces all existing tags. Example: ["campaign-q2"].
tinyurl_url_deleteDelete a TinyURL so it stops redirecting.DestructiveDelete TinyURL
Delete a TinyURL so it stops redirecting. Returns data with the deleted TinyURL. Use Archive or Unarchive TinyURL to hide a link without deleting it.
- Idempotent
Inputs
aliasstringrequired- Alias of the TinyURL: the part after the domain. Example: myexamplelink for https://tinyurl.com/myexamplelink.
domainstringrequired- Domain of the TinyURL, for example tinyurl.com or one of your branded domains. Example: tinyurl.com.
No tools match.