Skip to content

Commit

Permalink
Merge pull request #94 from oooiik/master
Browse files Browse the repository at this point in the history
Support Protocol Profile Behavior
  • Loading branch information
tomirons committed Mar 6, 2024
2 parents 2cbc360 + 91b7621 commit f5afbd2
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
14 changes: 14 additions & 0 deletions config/api-postman.php
Original file line number Diff line number Diff line change
Expand Up @@ -156,4 +156,18 @@

'disk' => 'local',

/*
|--------------------------------------------------------------------------
| Protocol Profile Behavior
|--------------------------------------------------------------------------
|
| Set of configurations used to alter the usual behavior of sending the request.
| These can be defined in a collection at Item or ItemGroup level which will be inherited if applicable.
|
*/

'protocol_profile_behavior' => [
'disable_body_pruning' => false, // Control request body pruning for following methods: GET, COPY, HEAD, PURGE, UNLOCK
]

];
6 changes: 6 additions & 0 deletions src/Commands/ExportPostmanCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,12 @@ public function makeRequest($route, $method, $routeHeaders, $requestRules, $requ
],
];

if($this->config['protocol_profile_behavior']['disable_body_pruning']) {
$data['protocolProfileBehavior'] = [
'disableBodyPruning' => true,
];
}

if ($requestRules) {
$ruleData = [];

Expand Down

0 comments on commit f5afbd2

Please sign in to comment.