Skip to content

Add ByteType Support #224

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

Merged
merged 24 commits into from
Sep 7, 2021
Merged

Add ByteType Support #224

merged 24 commits into from
Sep 7, 2021

Conversation

choipureum
Copy link
Contributor

@choipureum choipureum commented Sep 2, 2021

related issue : #96, #143, #136

Supports byte array type. I also added unit and integrated tests.

overview:

    public class SingleByteArrayObject
    {
        public byte[] ByteArrayValue { get; set; }
    }
      "singleByteArrayObject": {
        "type": "object",
        "properties": {
          "byteArrayValue": {
            "type": "string",
            "format": "base64"
          }
        }
      }

Copy link
Contributor

@justinyoo justinyoo left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution! We need to take a further look for the byte[] support.

@choipureum choipureum requested a review from justinyoo September 3, 2021 01:52
Copy link
Contributor

@justinyoo justinyoo left a comment

Choose a reason for hiding this comment

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

Although I've left comments in many places, they are all minor changes. Would you please take a look and apply changes?

@justinyoo
Copy link
Contributor

This will also fix #97

@justinyoo justinyoo linked an issue Sep 3, 2021 that may be closed by this pull request
Copy link
Contributor

@justinyoo justinyoo left a comment

Choose a reason for hiding this comment

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

Would you also change this as well?

@choipureum choipureum requested a review from justinyoo September 6, 2021 00:51
Copy link
Contributor

@justinyoo justinyoo left a comment

Choose a reason for hiding this comment

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

Almost there! Can you add more tests for the request body?

@choipureum choipureum requested a review from justinyoo September 7, 2021 12:19
Copy link
Contributor

@justinyoo justinyoo left a comment

Choose a reason for hiding this comment

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

Let's add more integration test codes for the request body taking the byte array!

@choipureum choipureum requested a review from justinyoo September 7, 2021 13:08
Copy link
Contributor

@justinyoo justinyoo left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks for the contribution!

@justinyoo justinyoo merged commit c1441e0 into Azure:main Sep 7, 2021
@justinyoo
Copy link
Contributor

Now, this extension supports many content types including:

  • Binary contents like application/octet-stream, image/png, etc
  • multipart/form-data
  • application/x-www-urlencode

@justinyoo justinyoo added enhancement New feature or request v0.9.0 labels Sep 7, 2021
@choipureum choipureum deleted the addByteType branch October 1, 2021 06:51
@AllTaken
Copy link

Does this allow to set "format: binary" somehow?

@sergiojrdotnet
Copy link

@AllTaken I would like to know too, my endpoint returns a pdf file and base64 format does not make any sense in this case

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
4 participants