After leaving public office, Foster remained in Washington and invented a new type of legal practice, lobbying for large "corporations seeking favors in Washington and chances to expand abroad." Foster also used his government and political contacts to secure legal fees as counsel to several foreign legations. He also continued to serve Ppresidents part-time on diplomatic missions. As such, Foster negotiated trade agreements with eight countries, brokered a treaty with Britain and Russia concerning seal hunting in the Bering Sea,l and negotiated the Treaty of Shimonoseki of 1895, technically as legal consultant and commissioner for the Qing Dynasty, in which China recognized Korea's independence and ceded Taiwan to the victorious Japanese after the First Sino-Japanese War.