auth=auth
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
import requests
|
import requests
|
||||||
|
from requests.auth import HTTPBasicAuth
|
||||||
from app.utils.logger import logger
|
from app.utils.logger import logger
|
||||||
from app.config import settings
|
from app.config import settings
|
||||||
|
|
||||||
@@ -23,7 +24,6 @@ class SimbrellaIntegration:
|
|||||||
"crc": False,
|
"crc": False,
|
||||||
"crms": True,
|
"crms": True,
|
||||||
"accountStatus": "active",
|
"accountStatus": "active",
|
||||||
"lienAmount": 0,
|
|
||||||
"lien": False,
|
"lien": False,
|
||||||
"noBouncedCheck": True,
|
"noBouncedCheck": True,
|
||||||
"existingLoan": False,
|
"existingLoan": False,
|
||||||
@@ -35,9 +35,10 @@ class SimbrellaIntegration:
|
|||||||
}
|
}
|
||||||
|
|
||||||
logger.error(f"This is PayLoad: {str(payload)}",exc_info=True)
|
logger.error(f"This is PayLoad: {str(payload)}",exc_info=True)
|
||||||
|
auth = HTTPBasicAuth(settings.VALID_APP_ID, settings.VALID_APP_SECRET)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
response = requests.post(url, json=payload, timeout=10)
|
response = requests.post(url, json=payload, timeout=10, auth=auth)
|
||||||
logger.error(f"This is Response: {str(response)}", exc_info=True)
|
logger.error(f"This is Response: {str(response)}", exc_info=True)
|
||||||
# Raise an error for non-200 responses
|
# Raise an error for non-200 responses
|
||||||
response.raise_for_status()
|
response.raise_for_status()
|
||||||
|
|||||||
Reference in New Issue
Block a user