brandon14/ebay-sdk-php

View on GitHub

Showing 3,709 of 3,709 total issues

Method bulkCreateNegativeKeywordRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function bulkCreateNegativeKeywordRequest($bulk_create_negative_keyword_request)
    {
        // Verify the required parameter 'bulk_create_negative_keyword_request' is set.
        if ($bulk_create_negative_keyword_request === null || (\is_array($bulk_create_negative_keyword_request) && count($bulk_create_negative_keyword_request) === 0)) {
            throw new \InvalidArgumentException('Missing the required parameter $bulk_create_negative_keyword_request when calling bulkCreateNegativeKeyword');
Severity: Major
Found in src/Sell/Marketing/V1/Api/NegativeKeywordApi.php - About 2 hrs to fix

    Method createCampaignRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        public function createCampaignRequest($create_campaign_request)
        {
            // Verify the required parameter 'create_campaign_request' is set.
            if ($create_campaign_request === null || (\is_array($create_campaign_request) && count($create_campaign_request) === 0)) {
                throw new \InvalidArgumentException('Missing the required parameter $create_campaign_request when calling createCampaign');
    Severity: Major
    Found in src/Sell/Marketing/V1/Api/CampaignApi.php - About 2 hrs to fix

      Method createReportTaskRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          public function createReportTaskRequest($create_report_task)
          {
              // Verify the required parameter 'create_report_task' is set.
              if ($create_report_task === null || (\is_array($create_report_task) && count($create_report_task) === 0)) {
                  throw new \InvalidArgumentException('Missing the required parameter $create_report_task when calling createReportTask');
      Severity: Major
      Found in src/Sell/Marketing/V1/Api/AdReportTaskApi.php - About 2 hrs to fix

        Method createPaymentPolicyRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            public function createPaymentPolicyRequest($payment_policy_request)
            {
                // Verify the required parameter 'payment_policy_request' is set.
                if ($payment_policy_request === null || (\is_array($payment_policy_request) && count($payment_policy_request) === 0)) {
                    throw new \InvalidArgumentException('Missing the required parameter $payment_policy_request when calling createPaymentPolicy');
        Severity: Major
        Found in src/Sell/Account/V1/Api/PaymentPolicyApi.php - About 2 hrs to fix

          Method createFulfillmentPolicyRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              public function createFulfillmentPolicyRequest($fulfillment_policy_request)
              {
                  // Verify the required parameter 'fulfillment_policy_request' is set.
                  if ($fulfillment_policy_request === null || (\is_array($fulfillment_policy_request) && count($fulfillment_policy_request) === 0)) {
                      throw new \InvalidArgumentException('Missing the required parameter $fulfillment_policy_request when calling createFulfillmentPolicy');
          Severity: Major
          Found in src/Sell/Account/V1/Api/FulfillmentPolicyApi.php - About 2 hrs to fix

            Method optOutOfProgramRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                public function optOutOfProgramRequest($program)
                {
                    // Verify the required parameter 'program' is set.
                    if ($program === null || (\is_array($program) && count($program) === 0)) {
                        throw new \InvalidArgumentException('Missing the required parameter $program when calling optOutOfProgram');
            Severity: Major
            Found in src/Sell/Account/V1/Api/ProgramApi.php - About 2 hrs to fix

              Method optInToProgramRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public function optInToProgramRequest($program)
                  {
                      // Verify the required parameter 'program' is set.
                      if ($program === null || (\is_array($program) && count($program) === 0)) {
                          throw new \InvalidArgumentException('Missing the required parameter $program when calling optInToProgram');
              Severity: Major
              Found in src/Sell/Account/V1/Api/ProgramApi.php - About 2 hrs to fix

                Method createReturnPolicyRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    public function createReturnPolicyRequest($return_policy_request)
                    {
                        // Verify the required parameter 'return_policy_request' is set.
                        if ($return_policy_request === null || (\is_array($return_policy_request) && count($return_policy_request) === 0)) {
                            throw new \InvalidArgumentException('Missing the required parameter $return_policy_request when calling createReturnPolicy');
                Severity: Major
                Found in src/Sell/Account/V1/Api/ReturnPolicyApi.php - About 2 hrs to fix

                  Method createTaskRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      public function createTaskRequest($create_task_request, $x_ebay_c_marketplace_id = null)
                      {
                          // Verify the required parameter 'create_task_request' is set.
                          if ($create_task_request === null || (\is_array($create_task_request) && count($create_task_request) === 0)) {
                              throw new \InvalidArgumentException('Missing the required parameter $create_task_request when calling createTask');
                  Severity: Major
                  Found in src/Sell/Feed/V1/Api/TaskApi.php - About 2 hrs to fix

                    Method createOrderTaskRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        public function createOrderTaskRequest($create_order_task_request, $x_ebay_c_marketplace_id = null)
                        {
                            // Verify the required parameter 'create_order_task_request' is set.
                            if ($create_order_task_request === null || (\is_array($create_order_task_request) && count($create_order_task_request) === 0)) {
                                throw new \InvalidArgumentException('Missing the required parameter $create_order_task_request when calling createOrderTask');
                    Severity: Major
                    Found in src/Sell/Feed/V1/Api/OrderTaskApi.php - About 2 hrs to fix

                      Method createInventoryTaskRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          public function createInventoryTaskRequest($create_inventory_task_request, $x_ebay_c_marketplace_id = null)
                          {
                              // Verify the required parameter 'create_inventory_task_request' is set.
                              if ($create_inventory_task_request === null || (\is_array($create_inventory_task_request) && count($create_inventory_task_request) === 0)) {
                                  throw new \InvalidArgumentException('Missing the required parameter $create_inventory_task_request when calling createInventoryTask');
                      Severity: Major
                      Found in src/Sell/Feed/V1/Api/InventoryTaskApi.php - About 2 hrs to fix

                        Method sendOfferToInterestedBuyersRequest has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            public function sendOfferToInterestedBuyersRequest($x_ebay_c_marketplace_id, $create_offers_request = null)
                            {
                                // Verify the required parameter 'x_ebay_c_marketplace_id' is set.
                                if ($x_ebay_c_marketplace_id === null || (\is_array($x_ebay_c_marketplace_id) && count($x_ebay_c_marketplace_id) === 0)) {
                                    throw new \InvalidArgumentException('Missing the required parameter $x_ebay_c_marketplace_id when calling sendOfferToInterestedBuyers');
                        Severity: Major
                        Found in src/Sell/Negotiation/V1/Api/OfferApi.php - About 2 hrs to fix

                          Function getInventoryLocationsRequest has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring.
                          Open

                              public function getInventoryLocationsRequest($limit = null, $offset = null)
                              {
                                  $resourcePath = '/location';
                                  $formParams = [];
                                  $queryParams = [];
                          Severity: Minor
                          Found in src/Sell/Account/V1/Api/LocationApi.php - About 2 hrs to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Function getSchedulesRequest has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring.
                          Open

                              public function getSchedulesRequest($feed_type, $limit = null, $offset = null)
                              {
                                  // Verify the required parameter 'feed_type' is set.
                                  if ($feed_type === null || (\is_array($feed_type) && count($feed_type) === 0)) {
                                      throw new \InvalidArgumentException('Missing the required parameter $feed_type when calling getSchedules');
                          Severity: Minor
                          Found in src/Sell/Feed/V1/Api/ScheduleApi.php - About 2 hrs to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          Function getScheduleTemplatesRequest has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring.
                          Open

                              public function getScheduleTemplatesRequest($feed_type, $limit = null, $offset = null)
                              {
                                  // Verify the required parameter 'feed_type' is set.
                                  if ($feed_type === null || (\is_array($feed_type) && count($feed_type) === 0)) {
                                      throw new \InvalidArgumentException('Missing the required parameter $feed_type when calling getScheduleTemplates');
                          Severity: Minor
                          Found in src/Sell/Feed/V1/Api/ScheduleApi.php - About 2 hrs to fix

                          Cognitive Complexity

                          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                          A method's cognitive complexity is based on a few simple rules:

                          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                          • Code is considered more complex for each "break in the linear flow of the code"
                          • Code is considered more complex when "flow breaking structures are nested"

                          Further reading

                          File SearchByImageApi.php has 274 lines of code (exceeds 250 allowed). Consider refactoring.
                          Open

                          <?php
                          
                          /**
                           * This file is part of the trollandtoad/ebay-sdk-php package.
                           *
                          Severity: Minor
                          Found in src/Buy/Browse/V1/Api/SearchByImageApi.php - About 2 hrs to fix

                            Method getFeedTypeRequest has 64 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                public function getFeedTypeRequest($feed_type_id)
                                {
                                    // Verify the required parameter 'feed_type_id' is set.
                                    if ($feed_type_id === null || (\is_array($feed_type_id) && count($feed_type_id) === 0)) {
                                        throw new \InvalidArgumentException('Missing the required parameter $feed_type_id when calling getFeedType');
                            Severity: Major
                            Found in src/Buy/Feed/V1/Api/FeedTypeApi.php - About 2 hrs to fix

                              Method getSigningKeyRequest has 64 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  public function getSigningKeyRequest($signing_key_id)
                                  {
                                      // Verify the required parameter 'signing_key_id' is set.
                                      if ($signing_key_id === null || (\is_array($signing_key_id) && count($signing_key_id) === 0)) {
                                          throw new \InvalidArgumentException('Missing the required parameter $signing_key_id when calling getSigningKey');
                              Severity: Major
                              Found in src/Developer/KeyManagement/V1/Api/SigningKeyApi.php - About 2 hrs to fix

                                Method cancelShipmentRequest has 64 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                    public function cancelShipmentRequest($shipment_id)
                                    {
                                        // Verify the required parameter 'shipment_id' is set.
                                        if ($shipment_id === null || (\is_array($shipment_id) && count($shipment_id) === 0)) {
                                            throw new \InvalidArgumentException('Missing the required parameter $shipment_id when calling cancelShipment');
                                Severity: Major
                                Found in src/Sell/Logistics/V1/Api/ShipmentApi.php - About 2 hrs to fix

                                  Method downloadLabelFileRequest has 64 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      public function downloadLabelFileRequest($shipment_id)
                                      {
                                          // Verify the required parameter 'shipment_id' is set.
                                          if ($shipment_id === null || (\is_array($shipment_id) && count($shipment_id) === 0)) {
                                              throw new \InvalidArgumentException('Missing the required parameter $shipment_id when calling downloadLabelFile');
                                  Severity: Major
                                  Found in src/Sell/Logistics/V1/Api/ShipmentApi.php - About 2 hrs to fix
                                    Severity
                                    Category
                                    Status
                                    Source
                                    Language