Players can partake in these downtime activities as written about in XGE:
Pit Fighting
Players participate in non-lethal forms of combat for money and fame. The character makes three checks: Strength (Athletics), Dexterity (Acrobatics), and a special Constitution check that has a bonus equal to a roll of the character's largest Hit Die (this roll doesn't spend that die). If desired, the character can replace one of these skill checks with an attack roll using one of the character's weapons.
The DC of these checks is randomly generated. Roll 2d10+5 to determined the DC. Players can bet on themselves, and make a return depending on their success.
0 Success - Lose bet
1 Success - Money * 1
2 Successes - Money * 1.5
3 Successes - Money * 2
Carousing
Carousing covers a workweek of fine food, strong drink, and socializing. A character can attempt to carouse among lower-, middle-, or upper-class folk. A character can carouse with the lower class for 10 gp to cover expenses, or 50 gp for the middle class. Carousing with the upper class requires 250 gp for the workweek and access to the local nobility. The character makes a Charisma (Persuasion) check using the Carousing table.
Crime
A character must spend one week and at least 25 gp gathering information on potential targets before committing the intended crime. The character must make a series of checks, with the DC for all the checks chosen by the character according to the amount of profit sought from the crime. The chosen DC can be 10, 15, 20, or 25. Successful completion of the crime yields a number of gold pieces, as shown on the Loot Value table.
Gambling
This activity requires one workweek of effort plus a stake of at least 10 gp, to a maximum of 1,000 gp or more, as you see fit. The character must make a series of checks, with a DC determined at random based on the quality of the competition that the character runs into. Part of the risk of gambling is that one never knows who might end up sitting across the table. The character makes three checks: Wisdom (Insight), Charisma (Deception), and Charisma (Intimidation). If the character has proficiency with an appropriate gaming set, that tool proficiency can replace the relevant skill in any of the checks. The DC of these checks is randomly generated.
Religious Service
Performing religious service requires access to, and often attendance at, a temple whose beliefs and ethos align with the character's. If such a place is available, the activity takes one workweek of time but involves no gold piece expenditure. At the end of the required time, the character chooses to make either an Intelligence (Religion) check or a Charisma (Persuasion) check.
Research
Typically, a character needs access to a library or a sage to conduct research. Assuming such access is available, conducting research requires one workweek of effort and at least 50 gp spent on materials, bribes, gifts, and other expenses. The character declares the focus of the research—a specific person, place, or thing. After one workweek, the character makes an Intelligence check with a +1 bonus per 50 gp spent beyond the initial 50 gp, to a maximum of +6. In addition, a character who has access to a particularly well-stocked library or knowledgeable sages gains advantage on this check. Determine how much lore a character learns using the Research Outcomes table.
Training
Receiving training in a language or tool typically takes at least ten workweeks, but this time is reduced by a number of workweeks equal to the character's Intelligence modifier (an Intelligence penalty doesn't increase the time needed). Training costs 25 gp per workweek.
Training: Hitpoints
When rolling for hitpoints there is a chance to roll under the average. Players can train to gain hitpoints up to what the average would have been. Each hitpoint takes a workweek, and costs 25gp. A Barbarian who rolls a 2 on their hit die could work 5 downtime activities to raise himself to 7. It would cost 125gp.
Work
When all else fails, an adventurer can turn to an honest trade to earn a living. This activity represents a character's attempt to find temporary work, the quality and wages of which are difficult to predict. Performing a job requires one workweek of effort. To determine how much money a character earns, the character makes an ability check: Strength (Athletics), Dexterity (Acrobatics), Intelligence using a set of tools, Charisma (Performance), or Charisma using a musical instrument. Consult the Wages table to see how much money is generated according to the total of the check.
Scribing a spell scroll
Scribing a spell scroll takes an amount of time and money related to the level of the spell the character wants to scribe, as shown in the Spell Scroll Costs table. In addition, the character must have proficiency in the Arcana skill and must provide any material components required for the casting of the spell. Moreover, the character must have the spell prepared, or it must be among the character's known spells, in order to scribe a scroll of that spell.
If the scribed spell is a cantrip, the version on the scroll works as if the caster were 1st level.