Skip to content

Commit 9b5b056

Browse files
📝 fix code samples (#174)
1 parent 5e10240 commit 9b5b056

6 files changed

Lines changed: 9 additions & 7 deletions

File tree

docs/code_samples/v2_classification.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ $classificationParams = new ClassificationParameters(
2222
// Load a file from disk
2323
$inputSource = new PathInput($filePath);
2424

25-
// Upload the file
25+
// Send for processing using polling
2626
$response = $mindeeClient->enqueueAndGetResult(
2727
ClassificationResponse::class,
2828
$inputSource,

docs/code_samples/v2_crop.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ $cropParams = new CropParameters(
2222
// Load a file from disk
2323
$inputSource = new PathInput($filePath);
2424

25-
// Upload the file
25+
// Send for processing using polling
2626
$response = $mindeeClient->enqueueAndGetResult(
2727
CropResponse::class,
2828
$inputSource,

docs/code_samples/v2_extraction_polling.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
use Mindee\ClientV2;
44
use Mindee\Input\InferenceParameters;
55
use Mindee\Input\PathInput;
6+
use Mindee\Parsing\V2\InferenceResponse;
67

78
$apiKey = "MY_API_KEY";
89
$filePath = "/path/to/the/file.ext";
@@ -33,8 +34,9 @@ $inferenceParams = new InferenceParameters(
3334
// Load a file from disk
3435
$inputSource = new PathInput($filePath);
3536

36-
// Upload the file
37-
$response = $mindeeClient->enqueueAndGetInference(
37+
// Send for processing using polling
38+
$response = $mindeeClient->enqueueAndGetResult(
39+
InferenceResponse::class,
3840
$inputSource,
3941
$inferenceParams
4042
);

docs/code_samples/v2_extraction_webhook.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ $inferenceParams = new InferenceParameters(
3434
// Load a file from disk
3535
$inputSource = new PathInput($filePath);
3636

37-
// Upload the file
37+
// Send for processing
3838
$response = $mindeeClient->enqueue(
3939
$inputSource,
4040
$inferenceParams

docs/code_samples/v2_ocr.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ $ocrParams = new OcrParameters(
2222
// Load a file from disk
2323
$inputSource = new PathInput($filePath);
2424

25-
// Upload the file
25+
// Send for processing using polling
2626
$response = $mindeeClient->enqueueAndGetResult(
2727
OcrResponse::class,
2828
$inputSource,

docs/code_samples/v2_split.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ $splitParams = new SplitParameters(
2222
// Load a file from disk
2323
$inputSource = new PathInput($filePath);
2424

25-
// Upload the file
25+
// Send for processing using polling
2626
$response = $mindeeClient->enqueueAndGetResult(
2727
SplitResponse::class,
2828
$inputSource,

0 commit comments

Comments
 (0)