commercetools / commercetools/connect-payment-integration-template
Custom type key should be configurable
- Dominant language
- TypeScript
- Stars
- 10
- Forks
- 5
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 14
Description
When creating a custom type definition in post deploy then the [key](https://github.com/commercetools/connect-payment-integration-template/blob/main/processor/src/custom-types/custom-types.ts#L2) for the custom type should be configurable. If another connector already created a type definition for an entity then only that type or your type can be set and one always overwrites the other.
An example of how to create or re use an existing type can be found in [here](https://github.com/commercetools/connect-shipping-integration-ingrid/blob/d901642ce4dc6f8ee54db02b6c18c0eb2ecefe10/processor/src/connectors/actions.ts) where the key for the custom type is configurable [here](https://github.com/commercetools/connect-shipping-integration-ingrid/blob/d901642ce4dc6f8ee54db02b6c18c0eb2ecefe10/connect.yaml#L34-L37).
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with processor/src/custom-types/custom-types.ts and trace how the post-deploy flow creates the custom type. Compare the linked shipping connector's processor/src/connectors/actions.ts and connect.yaml configuration to understand how its key is supplied or reused. Done means the payment template accepts a configurable custom-type key and prevents unrelated connector types from overwriting each other.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 55/100