All URIs are relative to https://api.reveng.ai
| Method | HTTP request | Description |
|---|---|---|
| CreateAiDecompilationComment | Post /v2/functions/{function_id}/ai-decompilation/comments | Create a comment for this function |
| CreateAiDecompilationTask | Post /v2/functions/{function_id}/ai-decompilation | Begins AI Decompilation Process |
| DeleteAiDecompilationComment | Delete /v2/functions/{function_id}/ai-decompilation/comments/{comment_id} | Delete a comment |
| GetAiDecompilationComments | Get /v2/functions/{function_id}/ai-decompilation/comments | Get comments for this function |
| GetAiDecompilationRating | Get /v2/functions/{function_id}/ai-decompilation/rating | Get rating for AI decompilation |
| GetAiDecompilationTaskResult | Get /v2/functions/{function_id}/ai-decompilation | Polls AI Decompilation Process |
| GetAiDecompilationTaskStatus | Get /v2/functions/{function_id}/ai-decompilation/status | Check the status of a function ai decompilation |
| UpdateAiDecompilationComment | Patch /v2/functions/{function_id}/ai-decompilation/comments/{comment_id} | Update a comment |
| UpsertAiDecompilationRating | Patch /v2/functions/{function_id}/ai-decompilation/rating | Upsert rating for AI decompilation |
BaseResponseCommentResponse CreateAiDecompilationComment(ctx, functionId).FunctionCommentCreateRequest(functionCommentCreateRequest).Execute()
Create a comment for this function
package main
import (
"context"
"fmt"
"os"
revengai "github.com/RevEngAI/sdk-go/v3"
)
func main() {
functionId := int32(56) // int32 |
functionCommentCreateRequest := *revengai.NewFunctionCommentCreateRequest("Content_example") // FunctionCommentCreateRequest |
configuration := revengai.NewConfiguration()
apiClient := revengai.NewAPIClient(configuration)
resp, r, err := apiClient.FunctionsAIDecompilationAPI.CreateAiDecompilationComment(context.Background(), functionId).FunctionCommentCreateRequest(functionCommentCreateRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FunctionsAIDecompilationAPI.CreateAiDecompilationComment``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CreateAiDecompilationComment`: BaseResponseCommentResponse
fmt.Fprintf(os.Stdout, "Response from `FunctionsAIDecompilationAPI.CreateAiDecompilationComment`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| functionId | int32 |
Other parameters are passed through a pointer to a apiCreateAiDecompilationCommentRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
functionCommentCreateRequest | FunctionCommentCreateRequest | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponse CreateAiDecompilationTask(ctx, functionId).Execute()
Begins AI Decompilation Process
package main
import (
"context"
"fmt"
"os"
revengai "github.com/RevEngAI/sdk-go/v3"
)
func main() {
functionId := int64(789) // int64 | The ID of the function for which we are creating the decompilation task
configuration := revengai.NewConfiguration()
apiClient := revengai.NewAPIClient(configuration)
resp, r, err := apiClient.FunctionsAIDecompilationAPI.CreateAiDecompilationTask(context.Background(), functionId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FunctionsAIDecompilationAPI.CreateAiDecompilationTask``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CreateAiDecompilationTask`: BaseResponse
fmt.Fprintf(os.Stdout, "Response from `FunctionsAIDecompilationAPI.CreateAiDecompilationTask`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| functionId | int64 | The ID of the function for which we are creating the decompilation task |
Other parameters are passed through a pointer to a apiCreateAiDecompilationTaskRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponseBool DeleteAiDecompilationComment(ctx, commentId, functionId).Execute()
Delete a comment
package main
import (
"context"
"fmt"
"os"
revengai "github.com/RevEngAI/sdk-go/v3"
)
func main() {
commentId := int32(56) // int32 |
functionId := int32(56) // int32 |
configuration := revengai.NewConfiguration()
apiClient := revengai.NewAPIClient(configuration)
resp, r, err := apiClient.FunctionsAIDecompilationAPI.DeleteAiDecompilationComment(context.Background(), commentId, functionId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FunctionsAIDecompilationAPI.DeleteAiDecompilationComment``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `DeleteAiDecompilationComment`: BaseResponseBool
fmt.Fprintf(os.Stdout, "Response from `FunctionsAIDecompilationAPI.DeleteAiDecompilationComment`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| commentId | int32 | ||
| functionId | int32 |
Other parameters are passed through a pointer to a apiDeleteAiDecompilationCommentRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponseListCommentResponse GetAiDecompilationComments(ctx, functionId).Execute()
Get comments for this function
package main
import (
"context"
"fmt"
"os"
revengai "github.com/RevEngAI/sdk-go/v3"
)
func main() {
functionId := int32(56) // int32 |
configuration := revengai.NewConfiguration()
apiClient := revengai.NewAPIClient(configuration)
resp, r, err := apiClient.FunctionsAIDecompilationAPI.GetAiDecompilationComments(context.Background(), functionId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FunctionsAIDecompilationAPI.GetAiDecompilationComments``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetAiDecompilationComments`: BaseResponseListCommentResponse
fmt.Fprintf(os.Stdout, "Response from `FunctionsAIDecompilationAPI.GetAiDecompilationComments`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| functionId | int32 |
Other parameters are passed through a pointer to a apiGetAiDecompilationCommentsRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
BaseResponseListCommentResponse
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponseGetAiDecompilationRatingResponse GetAiDecompilationRating(ctx, functionId).Execute()
Get rating for AI decompilation
package main
import (
"context"
"fmt"
"os"
revengai "github.com/RevEngAI/sdk-go/v3"
)
func main() {
functionId := int64(789) // int64 | The ID of the function for which to get the rating
configuration := revengai.NewConfiguration()
apiClient := revengai.NewAPIClient(configuration)
resp, r, err := apiClient.FunctionsAIDecompilationAPI.GetAiDecompilationRating(context.Background(), functionId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FunctionsAIDecompilationAPI.GetAiDecompilationRating``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetAiDecompilationRating`: BaseResponseGetAiDecompilationRatingResponse
fmt.Fprintf(os.Stdout, "Response from `FunctionsAIDecompilationAPI.GetAiDecompilationRating`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| functionId | int64 | The ID of the function for which to get the rating |
Other parameters are passed through a pointer to a apiGetAiDecompilationRatingRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
BaseResponseGetAiDecompilationRatingResponse
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponseGetAiDecompilationTask GetAiDecompilationTaskResult(ctx, functionId).Summarise(summarise).GenerateInlineComments(generateInlineComments).Execute()
Polls AI Decompilation Process
package main
import (
"context"
"fmt"
"os"
revengai "github.com/RevEngAI/sdk-go/v3"
)
func main() {
functionId := int64(789) // int64 | The ID of the function being decompiled
summarise := true // bool | Generate a summary for the decompilation (optional) (default to true)
generateInlineComments := true // bool | Generate inline comments for the decompilation (only works if summarise is enabled) (optional) (default to true)
configuration := revengai.NewConfiguration()
apiClient := revengai.NewAPIClient(configuration)
resp, r, err := apiClient.FunctionsAIDecompilationAPI.GetAiDecompilationTaskResult(context.Background(), functionId).Summarise(summarise).GenerateInlineComments(generateInlineComments).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FunctionsAIDecompilationAPI.GetAiDecompilationTaskResult``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetAiDecompilationTaskResult`: BaseResponseGetAiDecompilationTask
fmt.Fprintf(os.Stdout, "Response from `FunctionsAIDecompilationAPI.GetAiDecompilationTaskResult`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| functionId | int64 | The ID of the function being decompiled |
Other parameters are passed through a pointer to a apiGetAiDecompilationTaskResultRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
summarise | bool | Generate a summary for the decompilation | [default to true] generateInlineComments | bool | Generate inline comments for the decompilation (only works if summarise is enabled) | [default to true]
BaseResponseGetAiDecompilationTask
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponseFunctionTaskResponse GetAiDecompilationTaskStatus(ctx, functionId).Execute()
Check the status of a function ai decompilation
package main
import (
"context"
"fmt"
"os"
revengai "github.com/RevEngAI/sdk-go/v3"
)
func main() {
functionId := int64(789) // int64 | The ID of the function being checked
configuration := revengai.NewConfiguration()
apiClient := revengai.NewAPIClient(configuration)
resp, r, err := apiClient.FunctionsAIDecompilationAPI.GetAiDecompilationTaskStatus(context.Background(), functionId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FunctionsAIDecompilationAPI.GetAiDecompilationTaskStatus``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetAiDecompilationTaskStatus`: BaseResponseFunctionTaskResponse
fmt.Fprintf(os.Stdout, "Response from `FunctionsAIDecompilationAPI.GetAiDecompilationTaskStatus`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| functionId | int64 | The ID of the function being checked |
Other parameters are passed through a pointer to a apiGetAiDecompilationTaskStatusRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
BaseResponseFunctionTaskResponse
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponseCommentResponse UpdateAiDecompilationComment(ctx, commentId, functionId).CommentUpdateRequest(commentUpdateRequest).Execute()
Update a comment
package main
import (
"context"
"fmt"
"os"
revengai "github.com/RevEngAI/sdk-go/v3"
)
func main() {
commentId := int32(56) // int32 |
functionId := int32(56) // int32 |
commentUpdateRequest := *revengai.NewCommentUpdateRequest("Content_example") // CommentUpdateRequest |
configuration := revengai.NewConfiguration()
apiClient := revengai.NewAPIClient(configuration)
resp, r, err := apiClient.FunctionsAIDecompilationAPI.UpdateAiDecompilationComment(context.Background(), commentId, functionId).CommentUpdateRequest(commentUpdateRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FunctionsAIDecompilationAPI.UpdateAiDecompilationComment``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateAiDecompilationComment`: BaseResponseCommentResponse
fmt.Fprintf(os.Stdout, "Response from `FunctionsAIDecompilationAPI.UpdateAiDecompilationComment`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| commentId | int32 | ||
| functionId | int32 |
Other parameters are passed through a pointer to a apiUpdateAiDecompilationCommentRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
commentUpdateRequest | CommentUpdateRequest | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponse UpsertAiDecompilationRating(ctx, functionId).UpsertAiDecomplationRatingRequest(upsertAiDecomplationRatingRequest).Execute()
Upsert rating for AI decompilation
package main
import (
"context"
"fmt"
"os"
revengai "github.com/RevEngAI/sdk-go/v3"
)
func main() {
functionId := int64(789) // int64 | The ID of the function being rated
upsertAiDecomplationRatingRequest := *revengai.NewUpsertAiDecomplationRatingRequest(revengai.AiDecompilationRating("POSITIVE"), "Reason_example") // UpsertAiDecomplationRatingRequest |
configuration := revengai.NewConfiguration()
apiClient := revengai.NewAPIClient(configuration)
resp, r, err := apiClient.FunctionsAIDecompilationAPI.UpsertAiDecompilationRating(context.Background(), functionId).UpsertAiDecomplationRatingRequest(upsertAiDecomplationRatingRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FunctionsAIDecompilationAPI.UpsertAiDecompilationRating``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpsertAiDecompilationRating`: BaseResponse
fmt.Fprintf(os.Stdout, "Response from `FunctionsAIDecompilationAPI.UpsertAiDecompilationRating`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| functionId | int64 | The ID of the function being rated |
Other parameters are passed through a pointer to a apiUpsertAiDecompilationRatingRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
upsertAiDecomplationRatingRequest | UpsertAiDecomplationRatingRequest | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]