A current rating is not a fixed property. It is the current at which the connector heats itself by a limited amount above its surroundings, tested at a stated ambient temperature, while staying under the maximum temperature of its plastic and contact materials.
When the surrounding air is hotter than the test ambient, there is less temperature headroom left for the heat the contacts generate (P = I²R). To stay under the same maximum temperature, the allowed current has to be lower. That reduction is called derating.
Many manufacturers publish a derating curve in the datasheet. If yours does, use it. If it does not, a calculator can give an estimate, but it is only a planning figure: confirm the final number against the manufacturer data, especially when many contacts carry current at the same time.



