Skip to content

[Do not merge] - Python - DEVTOOLING-997 #1019

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

Closed
wants to merge 8 commits into from

Conversation

sureshperiyappan
Copy link
Collaborator

@sureshperiyappan sureshperiyappan commented Mar 25, 2025

  1. HTTP Client injection for Python SDK.
  2. Proxy Enablement.
  3. MTLS Enablement.

Testing completed:
https://jenkins.ininica.com/job/build-platform-sdks-internal-pipeline/5884/

ReadMe yet to be updated

@sureshperiyappan sureshperiyappan changed the title DEVTOOLING-997 [Do not merge] DEVTOOLING-997 Mar 27, 2025
@sureshperiyappan sureshperiyappan changed the title [Do not merge] DEVTOOLING-997 [Do not merge] - Python - DEVTOOLING-997 Mar 27, 2025
# Authenticate with client credentials and pass the apiclient instance into the usersapi
print("Authenticating with client credentials...")
SdkTests_mtls.apiclient_mtls = PureCloudPlatformClientV2.api_client.ApiClient()
SdkTests_mtls.apiclient_mtls.set_gateway("locahlost","https",4027,"login","api")
Copy link
Collaborator

Choose a reason for hiding this comment

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

this could be the problem for 404 error, "localhost"

Copy link
Collaborator Author

@sureshperiyappan sureshperiyappan Apr 1, 2025

Choose a reason for hiding this comment

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

@themooks
Copy link
Collaborator

Some explanations on how to use (Client Injection) or set (Proxy, MTLS) these new capabilities need to be added to the /resources/sdk/purecloudpython/templates/README.mustache file.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Why is this change done in this new rest.py file and not in the templates/rest.mustache one?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

For the following reason the "templates/rest.mustache" has been move to "extensions/rest.py":
1)The relocation of "templates/rest.mustache" to "extensions/rest.py" aligns with the Client Injection approach, positioning the default HTTP client "rest.mustache" within the extensions directory, as discussed with @HemanthDogiparthi12 .
2)Given that "rest.mustache" lacks any template-specific code, its placement within the extensions folder is logical.
3)Due to the absence of other code dependencies, this move is not anticipated to cause any adverse effects.
4)Although unlikely, there's a potential for regression if any client implementation directly references this file.

Copy link
Collaborator

Choose a reason for hiding this comment

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

The OpenAPI Generator for purecloudpython is expecting it

@sureshperiyappan
Copy link
Collaborator Author

Separate PR #1060 has been put for MTLS changes alone

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.

3 participants