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

wip: add support for oauth #412

Closed
wants to merge 144 commits into from
Closed

wip: add support for oauth #412

wants to merge 144 commits into from

Conversation

mtuchi
Copy link
Collaborator

@mtuchi mtuchi commented Oct 17, 2023

Summary

Add a OAuth2 support

Issues #410

Review Checklist

Before merging, the reviewer should check the following items:

  • Does the PR do what it claims to do?
  • Are there any unit tests? Should there be?
  • Is there a changeset associated with this PR? Should there be? Note that
    dev only changes don't need a changeset.

@mtuchi mtuchi linked an issue Oct 17, 2023 that may be closed by this pull request
mtuchi and others added 28 commits January 24, 2024 14:03
* add toUTF8 function

* add changeset

* add unit test

* fix typo

* update ast

* salesforce: fix any-ascii import

* salesforce: fix any-ascii import

* salesforce: add initialiser to not blow up simple-ast

* bump version and update changelog

---------

Co-authored-by: Joe Clark <[email protected]>
* Initial commit for Azure Blog Storage adaptor

* Cleanup log messages

* Small improvement to README

* Updating per josephjclark's review

* Resolving issues from review:
- Updating configuration schema
- Better handling of function options
- Adding support for
- Bumped to 1.0

* Update lockfile

* azure-storage: fill out initial changelog manuall

* azure-storage: lint

* azure-storage: fix linting again

* build ast

---------

Co-authored-by: Benson Miller <[email protected]>
Co-authored-by: Emmanuel Evance <[email protected]>
* expandreference in parseXML

* add changeset

* bump version and update changelog
* Remove writeOnly field and add format field

* Add changeset

* bump version and update changelog

---------

Co-authored-by: Emmanuel Evance <[email protected]>
* Remove regex validation pattern

* Bump minLength to 1 as all other adaptors

* Add changeset

* bump version and update changelog

---------

Co-authored-by: Emmanuel Evance <[email protected]>
Run publish instead
this commit should run CI tests but not publish
* wip add request util

* wip: using undici client

add tests

* wip: add mock agent

* wip: more tests

* wip: test options

* update undici

* add changeset

* fix typo

* improve errorMap

* fix undici

* remove method in assertOK

* improve signature

* improve assertOK

add tests for baseUrl option and errorMap

* throw an error if response code match errorMap

* remove duplicate property value

* test if body is string and add default body timeout

* wip: improvements in util

* remove util.js

* restructure util files

* add recursive option

* common: restructure build output

* remove comments

* update isValidHttpUrl

minor improvements

* rename a test

* wip: parseAs

* wip: update mockClient func

* wip: refactor test

* improve tests

* better url parsing

* remove comment

* update response body

* update content type check

* remove comments

* remove headers

* common: adjust import

* common: tweak request docs

* wip: refactor

* wip: refactor test

* wip: post tests

* wip: skip failed tests

* wip: tests

* common: updated unit tests

* common: fix test

* add request helper function

* wip: clean up tests

* add support for successcode in errorMap

* fix broken test

* remove undici skip test

* remove cookies handling

* remove unused packages

* improve aut parsing

* wip: followRedirect

* wip: follow redirect

* wip: form-data

* http: update formdata tests

* http: remove rediect test

* improve logging

* clean up unused packages and add http-status-codes

* clean up deadcode

* improve form-data test

* add changeset

* remove common changeset

* improvements

* add duration

* add method and url to response body

* add support for tls

* improve jsdoc

* update changelog

* add requestBodyType function

This function assert that body type and convert a plan json to a string

* remove JSON.stringify

* add unit test for requestBodyType

* add helpers for http server

* update dependencies

* remove http helpers

* add intergration test

* add responseUrl function

This function will return history url if found or request url

* fix test

* add koa and koa-sslify

* add certificates for testing

* update tests

* move server into integration file

* add server logic

* update https port

it turns out in ubuntu any port < 1024 needs root permission

* use nodes https module

remove koa implementation

* http: move request helper into utils

* common: typo in docs

* http: fix headers and start updating tests

* package lock

* test updates

* common: rename http helper response touse statusCode and statusMessage. Also remove the response url.

* http: update tests

* http: update tests

* common: restore url to the response object

A version of it anyway

* http: refactor response log

* common: update http error message

* http: update to use new  error handling

* http: tidy ups

* http: docs

* http,common:docs

* http: undocument maxRedirects

Not willing to commit to it tbh

* http: light refactor

* common: another light refactor

* lock node version in ci

* common: restore default error map

* http: fix form processing

* http: remove file extension from import

* common: deprecate old http functions

Shoud print a warning in dev mode, but not in prod (platform or lightning)

* http: expose a general request operation

* common: update release notes

* bump versions

* lockfile

* Update auto-generated documentation.

* docs: improve markdown templates

* tools: update docs

* Update http docs

* http: update request example

* remove build artefacts

* http,common: move some http stuff into common utils

* Update template

* template: update to use new helpers

* template: remove unused code

* readme

* Update template

Template should be locked at 1.0.0 and never published

* common: don't print output if you're given a bad response

* common: better url building

* http: remove custom tags from docs

* common: tweak URL parsing rules

* common: better url reporting in errors

* common: fix url parsing

whoops

* common: don't use URL.parse

* add linting for undeclared variables

Fixes issues in azure-storage, common, http, magpi, mailchimp, mongodb, resourcemap and twilio

* bump versions

* common: better handling of error responses in http

* http: update changelog

* http: changelog fixes

---------

Co-authored-by: Emmanuel Evance <[email protected]>
@mtuchi mtuchi closed this Jan 24, 2024
@mtuchi mtuchi deleted the 410-sf-oauth-support branch January 24, 2024 11:07
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.

salesforce: oauth support for api-only integration users
5 participants