Rinse the chicken inside and out and pat it dry with paper towels. Place the chicken in a large pot.
Cut 3 of the carrots and 2 of the celery stalks into 1-inch pieces. Quarter the onion. Add the cut vegetables to the pot with the salt, peppercorns, and enough cold water to cover (about 8 cups). Bring to a boil. Reduce heat and simmer, skimming any foam that rises to the top, until the chicken is cooked through, about 30 minutes. Transfer the chicken to a bowl and let cool.
Strain the broth, discarding the vegetables. Return the broth to the pot.
Thinly slice the remaining carrots and celery. Add them plus the tomatoes to the broth and simmer until tender, about 10 minutes.
When the chicken is cool enough to handle, shred the meat. Add it plus the spinach and basil to the soup. Cook until the spinach wilts, about 1 minute. Ladle into individual bowls.