mirror of https://github.com/langgenius/dify.git
fix: raw text
This commit is contained in:
parent
0c409e2b9e
commit
fa673f9b4c
|
|
@ -33,7 +33,7 @@ class HttpRequestNodeData(BaseNodeData):
|
|||
return v
|
||||
|
||||
class Body(BaseModel):
|
||||
type: Literal['none', 'form-data', 'x-www-form-urlencoded', 'raw', 'json']
|
||||
type: Literal['none', 'form-data', 'x-www-form-urlencoded', 'raw-text', 'json']
|
||||
data: Union[None, str]
|
||||
|
||||
variables: list[VariableSelector]
|
||||
|
|
|
|||
|
|
@ -275,7 +275,7 @@ class HttpExecutor:
|
|||
self.headers['Content-Type'] = f'multipart/form-data; boundary={self.boundary}'
|
||||
else:
|
||||
self.body = urlencode(body)
|
||||
elif node_data.body.type in ['json', 'raw']:
|
||||
elif node_data.body.type in ['json', 'raw-text']:
|
||||
self.body = original_body
|
||||
elif node_data.body.type == 'none':
|
||||
self.body = ''
|
||||
|
|
|
|||
Loading…
Reference in New Issue