<?php
define("EvolutionScript", 1);
define("ROOTPATH", dirname(__FILE__) . "/");
define("INCLUDES", ROOTPATH . "includes/");
require_once INCLUDES . "php84_compat.php";
require_once INCLUDES . "global.php";
mysql_set_charset("utf8");

date_default_timezone_set('Asia/Jerusalem');


/**
 * --------------------------
 * Shopify Configuration
 * --------------------------
 */
define('SHOPIFY_STORE_DOMAIN', '7memo.myshopify.com');
define('SHOPIFY_CLIENT_ID', '5c4a7c0979de88a00e8e52fdd0a37dd9');
define('SHOPIFY_CLIENT_SECRET', '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');

define('0000SHOPIFY_STORE_DOMAIN', 'b12508-b1.myshopify.com');
define('0000SHOPIFY_CLIENT_ID', '62b6d2907338aad2059f20736d569983');
define('0000SHOPIFY_CLIENT_SECRET', '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');

define('SHOPIFY_API_VERSION', '2026-04');
define('SHOPIFY_NOTIFY_CUSTOMER_ON_FULFILL', true);

define('SHOPIFY_REST_LIMIT', 100);
define('SHOPIFY_TOKEN_REFRESH_BUFFER', 120);
define('TABLE_ORDERS', 'orders');

/**
 * Optional token cache file
 */
define('SHOPIFY_TOKEN_CACHE_FILE', ROOTPATH . 'cache_shopify_access_token.json');


/**
 * --------------------------
 * NetSuite REST Configuration
 * --------------------------
 */
define('NS_REST_ACCOUNT', '6950311_SB1');
define('NS_REST_ACCOUNT2', '6950311-sb1');
define('NS_REST_CONSUMER_KEY', "d1a313bcecf04a838b69aa1ad673b3113e0e6a9184063aa7c838614cc3e1ab04");
define('NS_REST_CONSUMER_SECRET', "c10979c3626f1d381063d1de194399bcd389b1a74cd7bafd1de9791b71676350");
define('NS_REST_TOKEN_ID', "a774a0e75c1cf0cd58d2aa3406e865f97c83b3dc0f39ab73c1dadac0bc95c64e");
define('NS_REST_TOKEN_SECRET', "5a424b63c0feb338af28e301efe56b2f574513158adccb85c252c380300c87d9");
define('NS_REST_REALM', '6950311_SB1');

define('NS_REST_RECORD_BASE', 'https://6950311-sb1.suitetalk.api.netsuite.com/services/rest/record/v1');

define('NS_SYNC_LIMIT', 1);


/**
 * --------------------------
 * Current system defaults
 * --------------------------
 */
define('NS_DEFAULT_CUSTOMER_ID', 22388);
define('NS_DEFAULT_LOCATION_ID', 445);
define('NS_DEFAULT_SUBSIDIARY_ID', 39);
define('NS_DEFAULT_SALESREP_ID', 22389);
//define('NS_DEFAULT_TERMS_ID', 0);
//define('NS_DEFAULT_CUSTOMFORM_ID', 0);

define('NS_ENABLE_SUITETAX_OVERRIDE', true);
define('NS_DEFAULT_TAXTYPE_ID', 12);      // غيّرها حسب Tax Type internal id عندك
define('NS_DEFAULT_TAXCODE_ID', 3789);    // ضريبة NetSuite عندك
define('NS_DEFAULT_TAX_RATE', 25);     // 19%، أو اكتب 19 عادي

define('NS_DEFAULT_ITR_NEXUS', 'DE');
define('NS_DEFAULT_NEXUS_NOTC_ID', 1);

define('NS_ORDER_STATUS_SUCCESS', 1);
define('NS_ORDER_STATUS_ERROR', 2);

define('NS_PAYMENT_STATUS_PENDING', 0);
define('NS_PAYMENT_STATUS_SUCCESS', 1);
define('NS_PAYMENT_STATUS_NO_PAYMENTS', 2);

define('NS_DHL_TRACKING_NUMBER_CUSTBODY', 'custbody_il_shipping_num');
define('NS_DHL_LINK_CUSTBODY', 'custbody3');

define('NS_INVENTORY_SYNC_SECRET', '102030');

define('NS_DISCOUNT_ITEM_ID', -6);
define('NS_SHIPPING_ITEM_ID', 3790);


//declare(strict_types=1);

const DHL_API_KEY = '8bhXJPQs2tWdBVeLcDDEr1wYZUsNMRmk';
const DHL_API_SECRET = 'dciHAauoG68Z6IA6';

const DHL_BASE_URL = 'https://api-sandbox.dhl.com';

// Sandbox test credentials from DHL docs
const DHL_USERNAME = 'user-valid';
const DHL_PASSWORD = 'SandboxPasswort2023!';



/**
 * Optional body field script IDs if you want to send them
 */
//define('NS_BODYFIELD_BRANCH_SCRIPTID', getenv('NS_BODYFIELD_BRANCH_SCRIPTID') ?: '');
//define('NS_BODYFIELD_PAYMENT_METHOD_SCRIPTID', getenv('NS_BODYFIELD_PAYMENT_METHOD_SCRIPTID') ?: '');
//define('NS_BODYFIELD_SHOPIFY_ORDER_ID_SCRIPTID', getenv('NS_BODYFIELD_SHOPIFY_ORDER_ID_SCRIPTID') ?: '');


?>