You do not build a Partner WSDL by hand. Salesforce generates it for you from Setup, and you download the file once per API version, then feed it to your SOAP toolkit to generate client stubs. Here is the path in a Lightning org.
- Open the API page in Setup
From Setup, type API into the Quick Find box and click API. This page lists every WSDL and client certificate Salesforce can generate for your org.
- Generate the Partner WSDL
Click Generate Partner WSDL. Salesforce builds a generic, loosely typed WSDL that does not reference your org's specific objects or fields, so the same file works against any org.
- Save the file locally
Right-click the generated page and save it with a .wsdl extension. Keep it under version control alongside your client so you know exactly which API version your stubs were built from.
- Generate client stubs
Feed the .wsdl into your platform's SOAP tooling (for example wsimport for Java or the Force.com WSC) to produce the sObject and binding classes your application calls.
Produces the generic, loosely typed file for cross-org and ISV use. Download and consume it once per API version.
Produces the strongly typed file bound to this org's exact schema. Choose this for a single, known org instead of the Partner WSDL.
The user generating or calling the WSDL needs API Enabled. Without it, SOAP API access is blocked regardless of which WSDL you downloaded.
- Because field values arrive as strings, your code must parse and format types (dates, numbers, booleans) itself rather than relying on typed properties.
- Never assume a field exists. Call describeSObjects at runtime to confirm objects and fields before reading or writing them across unknown orgs.
- Use the fieldsToNull array to clear a field with the Partner WSDL; sending an empty value in the fields collection does not reliably null it out.
- The generated WSDL is pinned to one API version. Regenerate it deliberately when you want newer features, not in reaction to a customer's schema change.