DIYgod/RSSHub · error · InvalidParameterError

This profile or page does not exist.

Error message

This profile or page does not exist.

What it means

getAccountByUsername queries the Fansly `/account` endpoint with the supplied username and caches the result under `fansly:account:<username>`. If the response array is empty the handler throws InvalidParameterError. Because the negative result is cached, a later retry with the corrected name works, but a typo can be masked until the cache entry expires.

Source

Thrown at lib/routes/fansly/utils.tsx:29

const findAccountById = (accountId, accounts) => {
    const account = accounts.find((account) => account.id === accountId);
    return {
        displayName: account.displayName,
        username: account.username,
    };
};

const getAccountByUsername = (username) =>
    cache.tryGet(`fansly:account:${username.toLowerCase()}`, async () => {
        const { data: accountResponse } = await got(`${apiBaseUrl}/api/v1/account`, {
            searchParams: {
                usernames: username,
                'ngsw-bypass': true,
            },
        });

        if (!accountResponse.response.length) {
            throw new InvalidParameterError('This profile or page does not exist.');
        }

        return accountResponse.response[0];
    });

const getTimelineByAccountId = async (accountId) => {
    const { data: timeline } = await got(`${apiBaseUrl}/api/v1/timelinenew/${accountId}`, {
        searchParams: {
            before: 0,
            after: 0,
            wallId: '',
            contentSearch: '',
            'ngsw-bypass': true,
        },
    });

    return timeline.response;
};

View on GitHub (pinned to bed535e087)

Solutions

  1. Verify the exact username on fansly.com.
  2. If you previously tried a wrong name, remember the negative lookup is cached — wait for expiry or clear the `fansly:account:<wrong>` cache key.
  3. Use the account's current display URL as the source of truth for the slug.
Defensive patterns

Strategy: validation

Validate before calling

async function fanslyUserExists(username: string): Promise<boolean> {
  const { data } = await got(`${apiBaseUrl}/api/v1/account`, { searchParams: { usernames: username, 'ngsw-bypass': true } });
  return data.response.length > 0;
}

Try / catch

try {
  await getAccountByUsername(username);
} catch (e) {
  // clear the cached negative lookup before retrying with a corrected name
  cache.tryGet(`fansly:account:${username.toLowerCase()}`, async () => { throw e; });
}

Prevention

When it happens

Trigger: `/fansly/user/<username>` where the username has no Fansly account; the account was deleted or renamed.

Common situations: Typo in the username; the creator renamed their account; a stale cached 'not found' result.

Related errors


AI-assisted analysis of DIYgod/RSSHub@bed535e087 (2026-08-12). Data as JSON: /api/errors/238254432a7ebda2. Report an issue: GitHub.