You can use the populate parameter.
Ignoring that icon is placed within a component, you can just do
GET:/api/content-type?populate[icon][fields][]=url&populate[icon][fields][]=name&populate[icon][fields][]=altText
to fetch just the desired fields.
Adjusting for the component you’d just nest the params one more level.