Git Product home page Git Product logo

Comments (5)

FrimIdan avatar FrimIdan commented on May 27, 2024

Hi @brasseld thanks for reaching out and happy to hear that you want to add Gravitee.io as a new traffic source.

We definitely need to add a new doc describing how people can add more traffic sources, for now I can point you to the plugins API (go client code is already generated here).
For an example how/what info is expected you can look at the current plugins implementations (tapper, kong).

There is also a section in the helm values to enable each traffic source with a specific values for each one.

from apiclarity.

brasseld avatar brasseld commented on May 27, 2024

Thanks for your feedback @FrimIdan

It's probably me doing something wrong (or maybe I missed something) but when I try to Postman for creating (post) a new telemetry, I'm always getting a 400 response:

{
    "code": 400,
    "message": "parsing body body from \"\" failed, because illegal base64 data at input byte 3"
}

What I'm trying to POST to /api/telemetry:

{
    "requestID": "123456789",
    "scheme": "HTTP",
    "destinationAddress": "localhost:8082",
    "destinationNamespace": "default",
    "sourceAddress": "localhost:8082",
    "request": {
        "method": "GET",
        "path": "/api",
        "host": "localhost",
        "common": {
            "version": "1",
            "headers": [
                {
                    "key": "Content-Type",
                    "value": "application/json"
                }
            ],
            "body": "sit sint",
            "TruncatedBody": true,
            "time": "1988-12-08T22:59:33.988Z"
        }
    },
    "response": {
        "statusCode": "200",
        "common": {
            "version": "1",
            "headers": [
                {
                    "key": "cupidatat s",
                    "value": "irure sint in est"
                },
                {
                    "key": "aliqua in Lorem qui dolor",
                    "value": "aute labore"
                }
            ],
            "body": "aliquip irure enim",
            "TruncatedBody": true,
            "time": "1992-07-24T18:11:57.341Z"
        }
    }
}

(This has been mainly generated by Postman by importing the swagger you provided me).

Thanks for your feedback.

from apiclarity.

brasseld avatar brasseld commented on May 27, 2024

Ok, seems that the error message is quite clear body.body has to be base64 encoded (would be great to update the swagger to add a description about it :) )

Now fighting with a 500 status code from clarity...

from apiclarity.

brasseld avatar brasseld commented on May 27, 2024

Got it from logs, only base64 of json payload is supported :)

from apiclarity.

FrimIdan avatar FrimIdan commented on May 27, 2024

Ok, seems that the error message is quite clear body.body has to be base64 encoded (would be great to update the swagger to add a description about it :) )

format: 'byte' is not clear enough I agree - we didn't though about it since the generated client is handling that.
Fill free to open a PR to add descriptions where you think it will be helpful for others.

from apiclarity.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.