Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(FN-3163): add get or create customer endpoint #1132

Merged
merged 177 commits into from
Jan 17, 2025

Conversation

natdeanlewissoftwire
Copy link
Contributor

@natdeanlewissoftwire natdeanlewissoftwire commented Jan 8, 2025

Introduction ✏️

As part of the CCM project, if a customer doesn't exist in SF, we are automatically creating it rather than relying on the manual process currently undertaken by Business Support Group. DTFS will send requests to a new customer/salesforce endpoint for MDM to create a customer in Salesforce. Technical documentation of this process is here

Resolution ✔️

This PR adds a "get or create" salesforce customer endpoint that does a few things:
Checks for an existing customer via Informatica. If none exists (or we return a legacy one):
Generates a URN from NUMGEN (if there isn't already one returned from a legacy record by Informatica, in which case we just use that).
Calls the Dun and Bradstreet service to get a customer's DUNS number.
POSTs these along with the customer name and Companies House Number to Salesforce.
Returns the customer, including the URN to DTFS for deal submission.

Miscellaneous ➕

A tweak to the NUMGEN regex to allow customer URN creation, and a typo fix.

abhi-markan
abhi-markan previously approved these changes Jan 16, 2025
Copy link
Contributor

@abhi-markan abhi-markan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍🏼

Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
2 Security Hotspots

See analysis details on SonarQube Cloud

@abhi-markan abhi-markan merged commit 73a5b2a into main Jan 17, 2025
18 of 19 checks passed
@abhi-markan abhi-markan deleted the feat/FN-3163/create-customer-endpoint branch January 17, 2025 09:46
abhi-markan added a commit that referenced this pull request Jan 17, 2025
🤖 I have created a release *beep* *boop*
---


##
[1.23.0](v1.22.2...v1.23.0)
(2025-01-17)


### Features

* **FN-3163:** add get or create customer endpoint
([#1132](#1132))
([73a5b2a](73a5b2a))
* **FN-3163:** automate new DTFS customer creation in Salesforce (D&B
service only)
([#1130](#1130))
([8a6403c](8a6403c))


### Bug Fixes

* **deps:** replace all
([#1133](#1133))
([8454434](8454434))
* **deps:** update all to v4 (major)
([#1148](#1148))
([e9be73b](e9be73b))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants