Microsoft Customer Agreement Bulk Attestation Tool

Appropriate roles: Admin agent | Sales agent

Applicable clouds: Global

The Microsoft Customer Agreement Bulk Attestation Tool enables partners to confirm the acceptance of the Microsoft Customer Agreement on behalf of their customers. This tool is designed to help partners who have many customers and fall in scope of the Microsoft Customer Agreement refresh effort.

The bulk attestation tool has several features:

  • Open-source .NET console tool using an open-source .NET SDK (7.0)
  • Supports the comma-separated (.csv) file format for setting up bulk attestations
  • No code changes are required, and can be utilized with a .NET command
  • Code is extensible and can be enhanced as partners deem fit
  • Extensive logging can help troubleshoot issues

This tool is for direct bill partners and indirect providers transacting through the CSP Program.

Prerequisites

  • Partner accounts must be enabled for multifactor authentication (MFA) as Customer workspace APIs enforce MFA. You can add MFA by following the instructions in Mandating MFA for your partner tenant.

  • Ensure you have the .NET 7.0 SDK installed on the host machine.

  • Configure a native application in Partner Center:

    1. In Partner Center, select Settings (gear icon) > Account settings.

      Screenshot of the Partner Center settings menu, with Account settings highlighted.

    2. Select the App management page.

    3. Select + Add new native app. A new application is created for you. Copy the Application ID and keep it handy.

      Screenshot of the App Management page, with Add new native app highlighted.

      You should now be able to see the newly created application in Azure portal under Azure Entra ID > App registrations.

      Screenshot of the App registrations page, with Partner Center Native app highlighted.

    4. Use the Authentication tab to add a platform for Mobile and desktop applications.

      Screenshot of the Authentication page, with the 'Configure platforms' flyout open, and Mobile and desktop applications highlighted.

    5. Configure the http://localhost and other redirect URIs for the application.

      Screenshot of the 'Configure desktop + devices' page, with Redirect URIs shown.

    6. Once saved, verify the redirect URIs are listed under the Mobile and desktop applications platform, and that ID tokens is selected under Implicit grant and hybrid flows.

    To learn more, see Partner Center authentication.

Run the Microsoft Customer Agreement Bulk Attestation Tool

  1. Go to the Partner Center DotNet Samples on GitHub, and select Code > Download ZIP to extract the files into a local folder. In the extracted folder will be a subfolder named Microsoft Customer AgreementRefreshBulkAttestationCLITool. You're now ready to run the tool.

  2. Open the command prompt and navigate to the folder where you extracted the files.

  3. Run the following command: dotnet run. If necessary, wait for the build to complete.

  4. Provide your application ID and user principal name (UPN). Use the native application ID set up that you created, and your UPN.

  5. Sign in to your account with MFA.

  6. The tool shows the following options, which are described in the following sections:

    Screenshot of the Bulk Attestation Tool options to fetch or update customer agreement records.

Authentication

After you launch the tool, it attempts to fetch an authentication token silently. Should it fail, an interactive mode triggers, and a browser window opens to ask you to sign-in. Use the same credentials that you use when signing in to Partner Center.

After successful authentication, the following message appears. Close the browser window and return to the console application.

Screenshot of the browser localhost window, with a message that it's OK to close the browser tab.

Scenarios

Prior to using the tool, note:

  • The tool isn't designed to provide details for direct customer acceptance details
  • The tool has input data validation at parity with the Partner Center Create Agreement API

There are two scenarios that the tool supports: fetch customer agreement records and update customer agreement records.

Fetch customer agreement records

This operation uses the Partner Center API to fetch all the customer agreement records that are in scope of the Microsoft Customer Agreement Refresh for your partner tenant. The tool then saves the records to a CSV file (CustomerAgreementRecords.csv) in a path of your choosing.

If a customer agreement has been refreshed (either via the bulk tool, Partner Center Portal, or the Create Agreement API), the record won't be returned in the fetch operation. It also won't be included in the CSV file. All records that are returned in the CSV file are actionable and must be updated.

Example of running the fetch operation:

Screenshot of the Bulk Attestation Tool, with a message that it fetched 14 customer agreement records from Partner Center.

Part of the returned fields includes the customer contact details for the last partner-confirmed agreement. If a previous attestation (agreement confirmed by the partner on behalf of the customer) existed, the customer contact details for that confirmation are shown in the following fields. Otherwise, they'll be blank. These details are provided for your convenience in case that the accepting agent is the same at the time of refreshing the acceptance, but otherwise should be updated to accurately reflect the acceptance details. An email notification will be dispatched to the customer using the provided email once the partner confirms the acceptance of the Microsoft Customer Agreement.

The CSV file contains the following fields:

  • Customer Tenant ID: The customer's tenant/Microsoft ID
  • Customer Contact Details:
    • FirstName: The first name of the accepting agent in the customer's organization of the last partner-confirmed agreement
    • LastName: The last name of the accepting agent in the customer's organization of the last partner-confirmed agreement
    • Email: The email address of the accepting agent in the customer's organization of the last partner-confirmed agreement
    • PhoneNumber: The phone number of the accepting agent in the customer's organization of the last partner-confirmed agreement
    • LastAgreementDate: The datetime of the last partner-confirmed agreement
  • Partner Attestation Completed: A Boolean value indicating whether the customer agreement record should be updated by the bulk tool. This field is set to False by default, and should be set to True for all records that you want to update.
  • Customer Account Link: A non-operational field that is used to display a direct link to the customer's account page in Partner Center. The tool populates this field, but isn't used for any operations and shouldn't be modified.

Example CSV file:

Screenshot of sample output from the CSV file.

Tip

Prior to triggering the first update operation, it is recommended you save a copy of the customer agreement records returned to another location for your own records. Once customer agreement records are updated successfully, they are treated as resolved and will not be returned in the future.

Update customer agreement records

This operation uses the Partner Center API to update the customer agreement records from the CSV file created by the fetch operation.

Prior to updating a customer agreement record, ensure that the customer contact details for the accepting agent in the customer's organization are accurate and up-to-date. To do this, update the following fields in the CSV file:

  • FirstName
  • LastName
  • Email
  • PhoneNumber (optional)

The agreement datetime will be populated automatically in Partner Center.

To mark a customer agreement record to update, set the Partner Attestation Completed field to True for the record in the CSV file. The tool only processes records that have this field set to True.

Example of updating the CSV file for the top 2 customers returned from the fetch operation:

Screenshot of sample output from the CSV file, where Partner Attestation Completed is True.

After you mark the customer agreement records that you want to update, save and close the CSV file, and trigger the update operation from the tool menu. The tool prompts you to provide the path to the CSV file. After it successfully parses the records, the tool displays how many actionable records it found and starts to dispatch update operations.

For large amounts of agreements, the updates can take some time because the maximum agreements to update per dispatched call is 500. The update operations happen asynchronously once reaching Partner Center. You can expect a delay from when the tool completes the update operations and when the customer agreement records are updated in Partner Center.

Example of running the update operation:

Screenshot of the Bulk Attestation Tool, with a message saying that it processed two actionable records, and completed the operation.